cancel
Showing results for 
Search instead for 
Did you mean: 

JCoDestination Is not responding

Former Member
0 Kudos

I have provided my code my issue is below code is working on local but when deploy it on production JCoDestination Is not responding after below line, not even error or log.

destination = JCoDestinationManager.getDestination("mySAPSystem");

check my code once -

public class SapTest {

private static JCoDestination destination=null;
private static String DESTINATION_NAME1 = "mySAPSystem";

public static void main(String[] args) {

Properties connectProperties = new Properties();
connectProperties.setProperty(DestinationDataProvider.JCO_ASHOST, "xxx.xx.xx.xx");
connectProperties.setProperty(DestinationDataProvider.JCO_SYSNR, "xx");
connectProperties.setProperty(DestinationDataProvider.JCO_CLIENT, "xxx");
connectProperties.setProperty(DestinationDataProvider.JCO_USER, "279824");
connectProperties.setProperty(DestinationDataProvider.JCO_PASSWD, "xxxxxxx");
connectProperties.setProperty(DestinationDataProvider.JCO_LANG, "EN");

createDestinationDataFile(DESTINATION_NAME1, connectProperties);

try {

destination = JCoDestinationManager.getDestination("mySAPSystem");

destination.ping();

}catch (JCoException e) {
e.printStackTrace();
}

}

private static void createDestinationDataFile(String destinationName, Properties connectProperties) {

File destCfg = new File(destinationName+".jcoDestination");
try
{
FileOutputStream fos = new FileOutputStream(destCfg, false);
connectProperties.store(fos, "for tests only !");
fos.close();
}
catch (Exception e)
{
throw new RuntimeException("Unable to create the destination files", e);
}

}

}

Accepted Solutions (0)

Answers (0)