NetTalk Central

Author Topic: MultiDLL problem with report  (Read 7485 times)

osquiabro

  • Hero Member
  • *****
  • Posts: 687
    • View Profile
    • Email
MultiDLL problem with report
« 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

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11251
    • View Profile
Re: MultiDLL problem with report
« Reply #1 on: June 24, 2019, 01:08:42 AM »
hi Osa,

um - none of the apps are set as an Exe. Presumably the WebServer app should be set as Exe?

Cheers
Bruce
« Last Edit: June 25, 2019, 09:12:38 PM by Bruce »

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11251
    • View Profile
Re: MultiDLL problem with report
« Reply #2 on: June 24, 2019, 01:12:01 AM »
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

osquiabro

  • Hero Member
  • *****
  • Posts: 687
    • View Profile
    • Email
Re: MultiDLL problem with report
« Reply #3 on: June 24, 2019, 06:26:10 AM »
Thanks Bruce, I saw that in dll mode it is slower than .exe .

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11251
    • View Profile
Re: MultiDLL problem with report
« Reply #4 on: June 25, 2019, 12:08:12 AM »
slower to do what?

osquiabro

  • Hero Member
  • *****
  • Posts: 687
    • View Profile
    • Email
Re: MultiDLL problem with report
« Reply #5 on: June 25, 2019, 04:16:41 AM »
everything...

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11251
    • View Profile
Re: MultiDLL problem with report
« Reply #6 on: June 25, 2019, 09:16:44 PM »
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

osquiabro

  • Hero Member
  • *****
  • Posts: 687
    • View Profile
    • Email
Re: MultiDLL problem with report
« Reply #7 on: June 26, 2019, 02:26:51 PM »
and what do you recommend? this is my first app as dll mode, I don't know much about this topic.

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11251
    • View Profile
Re: MultiDLL problem with report
« Reply #8 on: June 27, 2019, 02:31:42 AM »
which of the above items (a through f) above are slow?

cheers
Bruce

osquiabro

  • Hero Member
  • *****
  • Posts: 687
    • View Profile
    • Email
Re: MultiDLL problem with report
« Reply #9 on: June 27, 2019, 03:48:35 AM »
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

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11251
    • View Profile
Re: MultiDLL problem with report
« Reply #10 on: June 27, 2019, 11:09:13 PM »
Hi Osa,

do you have a Data DLL?
does your Data DLL "generate all file declarations"?

cheers
Bruce

osquiabro

  • Hero Member
  • *****
  • Posts: 687
    • View Profile
    • Email
Re: MultiDLL problem with report
« Reply #11 on: June 28, 2019, 04:27:18 AM »
"do you have a Data DLL?
does your Data DLL "generate all file declarations"?"


Yes..

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11251
    • View Profile
Re: MultiDLL problem with report
« Reply #12 on: July 01, 2019, 10:27:09 PM »
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