Mobile application integration
Once you have made the decision to develop either a native (iOS/Android) or web-based application for your mobile device the next major challenge becomes how do you integrate this application to your back-end applications such as your CRM or ERP system?
The unique presentation challenges faced by mobile app developers has fundamentally changed the way we create web applications. Previously HTML would be requested from a central server and rendered in 'browsers' at the client side. The new "Mobile App" paradigm involves the delivery of dynamic content using HTTP and AJAX, with communication taking the form of JSON data being passed over HTTP using REST services.
Consequently the integration challenge becomes, how to quickly expose your existing infrastructure to this new 'mobile delivery channel', while minimizing changes to your back-end infrastructure. Organizations that are able to achieve this quickly will be able to expose their traditional business models to entirely devices and demographics. MuleSoft provides significant value here, providing a simple mechanism, or mediation layer, between existing SOAP/XML based Web Services and REST/JSON applications. Additionally, they can easily orchestrate sophisticated composite applications from multiple back-end services, both REST and non-REST services, without the need to expose your internal object model to your external consumers.
You need to connect to a legacy application that does not have a REST API. For example, you have a custom CRM or HR system that you want employees to be able to access remotely.
You want to connect to multiple applications or data sources, then combine the data, sending the results to your mobile application. For example, enriching HR or customer information with data available on social networks like Facebook or LinkedIn. Another common example would be where a company has multiple CRM systems but wants to provide a unified view to anyone accessing customer data on the road.
You want to optimize device bandwidth usage by stripping data down to the minimum set needed by your application as well as compressing data.
In this use case, we will show how easy it is using MuleSoft to "RESTify" an existing application. By "RESTify" we mean creating a REST web service frontend to an existing application.
Let's say you wanted to enable your sales team to create a new sales opportunity from their mobile devices that;
- Is synchronized with your Salesforce implementation, and
- Sends an email notification to a manager if the opportunity is over a certain dollar value.
Integration core principles
Applying our five core integration principles a Mobile Application Integration use case typically involves the following:
|Transformation||Since we are going to consume this interface from a mobile application, the best choice for the data format is JSON, which is a protocol that is very easy to work with both in a mobile application and in Mule. In this case the challenge will be to transform the JSON data being received from our mobile device into a format that is can be loaded in SFDC. A simple JSON data object is presented below, which indicates the type of data being received from our Mobile App.|
|Transportation||Transport protocol negotiation between a REST (HTTP) based service that interacts with our Mobile Application and in our use case, with the SFDC system over HTTP and an additional email connection that uses the SMTP protocol.|
|Orchestration||Composing several underlying components into a single higher order composite service. In this use case we are aggregating an update with SFDC with a simple email service and presenting it as a REST-based Mobile Application using a simple Mule integration flow to wire everything together.|
|Mediation||Mediation will be useful here over time as it becomes necessary to support multiple versions of this service for a wide range of consumers. Additionally, it is possible (if required) to provide an additional SOAP interface for this REST-based service by simply adding the mediation components to marshal between SOAP/XML & JSON.|
|Non-functional consistency||These requirements are by nature generic and include providing a common implementation of security, logging, deployment, management of run-time components, and more. |
MuleSoft integration components
MuleSoft provides a simple graphical interface for composing these types of applications. The first step in communicating with a Mobile Application would be to use an HTTP endpoint coupled with a REST component. This step takes care of most of the complexity associated with communicating with your Mobile apps and consuming JSON objects. MuleSoft also simplifies the process of communicating with the Salesforce CRM system by providing a 'pre-built' cloud connector that you can drag into your project, specify your username and token, select the function that you want to call and you're done. Likewise, the process of adding filtering logic and communicating with an SMTP server for sending email is also greatly simplified.
So what have we accomplished? Using Mule as an ESB we've illustrated how easy it can be to leverage your existing applications and compose them into higher level REST services, which makes integrating with Mobile applications easy.
Further, we also showed how simple it is using the pre-built connector provided by MuleSoft to integrate between a mobile application and Salesforce. This is a significant achievement when you consider that one of the primary challenges people have faced with adopting cloud technologies such as SFDC has been integration, but MuleSoft simplifies this process greatly.
Mobile devices and application have opened up delivery channels to much wider audiences and demographics. MuleSoft allows you to respond to the new interaction models required by these devices and easily integrates with your existing systems, in a simple, scalable, reliable manner.
Next, explore MuleSoft's mobile integration solutions.