The following WebSphere Work Area APIs and SPIs are not available on Liberty:
com.ibm.websphere.workareacom.ibm.wsspi.workareaThis rule flags any instance of these packages once per Java class. You must modify the application so that it can run on Liberty.
Although no exact alternatives exist, review the following migration suggestions.
Take note which features of Work Area APIs and SPIs are used in your code and consider which features are needed. Refer to the com.ibm.websphere.workarea Javadoc.
Some of the more difficult features to migrate from are:
PropertyModeTyperead_onlyfixed_normalfixed_readonlycom.ibm.websphere.appserver.api.DistributedMap
DistributedMap accesses the WebSphere local cache to store key, value Object pairsJNDI at services/cache/distributedmapjava.lang.ThreadLocal
Object at a thread-scopeThreadLocal (using its get or set method) has its own, independently initialized copy of the variableThreadLocal instances are typically private static fields in classes that associate state with a thread (for example, a user ID or transaction ID)java.lang.InheritableThreadLocal
ThreadLocal to provide inheritance of values from parent thread to child threadJDBC driver so that an application that is running on your Open Liberty server can connect with a relational database, such as IBM Db2, PostgreSQL, Microsoft SQL Server, or MySQL. Learn moreCDI producer to provide access to a NoSQL database, such as MongoDB or CouchDB. Learn moreDistributedMap exampleThis example shows how you can migrate to DistributedMap if your application does not need any of the difficult features to migrate from, which are listed in the Evaluate usage section.
The default WebSphere Dynamic Cache instance is created when the cache is enabled in the administrative console and is bound into the global JNDI namespace with the name services/cache/distributedmap. More cache instances can be created by using a properties file cacheinstances.properties or by defining a resource-ref for in cache in your module's deployment descriptor.
Read more and see example code in the Open Liberty Documentation for DistributedMap:
|
|
|---|---|
|
|
|
Mostly not applicable, but consider invalidating keys in a DistributedMap if you no longer need them |
|
|
|
Not applicable |
|
Not applicable |
|
Alternatively, you can set |
|
|
|
|
|
Not applicable |
For information about other APIs and SPIs that are not supported on Liberty, see Some APIs and SPIs are not available on Liberty.