Jump to content
OlgerDiekstra

Terminating PHP session

Recommended Posts

I've got a FMSv16 (can't upgrade yet due to Windows 2k8R2), and am using CWP to send data to the server using php.

The server sends out SMS's via an online SMS Gateway and gets results back via php. This happens sometimes in a burst where hundreds of SMS's are send out, and the incoming results can overwhelm the server (in terms of connections, not CPU or memory resources). I've set the allowed CWP sessions to 1000, but I'd like to be able to terminate a session after the script has run.

I've tried calling a FM script with 'close database' and 'exit application' at the end of the php script, and unsetting the $fm variable in the php script, but it doesn't terminate the session to FM. The sessions automatically terminate after 3 mins or so, but that is sometimes too long.

Does anyone know how to end a session from either a FM script or within the php script?

Share this post


Link to post
Share on other sites

I assume from your description that the CWP session stays open longer than you want to?  Perhaps that is due to the script that you're calling from the PHP call?  Why not just let it create a record and not call a FM script?  Build a queue and let a FMS script schedule do the logic of what your PHP-called script does.  That should allow the CWP sessions to be much shorter in duration and 'weight'.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.