NetTalk Central
NetTalk Web Server => Web Server - Ask For Help => Topic started by: osquiabro on June 22, 2019, 04:20:36 AM
-
i have a problem with my first program as dll, i recreate the problem with MultiDLL(20) example, in dll mode when call a report as url don't recognize the procedure and return The page cannot be found, as .exe work perfect
the example is attached
Clarion 11
NT 10.38
-
hi Osa,
um - none of the apps are set as an Exe. Presumably the WebServer app should be set as Exe?
Cheers
Bruce
-
you didn't add the report DLL to the web server app.
You had the Customer DLL added ok, but not the Report.
WebServer app, WebServer Global Extension, Multi-DLL tab.
cheers
Bruce
-
Thanks Bruce, I saw that in dll mode it is slower than .exe .
-
slower to do what?
-
everything...
-
Hi Osa,
>> everything...
ok cool.
I've not seen that myself, and alas "everything" is not something I can fix, but if you manage to narrow it down a bit then maybe I can help. Some areas you can measure;
a) loading the exe
b) clicking around on the main window, seeing the performance, logs, settings tab and so on.
c) processing a web request (ie starting a thread)
d) processing a specific kind of web request (browse, form, api etc)
e) deleting a session
f) accessing session variables...
I could go on, but I suppose you get the idea.
If I had to guess I'd say you now have a Data dLL, which is declaring _all_ your tables (whereas your exe only declares a subset of them) and hence starting threads is slower because there are more table structures to initialise.
but that unfortunately won't affect "everything" - so I don't know if it's the cause.
cheers
Bruce
-
and what do you recommend? this is my first app as dll mode, I don't know much about this topic.
-
which of the above items (a through f) above are slow?
cheers
Bruce
-
It is very difficult to explain, but in general, when open any browser or form inclusive the index page , it is slower than when it is compiled as .exe
-
Hi Osa,
do you have a Data DLL?
does your Data DLL "generate all file declarations"?
cheers
Bruce
-
"do you have a Data DLL?
does your Data DLL "generate all file declarations"?"
Yes..
-
Hi Osa,
In that case when each thread starts all the File Manager objects have to be instantiated, and all the file buffers are allocated space and so on. This takes "a little" time, but it can be significant if there are a lot of tables. (In an extreme case a system with 1200 tables took 0.3 seconds to start a thread - which is long.)
In your case it's likely your app is only using a few tables, so the exe only included those tables, and it was fast. Now you are using a data DLL it's generating all the tables, so it's a bit slower.
In this sort of seyup I recommend making use of the Thread Pooling features. This "pre-opens" the threads, which in turn makes this "start thread" cost go away. See the docs for more on thread pooling.
cheers
Bruce