cancel
Showing results for 
Search instead for 
Did you mean: 

How to deploy custom java code to SMP 3.0 SP05 server?

former_member197782
Participant
0 Kudos

Hi Experts,

I have created custom application in management cockpit and published standard agentry definitions to development server and after that I have done the configuration settings in JavaBE.ini file to connect to custom mobile app.

Done changes to class path and server class from cockpit which effect the Agentry.ini file in development server. Here also I have mapped class path for standard java code.

Now I have done changes to the Agentry application and the java code. We have got the standard SAP WM 6.2 java source code from SAP.

Published the custom agentry definitions to development server from editor and mapped customized java classes, BAPI's, POJO's & Stephandlers in config panel parameters and mapped the steplet in editor definitions.

I have copied the custom jar(ZXXX.jar) file to the java folder of the custom application along with standard WM java code & respective other.jar files and I included Agentryv5.jar as well.

Now I have modified the class path from cockpit which would point to the custom .jar file as below.

Class Path: ./ini4j.jar;./sapjco3.jar;./Java/Agentry-v5.jar;./Java;./Java/SAPWM-6.2.0.0.jar;./Java;./Java/SAPCommon-133461.jar;.java/ZWM.jar;

Restarted Agentry app and restarted SMP server. But I could not able to see the sub URL in startup.log file.

I am getting "Communications Error" from device and HTTP not found error in browser.

Could anyone please suggest the process of deploying the custom .jar file to SMP server & Modifications to JavaBE.ini , Agentry.ini file and also please correct me for the above steps.

Any help would be much appreciated.

Thanks & Regards,

Roopa M.

Hi

Accepted Solutions (1)

Accepted Solutions (1)

jason_latko
Active Contributor
0 Kudos

Roopa,

Your custom java should have nothing to do with your application not initializing properly.  What is in your custom code?  Are these extended and new classes?  Are there any errors in your startup log?  Is your editor the correct version to work with your server?  I made the mistake of publishing with an older editor last week and had your same symptom where the application URL did not show up and I got communications error also until I realized I was accidentally using an old incompatible editor plugin.

Jason Latko - Senior Product Developer at SAP

former_member197782
Participant
0 Kudos

Hi Jason,

Thanks for the prompt reply.

I am using Agentry Juno editor. I am extending GetWorkOrderFetchBAPI to retrieve more details and added additional object and all.

And I have created .jar file and pasted custom .jar file into the application java folder and mapped the custom .jar file path in cockpit SAP-JAVA connections.

But still the same error. I could not understand where i am missing the configuration.

SMP Server: SMP 3.0 SP05

Please suggest.

Thanks & Regards,

Roopa

Former Member
0 Kudos

Is your application using development or production logic (Agentry application logic and now how the SMP Server is installed)?

If you are using Production logic, you need to publish a new application version. In the zip file before you upload it to the server add the folder for Java and add your Jar file into it,  Then upload it to the server.

Also, the classPath you show you have added ".java/ZWM.jar".  It should be "./java/ZWM.jar"

Stephen

jason_latko
Active Contributor
0 Kudos

Roopa,

Did the application work properly before your customizations?  Just trying to figure out if it ever worked for you out of the box.

Jason Latko - Senior Product Developer at SAP

former_member197782
Participant
0 Kudos

Hi Stephen,

Thanks for the reply.

I am using the development logic of the application. I want to add the custom .jar file in development propspective.

So I have copied the custom .jar file to the java folder of the application and modified the class path from management cockpit.

Still the app is not getting loaded. Please suggest.

Thanks & Regards,

Roopa M.

former_member197782
Participant
0 Kudos

Hi Jason,

Yes the custom app which is published to development server is working with out java & agentry custom logic and app also got downloaded into the device.

I am having the issue when I am doing the custom agentry definitions and custom java code.

Please suggest on the configuration settings for custom agentry & Java mapping in .ini files.

What is the procedure?

Thanks & Regards,

Roopa M

jason_latko
Active Contributor
0 Kudos

Roopa,

There is no trick to this.  There are no changes required to your javabe.ini.  Not sure what you are doing wrong.  We need to identify the problem point.  So if you remove your custom jar from the classpath and restart the server, does the application load properly?  If yes then something is wrong with your jar.  If no, try publishing using the out of box editor definitions.  Does it load then?  If yes then something is wrong with your custom editor definitions.

Jason Latko - Senior Product Developer at SAP

former_member197782
Participant
0 Kudos

Hi Jason,

Thanks for the reply.

I am not changing anything in JavaBE.ini file when I deploy the custom Java code. And my app is working fine without custom jar files.

Still now I have made customization to ABAP code and config panel and these changes are successfully reelected the the application and every thing seems to be working fine.

Now I want to customize the Agentry editor definitions & java code for some screen level changes. Please see below for the procedure and correct me if I am wrong.

Agentry definitions Customization:

Build the required customization in agentry editor and publish to development server these would directly effect the app.

JAVA Customization:

  1. I have standard SWM 6.2 Java source code which is delivered by SAP. But this code has many other components like meter management etc.
  2. But I would require only the classes related to work manager. So I want to make changes to classes where ever required.
  3. Convert the source code (related to work manager) to .jar file.
  4. Copy the custom .jar file to java folder of the development server along with standard SAP work manager 6.2.0.jar file.
  5. Modify the class path with custom .jar file from management cockpit.
  6. Map custom steplet in agentry editor fetches-->steps
  7. Map the stephandler to config panel stephandler
  8. Map Java object to config panel SAPOBJECT
  9. Map custom BAPI to config panel BAPI_WRAPPER
  10. Restart server

I assume this would be the procedure. Kindly suggest me for the above and let me know for any changes in development & Configurations

Any help would be much appreciated.

Thanks & Regards,

Roopa M.

former_member197782
Participant
0 Kudos

Hi Jason,

Thanks for your support. The issue got resolved with java source code. As you said there is no trick to do this.

I have just modified the required BAPI, Object and converted the java code to .jar file. Deployed the custom .jar file to java folder of the application.

Mapped the custom jar files path with BAPI_WRAPPER, SAPOBJECT,STEPHANDLER in config panel.

Modified the class path with custom jar file and then restarted the server.

This resolved my issue. Many thanks for all your support.

Thanks & Regards,

Roopa M

jason_latko
Active Contributor
0 Kudos

Roopa,

What step was missing previously causing the error?  I am unclear what you corrected.  Also, don't forget to assign helpful answers to those who took the time to help.

Jason Latko - Senior Product Developer at SAP

former_member197782
Participant
0 Kudos

Hi Jason,

Initially I mixed up all the changes and published all together into server. So I could not able find where the problem point is. But this time I have done the changes step by step like once I published ABAP customization after that config panel mappings.

Once these changes are working fine, I concentrated from JAVA prospective. Here also I have done changes first at SAPOBJECT after that BAPI later with STEPHANDLER.

And subsequent changes in config panel, In my case I forgot to make the parameter mapping active for one object definition.

When I active the flag, the java code seems working well.

Initially I zipped both java code and agentry application folder and deployed from cockpit in development environment. This process disabled the backend connection for my app and app is not getting loaded into device and got "Communications Error".

So for development environment, we dont't need to make any ZIP files to deploy from cockpit. We just have to copy the jar files into the java folder of the application.

These are the mistakes I have done. Many thanks to all who posted for this thread.

Thanks & Regards,

Roopa M.

Answers (0)