Category: Resource

Federated MBO / JSON Resource – Filling the gap between Maximo and IoT

What is a Federated MBO?

Recently I got some time to explore the new Federated MBO feature. I like it a lot because it is simple to configure and quite powerful. Of course, prior to Maximo 7.6, the same functionality can be done with Java programming, but with this new feature, it is so easy to incorporate data from external systems into Maximo business logic and make a seamless experience to the end-users.

Basically, Federated MBO allows you to link an API from an external system and make it looks like a standard object in Maximo and treat it like other standard Maximo objects such as displaying data on GUI or setting up workflow conditions or writing automation script against it. The key difference here is that data is not stored inside Maximo database but queried from the API on-the-fly when the object is accessed.

Use Cases

I can immediately think of several applications that are enabled by this feature:

  • Integrate with Data Historian/SCADA: to display real-time operation conditions of assets. It is always beneficial for the asset managers to know the current conditions of the assets when planning works. Traditionally, operation conditions of critical assets can be imported/synchronized into asset meters for conditional monitoring PM or analytical reports. But it is not real time data. Generally, we don’t import every meter reading collected into Maximo. It will fill-up the database and consume valuable system resource. With this capability, we will only query data of a specific asset or location directly from an external system and don’t store it in the DB. However, we still can interact with the data as part of Maximo functionality which is a distinct advantage over other methods such as embedding the web page of an external system inside Maximo or directing user to a different web application
  • Integrate with security access systems: to display in real-time the current whereabouts of a worker. This could help with work planning and coordination activities.
  • Integrate with external service: to verify ID, Certificates etc. for the labour self-registration process.
  • Integrate with weather service to assist work planning process. For example, Maximo will warn the planner when planning to work if extreme heat, high UV, or heavy rain is forecasted. This allows them to plan the work on a different date or prepare proper PPE equipment to the workers. The same can be done if we deploy sensors to report temperature, noise level, humidity etc. on certain work locations.

Implementation

To demonstrate how the Federated MBO feature works, below is an exercise I did with OpenWeatherMap API. This API provides free access to 5-day weather forecast, UV Index forecast, and Air Pollution. In this example, I will link the UV Index forecast API and make it available as an MBO. When the user set a Scheduled Start Date, if UV Index is forecasted to be higher than 7, Maximo will display a warning message to remind the planner.

Step 1: Register OpenWeatherMap API account, and retrieve data on browser

  • Go to OpenWeatherMap.org to register a free account.
  • Sign-in with your new account, go to Account home page, open the “API keys” tab and copy your API key to use it to access the API.
  • Paste the following link into a new browser tab, replace the XXX with your API key, you should be able to retrieve JSON data of the UV Index forecast for the next 8 days as shown in the image below 
http://api.openweathermap.org/data/2.5/uvi/forecast?lat=-33.8688&lon=151.2093&cnt=7&appid=XXX
Test the OpenWeatherMap URL in browser
  • If you couldn’t retrieve the data, go to the site’s API document to read the instructions. It might have been updated. The OpenWeatherMap’s API syntax is very simple.

Step 2: Create a JSON Resource in Maximo

  • In Maximo, go to the Integration \ JSON Resource application. Under the More Actions menu, click Create JSON resource to start the wizard
  • Create a new Resource
    • Resource: OW_UVI
    • Resource Usage: OBJECT
    • Resource Type: REST
    • URL: <copy/paste the URL in the previous step above>
  • Note: for simplicity, we hardcode the latitude/longitude of the location in the URL. Once it works, you can dynamically populate the values from the main object by putting the field name inside a bracket such as:
    lat={LOCATIONS.LATITUDE}&lon={LOCATIONS.LONGITUDE}
  • Click Next 
  • Copy/Paste the sample JSON data we retrieved in previous step from OpenWeatherMap into the JSON Data text area. This allows Maximo to parse the data structure returned from the API for the next step
  • For Parent Object, enter “WORKORDER”. This will create a relationship on the “WORKORDER” object to point to the new JSON object “OW_UVI” we are creating
  • Click Next to proceed to the next screen. This screen summarizes how Maximo parsed and construct new MBO structure from the sample data provided.
  • Leave the default value, click Process to finish.

Step 3: Test the new JSON Resource

  • In the Database Configuration application, open the new OW_UVI object it just created for us. It also added a relationship OW_UVI in the WORKORDER object to link to this new mbo.
  • To check if our JSON resource can query data from the API correctly, use Application Designer, add a Table to anywhere, such as the “Map” tab. Open properties of the table, put OW_UVI as the relationship of the table. Add two columns and assign the DATE_ISO and VALUE field to the two columns. 
  • Open the Work Order Tracking app, open any work order, the table will display some UV forecast data:

Step 4: Create a warning using Automation Script

  • Open the Database Configuration app, choose Action > Messages to open the Message dialog. Create a new Warning Message:
    • Message Group: WOTRACK
    • Message Key: HighUVI
    • Value: High UV Index is forecasted for the scheduled date. Ensure proper sun protection PPE has been planned.
  • Note: the Message Group and Message Key fields are case-sensitive. Thus, in automation script, we should use the exact case in order for the message to be displayed
  • Open Automation Script app, Create an Attribute Launch Point:
    • Launch Point: SCHEDSTART
    • Object: WORKORDER
    • Attribute: SCHEDSTART
    • Event: Validate 
  • Click Next to the next screen, give the script a name such as Check_UVI choose Python as language
  • Click Next. Copy/Paste the following source into the Source code text area, then click Create to finish creating the script
  • In this script, I compare and identify if the Scheduled Start Date is in the next 8 days, and if the UV Index is higher than 7. If this condition is met, Maximo will display the warning we created above.

Extras

With Maximo 7.6, we can setup to assign Service Address to Location with coordinate of the location. When a Work Order is created against a location, it will inherit the coordinate of the location. We can use it to fill into the parameter of the API request, and retrieve the actual forecast of the Work Order’s location.  If you’ve read my previous post on creating custom chart control, we can also modify the app to display UV Index forecast in a chart for visualization. A planner after receiving the warning can then open the “Map” tab to see the location of the work, and see the UV Index forecast on a chart to determine what day is better to carry out the work.

I hope you have fun with this new Maximo feature. If you can think of any creative application using this feature to make Maximo better, please suggest by leaving me a comment. I would love to try it out

Free Maximo Training Resources

Our company employees usually wear the T-shirt that has IBM Tivoli and Maximo logos on it. Because of that, for many times, I was approached by random guys on the street to talk about Maximo. In a few cases, they mentioned that they want me to provide materials to learn about Maximo or give them basic Maximo training. I have a few friends who work in IT and like to learn about Maximo too. So I think it would be helpful for some of you out there to know that you can learn and practice with the software completely free with the resources provided by IBM. In this post, I’ll provide some information and links to some of these sources:
Access to Maximo training environment:
You can access and play around with Maximo using the IBM’s preview environment using the following links or googling “Maximo Asset Management Preview Site”. Accessing this environment is completely free and open to the public.

          Maximo 7.5: http://www-01.ibm.com/support/docview.wss?uid=swg21499350 
The core functionality of the two versions are exactly the same, so any version would be ok for you to learn and play around.
(One side note: if you are serious on being a consultant or need to install your own Maximo system for advanced implementation training or for integration purposes, you can purchase the IBM Software Value Package ($999) to get access to the Software Access Catalog where you can download almost all software provided by IBM including all Maximo versions, industry solutions and add-ons. If you are a business partner and want to have access to different Maximo industry solutions and add-ons such as Oil & Gas, Scheduler, Anywhere etc., you can contact IBM to provide you access to their Skytap environments too.)
Free Online Training courses:
IBM recently created a website at www.iot-academy.info to provide free interactive online training courses. The Asset Management courses provided here cover all Maximo core modules and applications. This should be the first place to visit if you want to learn the basic functionality of the software. The courses available on this site provide both trainings on the functionality and business processes of the software and training for implementer and administrator.
 

Several courses available on iot-academy.info

Besides the two main sites above, there are many training resources made available by IBM, business partners and individuals that you can access too:


YouTube: search for those keywords “IBM” “Maximo” “Demo” you can find a tone of webinars, demonstration, and training video recordings uploaded by IBM and other business partners. Some go quite deep into the functionalities of various applications and modules. (If you prefer to learn the software in Vietnamese, check out my previous post: Maximo Immersion Training
For customization, you should go to Bruno Portaluri’s blog. His Java Customization tutorial series is definitely the best and most comprehensive source that you can find on the web. Simply by spending some time to go through his tutorials, you will master Maximo customization in no time.

All of the training resources provided in this post are free. However, the content of these sites are quite organized and will be enough to make you a competent power user, administrator or consultant, depending on what are you looking for. So don’t bother looking elsewhere and spend a lot of money on expensive classes unless you prefer to learn more advanced topics.