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.
Any updates on this?
I may be having a similar issue . . . is there an update on this?
. . . possibly related, I'm getting these exceptions regularly in the background:
Exception in thread "Timer-6" java.lang.NullPointerException
Can you take the trunk and make a build out of it ? I think the fix is checked in but not into release yet.
(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.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.