NetTalk Central

Author Topic: First access to p_web on app start  (Read 3425 times)

markster

  • Full Member
  • ***
  • Posts: 204
    • View Profile
    • Email
First access to p_web on app start
« on: September 15, 2015, 03:42:40 PM »
Bruce, I've been thinking about my ThreadPool issue from several months ago wherein my app crashes on startup when Thread Pooling is ticked off. I'm thinking now that it may have to do with some initialization procedures that I put in a routine at the beginning of the WebHandler. The routine is called after the third line of the WebHandler code:

  GlobalErrors.SetProcedureName('WebHandler')
  p_web.ProcessRequest(p_ReqString)
  GlobalErrors.SetProcedureName()
! [Priority 7500]
  DO ProcessGlobal !! my initialization procedures

The routine runs only one time and the function is to load a bunch of data from SQL files into Memory files. So I'm wondering if there is any way to access p_web data before the first call to WebHandler (ie in the WebServer).

Thanks,

Mark

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: First access to p_web on app start
« Reply #1 on: September 16, 2015, 02:03:41 AM »
Hi Mark,

I'm not sure your approach makes any sense to me.

Anything you do on program startup you can do in the web server procedure.
Anything you do in WebHandler to p_web will be almost instantly lost as that thread completes.

So first question becomes;
What has p_web got to do with application startup?

cheers
Bruce


markster

  • Full Member
  • ***
  • Posts: 204
    • View Profile
    • Email
Re: First access to p_web on app start
« Reply #2 on: September 19, 2015, 12:07:14 PM »
Setting Pool Threading crashed my program when I tried to implement it several months ago and I was trying to minimize any non-template coding in an effort to debug things. However, I just tried setting the Thread Pooling on again and it's working! Don't know why, but during the last several months I upgraded to Win10, C10, and all the current CS updates...

Mark