Calling a webservice method on port in CLOSE_WAIT establishes a new connection - Forum - OpenEdge Development - Progress Community

Calling a webservice method on port in CLOSE_WAIT establishes a new connection

 Forum

Calling a webservice method on port in CLOSE_WAIT establishes a new connection

This question is not answered

I noticed that when a webservice port switches to CLOSE_WAIT because of inactivity then later on you try to call another webservice method, the act of calling a method establishes a new connection and thus a new port number. This leaves the original port in CLOSE_WAIT status.

Is this an expected behavior of port, or is this a Progress implementation? The problem is that the port in CLOSE_WAIT status lingers on and never freed up until the application is closed.

Or better yet, is there a way to check for the port status before I make my method call?

All Replies
  • Most (all?) OS's have a linger timeout before a socket is completely cleaned up.  This is to let the OS handle any stray packets that may be coming in over the network even after the application has indicated it is done with the socket.  You can control it by setting socket option SO_LINGER to 0.

  • Unfortunately, it lingers on forever (throughout the lifetime of the application) it seems. Ports in CLOSE_WAIT status accumulate throughout the day.

    From the KB, to address this left over port in CLOSE_WAIT, it is recommended to disconnect, and delete porttype and webservice handles. However, if the new connection (new port assignment) is established implicitly during a method call then there is no way for the program to issue a disconnect.

  • Joseph,
     
    I would consider that to be a bug.  Please open a case with support.
     
    Brian Maher
    Principal Engineer, Technical Support
    Progress
    Progress
    14 Oak Park | Bedford, MA 01730 | USA
    phone
    +1 781 280 3075
     
     
    Twitter
    Facebook
    LinkedIn
    Google+
     
     
    ProgressNext2018_Email_Signature
     

  • Case is created. Thanks,

  • I believe this is the TIME_WAIT status and not the CLOSE_WAIT status.

    Matt Baker

    Most (all?) OS's have a linger timeout before a socket is completely cleaned up.  This is to let the OS handle any stray packets that may be coming in over the network even after the application has indicated it is done with the socket.  You can control it by setting socket option SO_LINGER to 0.

  • CLOSE_WAIT means the socket is being shut down and the server is waiting for the client to perform a close () call.

  • No related bug number, but we are going to test this on 11.7. Per support, the issue is not occurring in 11.7. We are still using 11.6.

  • The related bug number is PSC00340741, fixed in 11.7.0