Developer

Preparing Agentry Applications With Java System Connections

When migrating an Agentry application to the SAP Mobile Platform Server 3.0, be sure to account for changes within the architecture that directly affect how the Java synchronization logic of the mobile application processes file references. Skip this information if your application does not include a Java system connection.

In releases of SAP Mobile Platform prior to 3.0 and Agentry Mobile Platform versions 6.0.x and earlier, the Java synchronization logic could reference file resources relative to the location of the Agentry Server publish directory (where Agentry.ini is located). In product-name 3.0, the current directory when processing the Java logic is no longer the publish directory.

To prepare Agentry applications for migration to SAP Mobile Platform 3.0, you modify the Java synchronization logic to change any references to configuration files or other resource files within the logic. In each case where such a file is referenced, replace it with a call to the method com.syclo.agentry.Server.findConfigurationFile within the Agentry Java API class com.syclo.agentry.Server. This method takes either the file name, or relative path and file name as its parameter, and returns the full path to the file. This return value can then be used in the same manner in which the previous relative file path was used to process a configuration file.

When making this change, first import all development resources, including the Java logic, as well as the Agentry application project into the Agentry Editor plug-in provided in the SAP Mobile Platform SDK. Update the AJ-API to the version provided with SAP Mobile Platform SDK 3.0. This API is contained in the Agentry-v5.jar file provided with SAP Mobile Platform SDK.

Continue with the migration steps to copy all the necessary resource files to the proper location for SAP Mobile Platform.