简体   繁体   English

通过JCO连接到SAP消息服务器

[英]Connect to SAP message server through JCO

I have a working connection between my Java application and a SAP server through use of SAP JCO. 通过使用SAP JCO,我的Java应用程序与SAP服务器之间建立了有效的连接。 The problem is that my connection is limited to 1 server. 问题是我的连接仅限于1台服务器。 There should be an option available for connecting to a SAP message server that acts like a load balancer. 应该有一个选项可用于连接到充当负载平衡器的SAP消息服务器。

Does anyone have an idea how this works? 有谁知道这是如何工作的?

My working Hibersap example: 我工作的Hibersap示例:

final SessionManagerConfig sessionManagerConfig = new SessionManagerConfig("");

 sessionManagerConfig.setContext(JCoContext.class.getName()); sessionManagerConfig.setProperty(DestinationDataProvider.JCO_ASHOST, ""); sessionManagerConfig.setProperty(DestinationDataProvider.JCO_SYSNR, ""); sessionManagerConfig.setProperty(DestinationDataProvider.JCO_CLIENT, ""); sessionManagerConfig.setProperty(DestinationDataProvider.JCO_USER, ""); sessionManagerConfig.setProperty(DestinationDataProvider.JCO_PASSWD, ""); sessionManagerConfig.setProperty(DestinationDataProvider.JCO_LANG, ""); ... 

Instead of JCO_ASHOST and JCO_SYSNR , you have to provide 代替JCO_ASHOSTJCO_SYSNR ,您必须提供

  • JCO_R3NAME with the system ID of the target system 具有目标系统的系统ID的JCO_R3NAME
  • JCO_MSHOST with the message server host name or address 具有消息服务器主机名或地址的JCO_MSHOST
  • JCO_MSSERV with the message server port number JCO_MSSERV与消息服务器端口号
  • JCO_GROUP with the name of the logon group JCO_GROUP具有登录组的名称

See this file for a working example using JCo3. 请参阅该文件使用JCo3工作的例子。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM