cancel
Showing results for 
Search instead for 
Did you mean: 

Disconnect JCO Connection.

Former Member
0 Kudos

Hi,

We are not sure that the JCo connection which are getting created are getting disconnected as well. How do we verify it? We are disconnecting the jco in code itself. But, its not working, I guess. The problem which we are facing is that since the connection are not getting disconnected, like we have MAX 100 connection size, the users are not able to connect or execute the application as they don't have any way to connect.

Is there any solution to solve this issue?

We are using EP 6 SP19.

Regards,

Vaibhav

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

To verify if the connection has been closed you can use:

<b>wdContext.currentModelElement().modelObject().modelInstance().disconnectIfAlive();</b>

If you use Transaction Commit be aware that you don't do this before you are sending the transaction commit. Otherwise all changes will be lost.

Regards,

Dennis

Former Member
0 Kudos

Is there any way other than

wdContext.currentModelElement().modelObject().modelInstance().disconnectIfAlive();

to disconnect?

Will increasing the size of max pool size solve the issue?

If increased, will it affect other applications performance?

Former Member
0 Kudos

I don't know any other way to disconnect and I think

you should always do it over the modelObject if wanted.

Normally the framework takes care of it.

I'm only calling this in wdDoExit to make sure

all connections are terminated when the Component gets destroyed.

Answers (1)

Answers (1)

Former Member
0 Kudos

<b>While Creating JCo there will be option for entering the Maximum Connections that can be handled.

It will be specified in the Connection Pool.

Hi

So During the Life cycle of your application Your connection will be Released when it is inactive for particular Time (The inactive time limit will be specified in the JCo Pool Settings that would be in milli seconds)

The RFC Connection can be Monitored using the Gateway process .

There are Some Predefined Connections in the Gatewway Process and each connection Requires approximately 200Kb of Memory.

So the memory cosumption of the Gateway process is proportional to the number of Active RFC Connection.

Regards

Chandran S</b>