Sybase Unwired Platform 1.2.4 introduces a new mechanism of caching mobile business object (MBO) data in memory that provides both faster synchronization and a lower overall memory requirement.
Note: The in-memory cache setting can be created for bulk-load MBOs only, in other words, MBOs that do not have playback parameters. The cached data is used for initial synchronization from the device. Unwired Server will read from the consolidated database for subsequent synchronizations from a device even if data is in the cache.
Use in-memory caching for the initial synchronization of large reference data MBOs. This setting is not meant to be used for smaller transactional MBOs where the data is usually partitioned by users and thus changing frequently so that a consolidated database (CDB) read is required for each subsequent synchronization. In most synchronization scenarios, where per MBO data to be downloaded is small in size, resulting in smaller reads from the CDB, performance is improved. However, in-memory caching improves performance when initial synchronization involves large sizes of reference data as Sybase Unwired Platform can use a shared copy of data, which significantly reduces the memory requirement.
Note: The Unwired Server download stream for each device client is still separate and an appropriate size of the synchronization server cache is required if concurrent device clients initiate synchronization server download streams.
HTTP APIs for managing the in-memory cache setting
A set of HTTP-based Admin APIs are provided to read MBO data into the in-memory cache, clear it from cache, and query whether it is currently in cache.
-
http://host:port/onepage/servlet/UWPServlet?app=uep&cmd=MobileObjectAdmin.enableInMemoryCache
&package_name=packageName&mobile_object_name=mboName
&authenticate.user=supAdmin&authenticate.password=s3pAdmin – reads MBO data into the in-memory cache. The response indicates whether the operation was successful or not.
-
http://host:port/onepage/servlet/UWPServlet?app=uep&cmd=MobileObjectAdmin.disableInMemoryCache
&package_name=packageName&mobile_object_name=mboName
&authenticate.user=supAdmin&authenticate.password=s3pAdmin – clears MBO data from the in-memory cache.
-
http://host:port/onepage/servlet/UWPServlet?app=uep&cmd=MobileObjectAdmin.queryMemoryCache
&package_name=packageName&mobile_object_name=mboName
&authenticate.user=supAdmin&authenticate.password=s3pAdmin – checks status of in-memory cache for an MBO. Unwired Server does not cache MBO data except by explicitly pinning the MBO in memory as shown above.
Nor does it remove it except when it receives a disableInMemoryCache.
The server returns an error response for enableInMemoryCache if there is no data in the MBO.
Note: This setting is not persistent. No cache-filling occurs automatically at Unwired Server startup. It must be done every time the server starts. It is also a per-node setting, not cluster-wide. So it must be set for each node separately.