on 06-05-2015 7:42 AM
Dear All,
I had SMP3.0 SP07 PL02 server, I follow a guide for implement my first project. I had CUSTOM and BEP Service setup on the cockpit (ZFLIGHT_PROJECT and ZBAPI) like the following:
ZBAPI Service is calling the same FM and deployed by Java IDE. I able to "open source document" for BEP Service like the following
But I'm not able to "open source document" for ZBAPI that deployed via JAVA IDE like the following with error "Internal_server_error":
Please advise.
Thank you.
Regards
Marcus
Hi JK and Pavel,
Currently I'm able to create Custom and BEP services in IGW, possible I can know how is the linkage/purpose between Custom and BEP and how to consume these service in iOS development?
I will open another discussion but i hope i can get some idea before open the new discussion.
Regards,
Marcus
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Following is the xxx.smp-server.log but as mentioned previously, the last update was 4th of Jun 2015.
2015 06 04 19:04:36#+0800#ERROR#com.sap.gateway.core.service.repository.api.ServiceRepositoryAPIHandler##anonymous#Framework Event Dispatcher###[Gateway][TECHNICAL][ApiHandlerGetServiceFailed]:Error in getting the service. Exception: java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory. |
2015 06 04 19:04:36#+0800#ERROR#com.sap.gateway.core.service.repository.api.ServiceRepositoryAPIHandler##anonymous#Framework Event Dispatcher###java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory. com.sap.gateway.core.service.exception.ServiceRepositoryException: java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory.
at com.sap.gateway.core.service.dao.CustomServiceDAO.getService(CustomServiceDAO.java:38)
at com.sap.gateway.core.service.repository.api.ServiceRepositoryAPIHandler.getServiceEntity(ServiceRepositoryAPIHandler.java:232)
at com.sap.gateway.core.service.ljs.registry.ServiceRegistrationActivator.bundleChanged(ServiceRegistrationActivator.java:143)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:847)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
Caused by: java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory.
at org.eclipse.persistence.internal.jpa.EntityManagerFactoryDelegate.verifyOpen(EntityManagerFactoryDelegate.java:306)
at org.eclipse.persistence.internal.jpa.EntityManagerFactoryDelegate.createEntityManagerImpl(EntityManagerFactoryDelegate.java:277)
at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:304)
at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:289)
at com.sap.gateway.core.service.dao.DBPersistence.getEntityManager(DBPersistence.java:136)
at com.sap.gateway.core.service.dao.CustomServiceDAO.getService(CustomServiceDAO.java:22)
... 5 common frames omitted
|
2015 06 04 19:04:36#+0800#ERROR#com.sap.gateway.core.service.ljs.registry.ServiceRegistrationActivator##anonymous#Framework Event Dispatcher###[Gateway][TECHNICAL][LjsSrvRegGetSrvError]:Error in getting registered service. Exception: java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory. |
2015 06 04 19:04:36#+0800#ERROR#com.sap.gateway.core.service.ljs.registry.ServiceRegistrationActivator##anonymous#Framework Event Dispatcher###java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory. com.sap.gateway.core.service.api.exception.ServiceRepositoryAPIException: java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory.
at com.sap.gateway.core.service.repository.api.ServiceRepositoryAPIHandler.getServiceEntity(ServiceRepositoryAPIHandler.java:239)
at com.sap.gateway.core.service.ljs.registry.ServiceRegistrationActivator.bundleChanged(ServiceRegistrationActivator.java:143)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:847)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
Caused by: com.sap.gateway.core.service.exception.ServiceRepositoryException: java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory.
at com.sap.gateway.core.service.dao.CustomServiceDAO.getService(CustomServiceDAO.java:38)
at com.sap.gateway.core.service.repository.api.ServiceRepositoryAPIHandler.getServiceEntity(ServiceRepositoryAPIHandler.java:232)
... 4 common frames omitted
Caused by: java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManagerFactory.
at org.eclipse.persistence.internal.jpa.EntityManagerFactoryDelegate.verifyOpen(EntityManagerFactoryDelegate.java:306)
at org.eclipse.persistence.internal.jpa.EntityManagerFactoryDelegate.createEntityManagerImpl(EntityManagerFactoryDelegate.java:277)
at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:304)
at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:289)
at com.sap.gateway.core.service.dao.DBPersistence.getEntityManager(DBPersistence.java:136)
at com.sap.gateway.core.service.dao.CustomServiceDAO.getService(CustomServiceDAO.java:22)
... 5 common frames omitted
|
Dear Choong,
The ZSFLIGHT_SERVER_PROJECT BEP service, I wonder why it has namespace SAP in your Gateway cockpit. This is the service you registered from your cockpit, from the MD1 destination I would assume? In my test, this should always have namespace IWBEP. Do you know why there is namespace SAP instead?
How is your destination configured please?
Otherwise the debug logs for Integration Gateway should be in Gateway Cockpit, under troubleshooting, as per the screenshot attached. Can you look there too if there are any useful logs?
Thanks.
Pavel
Hi Pavel,
Thanks for reply. The ZSFLIGHT_SERVER_PROJECT BEP service namespace is automatic added when i register service at cockpit. Will it possible that i install the IWBEP in SAP ECC and expose the OData services so that the name space is SAP?
To avoid confusion, I redeploy the custom service namespace to IWBEP and following is the latest screen shot.
My Destination was configure as MD1 and configure the URL as http://serverdomain/sap/iwbep?sap-client=100. Its ping successfully like the following:
Thanks for pointing the correct Integration Gateway and it display log on the cockpit like the following:
Error : while trying to invoke the method com.sap.gateway.core.api.srvrepo.IServiceInfo.getServiceName() of a null object loaded from local variable 'serviceInfo'
Regards,
Choong
Hi JK and Pavel,
I did try to use the demo service available on SAP Gateway Demo system and deploy as same as your guide provided like the following:
But i failed with the same error when i access the following:
https://server:8084/gateway/odata/SAP/SAMPLEFLIGHT;v=1/CarrierCollection('AA').
Hope someone can support me.
Regards,
Marcus
Hi Marcus,
I tried the same steps on my local installation, as per the guide, and for me it works.
Please, check the following three steps first and let me know.
1. Change target runtime to SP07 in Eclipse
2. In Eclipse create the Data Source for CarrierCollection entity set as follows:
3. Redeploy the project to IGW, under namespace SAP.
4. Test with URL: https://smp30pp:8083/gateway/odata/SAP/SAMPLEFLIGHT;v=1/CarrierCollection('AB')
Note that in your URL above, you have 'AA', but there is no Carrier with 'AA' ID, so use 'AB' instead please.
Fingers crossed! Pavel
Hi JK and Pavel,
Thanks for your advise. Following is the step i change the data source and deploy as NameSpace = SAP.
Change the URL to /CarrierCollection('AB') the following is the outcome.
Regards
Choong
Awesome.. That is my typo on the data source name and currently my SMP server able to work with SAP Gateway Demo System.
Back to OData in my SAP gateway, based on the SAP Gateway testing, it proved that my SMP server is working without error. Can you suggest how to troubleshooting the SAP gateway?
Regards
Choong
Great!!
How is your SAP landscape? Is it an embedded system or hub deployment (frontend and backend)?
Lets try this:
1. Delete both services ZBAPI and ZSFLIGHT_PROJECT_SRV from Registered Services list
2. Register it again (directly on IGW > Register>Search) >> Are you able to execute it?
Can you configure debug logging for IGW and check the Troubleshooting section? As per the procedure below?
Regards,
JK
Hi Choong,
Please try as follows:
1. In Eclipse create a new project for runtime SP07 - with any name
2. New ODATA Model, any name, select type ODC, ODATA Service URL: use your full URL for the ZSFLIGHT_PROJECT_SRV service (does the URL: contain /sap/opu/odata/sap/ or /sap/opu/odata/IWFND/ or /sap/opu/odata/IWBEP/?)
3. Create Data Source as follows (and use SAP as NameSpace) for all the entity sets, assuming that the ODATA service URL contains SAP and not IWFND or IWBEP:
4. Deploy to IGW with any name and SAP namespace (here the namespace does not really make a big difference).
PS. I tried with my GW service, that is in SAP namespace (not IWBEP or IWFND), then it also shows namespace as empty in search services - but using SAP, as namespace in Eclipse, works for me.
Fingers crossed!
Pavel
Hi Pavel,
Thanks for the step and it did alert me of something which help me solve my problem.
Following is my root cause and hope it help can the others:
My root cause is because my SMP server is SP07 PL02 but my project created in Eclipse IDE is SP06.
So I update my SAP Development tools in Eclipse and create oData Project with SP07 did solve my problem.
Regards
Choong
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am assuming you have done that changes for both entitysets CarrierSet and FlightSet
Are you able to execute individual entity sets?
url: https://host:port/gateway/odata/SAP/ZBAPI;v=1/CarrierSet
https://host:port/gateway/odata/SAP/ZBAPI;v=1/FlightSet
Try deploying again with changing its version.
Is that service publicly available if i want to check at my end?
Increase server log settings for Integration Gateway in Admin cockpit to deug and Trace>Enabled. If error persists, look into logs.
Regards,
JK
Hi JK,
Thanks for your suggestion.
I tried to deploy with version 2 and setup the log setting to debug like the following:
I run individual entity set with https://host:port/gateway/odata/SAP/ZBAPI;v=1/CarrierSet
was failed with the same error also.
I check on the log and Trace but it didn't show anything.
Am I checking to the right log file?
Regards
Choong
I tried to adjust the time frame from May to Jun, The log is not showing any latest error.
As per the screen shot like the following, the problem is because I wrongly create a duplicated profile.
I had downloaded the smp.server.log and the last update was 4th Jun 2015, the log file is not updated even i restart the SMP server. Is that any problem here?
Besides, I'm apologize that the service is not publicly available service. May I know how to make it available publicly ?
Regards
Choong
<< I thought you might be trying with some publicly available service, i am not asking you to make any internal service as public)>>
Were you able to run ?https://host:port/gateway/odata/SAP/ZSFLIGHT_PROJECT_SRV;v=1/CarrierSet
and then https://host:port/gateway/odata/SAP/ZSFLIGHT_PROJECT_SRV;v=1/FlightSet
Above log screenshot is not related to your error. Do you see anything relevant in SMP server.log file under LOG FILES tab?
<I haven't try with others publicly available service and I will try it soonest possible, it will be great if you have any publicly service for me to test, Much appreciate if you have any>
Besides, I'm able to run the URL as suggest like the following:
I tried to find the LOG FILE tab and there is no any relevant log
Messages.log is empty. events.log and start.log did provide some info like the following:
Regards,
Choong
User | Count |
---|---|
84 | |
25 | |
12 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.