on 06-27-2014 11:01 AM
Dear community,
we do this steps:
Now we want only check if we could connect succesfully with the agentry server to the SAP ERP back-end.
How can we do this without to create a demo application?
Thanx,
André
Andre,
Assuming you have the SAPCommon jar file (part of SMP 2.3 SDK) you can execute the following to verify your connection to SAP.
set classPath=./ini4j.jar;./sapjco.jar;./Java/Agentry-v5.jar;./Java/SAPCommon-122971.jar;
rem --- run the simple ConnectTest class
java -cp %classpath% com.syclo.sap.ConnectTest
The version of the SAPCommon jar that you have may be different so replace with the name of your SAPCommon jar version. The ConnectTest class is in all the recent versions of the jar.
--Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear Bill,
i execute the following to verify my connection:
set classPath=./Java/ini4j-0.4.1.jar;./Java/sapjco3.jar;./Java/Agentry-v5.jar;./Java/SAPCommon-130881.jar;
java -cp %classpath% com.syclo.sap.ConnectTest
and now i get the following print:
reading user credentials from [SERVICE_LOGON] section
connecting as...
clientNum=040
sysNum=12
host=XXX.XXX.XXX.XX
name="my username"
*** Caught exception: com/sap/mw/jco/JCO
release::releasing connection
release::complete.
Was the connection successfully established our is this a error in my JCO File that the path is not correct?
Thanx,
André
Yes i do. And i have configured the [SERVICE_LOGON] section for the agentry server to login during initial startup.
André
here my JavaBE.ini:
[HOST]
server=XXX.XXX.XXX.XX
APPNAME="Appname"
[SERVICE_LOGON]
;The purpose of the [SERVICE_LOGON] is to set up a user(system user) for Agentry Server to login to SAP during initial startup.
ENABLED=true
UID=mySAP-UserName
UPASSWORD=mySAP-UserPassword
UPASSWORDENCODED=false
SERVERSERIALNUM=AVXMLJIOMDDIPLKH
[CONFIG]
source=SAP
[CLIENT_NUM]
CLIENT=040
[SYSTEM_NUM]
SYSNUM=52
[LANGUAGE]
LANG=DE
[LOGGING]
Level=3
[LOGON_METHOD]
LOGON_METHOD=USER_AUTH
[REQUIRED_BAPI_WRAPPER]
com.syclo.sap.bapi.LoginCheckBAPI=/SYCLO/CORE_SUSR_LOGIN_CHECK
com.syclo.sap.bapi.RemoteUserCreateBAPI=/SYCLO/CORE_MDW_SESSION1_CRT
com.syclo.sap.bapi.RemoteParameterGetBAPI=/SYCLO/CORE_MDW_PARAMETER_GET
com.syclo.sap.bapi.SystemInfoBAPI=/SYCLO/CORE_SYSTINFO_GET
com.syclo.sap.bapi.ChangePasswordBAPI=/SYCLO/CORE_SUSR_CHANGE_PASSWD
com.syclo.sap.bapi.CTConfirmationBAPI=/SYCLO/CORE_OUTB_MSG_STAT_UPD
com.syclo.sap.bapi.DTBAPI=/SYCLO/CORE_DT_GET
com.syclo.sap.bapi.GetEmployeeDataBAPI=/SYCLO/HR_EMPLOYEE_DATA_GET
com.syclo.sap.bapi.GetUserDetailBAPI=/SYCLO/CORE_USER_GET_DETAIL
com.syclo.sap.bapi.GetUserProfileDataBAPI=/SYCLO/CORE_USER_PROFILE_GET
com.syclo.sap.bapi.PushStatusUpdateBAPI=/SYCLO/CORE_PUSH_STAT_UPD
com.syclo.sap.bapi.RemoteObjectCreateBAPI=/SYCLO/CORE_MDW_USR_OBJ_CRT
com.syclo.sap.bapi.RemoteObjectDeleteBAPI=/SYCLO/CORE_MDW_USR_OBJ_DEL
com.syclo.sap.bapi.RemoteObjectGetBAPI=/SYCLO/CORE_MDW_SESSION_GET
com.syclo.sap.bapi.RemoteObjectUpdateBAPI=/SYCLO/CORE_MDW_SESSION_UPD
com.syclo.sap.bapi.RemoteReferenceCreateBAPI=/SYCLO/CORE_MDW_USR_KEYMAP_CRT
com.syclo.sap.bapi.RemoteReferenceDeleteBAPI=/SYCLO/CORE_MDW_USR_KEYMAP_DEL
com.syclo.sap.bapi.RemoteReferenceGetBAPI=/SYCLO/CORE_MDW_SESSION_GET
com.syclo.sap.bapi.RemoteReferenceUpdateBAPI=/SYCLO/CORE_MDW_SESSION_UPD
com.syclo.sap.bapi.RemoteSessionDeleteBAPI=/SYCLO/CORE_MDW_SESSION1_DEL
com.syclo.sap.bapi.RemoteUserDeleteBAPI=/SYCLO/CORE_MDW_SESSION1_DEL
com.syclo.sap.bapi.RemoteUserUpdateBAPI=/SYCLO/CORE_MDW_SESSION_UPD
com.syclo.sap.bapi.TransactionCommitBAPI=WFD_TRANSACTION_COMMIT
com.syclo.sap.bapi.SignatureCaptureBAPI=/SYCLO/CS_DOBDSDOCUMENT_CRT
Andre,
Try adding the following section to your JavaBE.ini. I am not positive which version of SAPCommon introduced support for JCO 3 but believe you need this setting in order for the JCO 3 to work. Otherwise if the SAPCommon is based on JCO2 you will need to have the correct sapjco.jar for JCO2.x in your classpath instead.
Also the Appname item should not be quoted. See my example below.
--Bill
[HOST]
server=hostname-here
; mobile application name configured in sap like SMART_WORK_MANAGER_51, SMART_CUSTOMER_SERVICE_10, SMART_ISU_WORK_MANAGER_10...etc
APPNAME=SAP_WORK_MANAGER_61
[JCO]
CLASS=JCO3
Hello André Nehm , As bill said follow the steps and can you execute your agentry server ? Once you run your server you could see that you have successfully connected to backend if not then it will throw error. Thanks & Regards, Kunal Varaiya
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.