Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Fast demands gives err 500
#4
(06-03-2019, 02:19 AM)Alexandre Machado Wrote: Hi,

As Dan pointed out above, which version of IW and Delphi are you running?

Also, it is not clear that the calls to your content handler are targeted to the same session or different sessions. Is your session control based on cookies? If so, are you sending the cookies correctly to the server?

Sorry for the missing info.

Delphi XE 5 (the application runs on an old windows XP)
intraweb version is 14.0.52
Mode: SA
Not using cookies
Database: Firedac/mysql

The handler is an API for an external web application. The handler produces a label (for shipping goods). The problem arises when the client program does a bulk print (e.g. sends for instance 10 individual calls for 10 labels to the handler within a second). The handler produces a PDF label, writes this to disk and returns a string to the calling program, that contains the web-address of the PDF file for each of the 10 calls.

I have tried to lock the session (asession.lock   .handler-code...   asession.unlock), 
tried to delay each the session (makes no sense if the session is not locked, as it is timer based)

What I need is some way to delay the jobs until the current client job is terminated. The documentation for intraweb states that the 10 jobs is queued and executed one at the time, but somehow the process does not wait until all processes is terminated. It seems as it is the database process that is not done.

The problem is probably a firedac/mysql issues (blocking versus non-blocking), but the quick and dirty way to solve the problem is to delay each call in Intraweb.

Regards ib
Reply


Messages In This Thread
Fast demands gives err 500 - by ib elfving - 05-28-2019, 03:21 PM
RE: Fast demands gives err 500 - by DanBarclay - 05-29-2019, 01:06 AM
RE: Fast demands gives err 500 - by ib elfving - 06-03-2019, 03:53 AM
RE: Fast demands gives err 500 - by ib elfving - 06-03-2019, 12:29 PM
RE: Fast demands gives err 500 - by zsleo - 06-03-2019, 09:24 PM
RE: Fast demands gives err 500 - by joel - 06-04-2019, 01:29 AM
RE: Fast demands gives err 500 - by ib elfving - 06-04-2019, 03:00 AM
RE: Fast demands gives err 500 - by DanBarclay - 06-04-2019, 01:08 AM
RE: Fast demands gives err 500 - by ib elfving - 06-04-2019, 05:22 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)