Category: Service

IBM App Connect – Integrate Maximo with Google Sheet, SalesForce, and ServiceNow

While having a break between projects, I have some free time to play around with IBM’s new toy: App Connect. After several years of working with Enterprise applications, I’ve got to a point where I can tell if a system is great or not after playing around with it for a short time.  Some examples of great systems or platforms I have experience with is Maximo (of course), React Native (for mobile development), and SAP. Some examples of *not so great* systems I played with include Oracle EBS, Infor SunSystems, and Maximo Anywhere mobile platform.
With App Connect, I can tell this is an excellent tool after going through a few beginner tutorials. I can immediately come up with some useful use case using it to enhance Maximo by integrating it with other cloud applications. Below are two examples:
1 – Using shared Google Sheets to collect project data such as Asset register, Spare-part BOM from vendors:
An operator can create different Google Sheets and then share them with EPC contractor or sub-contractor, asking them to copy/paste data from their internal design database, and the data will be sent over to Maximo automatically. This continuous data provision process will ensure a more complete and accurate asset database after the system is handed over to the operator.

2 – Linking Maximo with a Service Provider’s CRM or ticketing system to automate Service Request workflow: 

Obviously, companies have been integrating Maximo with other systems in similar scenarios for ages, but with App Connect, the implementation is so much simpler and effortless. The above scenarios took me less than 10 minutes to configure everything without writing a single line of code. For an enterprise-grade integration solution, which needs to be robust, secure, and has high performance, it will take a lot more effort than that, but surely, it will not take weeks or months using traditional methods which involve coding. This is great news for companies that need to react fast to changing processes.
I haven’t looked into details on the cost of this solution, but IBM’s cost model charging is based on the volume of messages exchanged via App Connect. It will be relatively cheap and easy to get started. The cost will only increase as you scale up your operation. For small operators which only need to send out a few hundred tickets a month, I guess they can even get away with the free Lite plans. So this is definitely worth considering.

Hope you enjoy it.

Creating high performance service using MaximoCache

Sometimes in our application, we need to build custom services that run when Maximo starts. We can extend the psdi.server.AppService class and register it with MXServer by inserting a new entry into the MAXSERVICE table. If the service executes slow-running queries, it is a good idea to cache the data in memory to improve performance. We can implement MaximoCache interface for this purpose. By doing this, we can initialize the service when MXServer starts and pre-load all data required by the service into JVM memory. When the service is called, it will only use cached data to provide instant response which gives a much better user experience. 
 
Below are the steps to create a sample service that loads all Location’s descriptions into memory. The service will provide a function to check if an input string matches a location’s description or not. We will call this check when the user enters an Item’s description and it will throw an error whenever the input matches with the description of any existing Location. This is not a very good use case. But for the sake of simplicity, I hope it gives you an idea of how it can be implemented.

1. Create a LocationCache class, implementing psdi.mbo.MaximoCache
interface:
  • For the getName() function, set a name for the cache, such as “LOCATION_CACHE”.
  • Create method loadData() to query and load all locations’
    description into a HashSet
  • Call the loadData() method in the init(), reload(), reload(String)
    function overridden from the MaximoCache interface
  • Create function isLocationExist(String) to check if an
    input String matches with a description contained in the HashSet

2. Create a LocationCheck class extending the psdi.server.AppService
class. Override the init() method to initialize a new LocationCache object and
add it to the MXServer’s cache.

 
3. Insert a new entry into the MAXSERVICE table to register with MXServer to initialize the service when Maximo starts. Sample SQL statement to insert the record as follows:

4. Extend the LocationSet class to override the fireEventsAfterDBCommit() method. Essentially this method will reload the cache whenever there is a change to location data. This will ensure that the information stored in the cache will always be in sync with the new update.

5. Create a FldDescription class to override the validate()
method, and associate it with the Item.Description field. In the validate()
method, we will check if the description entered is the same as a location’s description stored inside the cache and throw an error dialog if there is a
match.

You can view or download the full sample code from this GitHub repository: link

After deploying the code and associating the LocationSet to
the Location object and the FldDescription class the Description field of the
Item object, to test if the code works, open an Item and enter a description
that matches the description of a location, it should throw an error
message as in the image below:

To check if the cache is reloaded properly, create a new location or update an existing one, enter the description of the updated location to an item’s description, it should also throw an error message.