cancel
Showing results for 
Search instead for 
Did you mean: 

Close JCO Session

Former Member
0 Kudos

Dear All,

We are facing a major performance problem in the production environment. We have more than 300 users in the production. when I was checking JCO connections status through sm04 transaction, we see most of the connections stay open more than one day. After reaching the maximum, we are forced to restart the server. Then only the JCO connections are closed. We have SSO enabled for all the model data JCO connections.

I found some peoplo adjust do it like this:

-


Zzcsh_Nbzy_T09_Input input = new Zzcsh_Nbzy_T09_Input();

input.setI_Bukrs(el.getI_bukrs());

input.setI_Date_B(el.getI_date_b());

input.setI_Date_E(el.getI_date_e());

input.setI_Only_Sbd(el.getI_only_sbd());

input.setI_Swerk(el.getI_swerk());

try{

input.execute();

}catch(Exception e) {

reporter.error("error:"+e.getMessage());

}

wdContext.nodeZcsh_Struc_Sbbd();

Common.getReturn(input.getOutput().getReturn(),reporter);

List list = input.getOutput().getTb_List();

wdContext.nodeZcsh_Struc_Sbbd().bind(list);

input.modelInstance().disconnectIfAlive();

-


I met this error:

-


com.sap.mw.jco.JCO$Exception: (102) RFC_ERROR_COMMUNICATION: connection closed without message (CM_NO_DATA_RECEIVED)

-


How can I do it?

Best Regards.

Jiandong

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi ,

Write the code as follows and check.

Zzcsh_Nbzy_T09_Input input = new Zzcsh_Nbzy_T09_Input();

input.setI_Bukrs(el.getI_bukrs());

input.setI_Date_B(el.getI_date_b());

input.setI_Date_E(el.getI_date_e());

input.setI_Only_Sbd(el.getI_only_sbd());

input.setI_Swerk(el.getI_swerk());

try{

input.execute();

wdContext.nodeZcsh_Struc_Sbbd();

Common.getReturn(input.getOutput().getReturn(),reporter);

List list = input.getOutput().getTb_List();

wdContext.nodeZcsh_Struc_Sbbd().bind(list);

}catch(Exception e) {

reporter.error("error:"+e.getMessage());

}

finally

{

input.modelInstance().disconnectIfAlive();

}

Best Wishes

Idhaya R

Former Member
0 Kudos

Dear IdhayaR,

Thank you very mutch. It resolved.

Jiandong

Former Member
0 Kudos

Best Wishes

Idhaya R

Answers (2)

Answers (2)

Former Member
0 Kudos

.

former_member197348
Active Contributor
0 Kudos

Hi Jiandong,

Try this:

Increase Maximum Pool Size: 300 , Maximum Connections = 300 for JCO. Increase Maximum Waiting Time and decrease Connection Timeout

I don't see any problem with your coding but I think you can close the connection