Port 135 Connection issue

Dev B
  • Dev B

    Dev B - 2011-03-17

    I are using j-interop for DCOM communication with Windows host.
    I have a process which opens up the connection to the Windows host. Below is the snippet of the code which does this:
                                  JISession jISession = JISession.createSession(domain, username, password);
                                  JIClsid clsid = JIClsid.valueOf(CLSID);
                                  JIComServer comStub = new JIComServer(clsid, host, jISession);
                                  IJIComObject comObject = comStub.createInstance();-------<1>
                                  IJIComObject swbemLocator = comObject.queryInterface(IID);
                                  IJIDispatch swbemLocator_disp = (IJIDispatch) JIObjectFactory.narrowObject(swbemLocator.queryInterface(IJIDispatch.IID));
    Using the IJIDispatch and JISession object, after the work with the COM server is done, I move to close the session during which JISession.destroySession(jISession) is called.

    However, one of the 2 connections which gets opened during <1> above, is not getting closed after the destroySession method is called. Only the random numbered port connection is closed whereas the 135 port connection remains open till the end of the process.

    Could you please provide some detail on the following and what could be possible reasons for the connection to port 135 remaining open?
    >> Are these 2 ports opened as part of the same JISession object?
    >> Is there a sequence to the opening of the ports?I can see that the random numbered port connection opens up first and then the port 135 connection, after sometime.
    >> Is there any way I can force the closure of this open connection? There does not seem to be a way to get a handle to this connection.

  • Dev B

    Dev B - 2011-03-28

    Any updates on this?

  • fhwdgads

    fhwdgads - 2011-05-18

    I may be having a similar issue . . . is there an update on this?

  • fhwdgads

    fhwdgads - 2011-05-18

    . . . possibly related, I'm getting these exceptions regularly in the background:

    Exception in thread "Timer-6" java.lang.NullPointerException
        at org.jinterop.dcom.core.JIComOxidRuntime$ServerPingTimerTask.run(JIComOxidRuntime.java:126)
        at java.util.TimerThread.mainLoop(Timer.java:512)
        at java.util.TimerThread.run(Timer.java:462)
  • Vikram Roopchand

         Can you take the trunk and make a build out of it ? I think the fix is checked in but not into release yet.

    best regards,

  • fhwdgads

    fhwdgads - 2011-05-23

    Awesome, thanks!

    (BTW, we also need to set our default timeout on connections to something other than infinite.  I think that's made it G2G.)


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks