<dependency>
<groupId>org.mule.connectors</groupId>
<artifactId>mule-remedy-connector</artifactId>
<version>x.x.x</version>
<classifier>mule-plugin</classifier>
</dependency>
BMC Remedy Connector - Mule 4
BMC Remedy Connector v3.0
Anypoint Connector for BMC Remedy (BMC Connector) is built with the BMC Remedy AR System Java API v8.1 and is compatible with BMC Remedy AR System 7.x and later. The connector exposes methods for performing CRUD operations on BMC Remedy AR System.
The BMC Remedy Connector functions within a Mule application as a secure entrance for access and updates to your organization’s information in the BMC Remedy AR System.
Your application can perform several operations that BMC Remedy AR System exposes via RPC, When building an application that connects with BMC Remedy AR System.
Release Notes: BMC Remedy Connector Release Notes
Exchange: BMC Remedy AR System Connector
Before You Begin
To use this information, you should be familiar with BMC Remedy API, Mule, Anypoint Connectors, Anypoint Studio, Mule concepts, elements in a Mule flow, and Global Elements.
To use the BMC Remedy connector, you need:
-
BMC Remedy AR System - A BMC Remedy AR server instance v7.x or later. The connector has been tested against a BMC Remedy AR server v9.1 instance. See the BMC installation instructions link in the See Also section of this document.
-
BMC Remedy AR System Java API v8.1 - You can download it using the link in the See Also section of this document.
POM File Information
Replace x.x.x
with the version that corresponds to the connector you are using.
To obtain the most up-to-date pom.xml
file information, access the connector in Anypoint Exchange and click Dependency Snippets.
Add the Connector to a Studio Project
Anypoint Studio provides two ways to add the connector to your Studio project: from the Exchange button in the Studio taskbar or from the Mule Palette view.
Add the Connector Using Exchange
-
In Studio, create a Mule project.
-
Click the Exchange icon (X) in the upper-left of the Studio task bar.
-
In Exchange, click Login and supply your Anypoint Platform username and password.
-
In Exchange, search for "bmc".
-
Select the connector and click Add to project.
-
Follow the prompts to install the connector.
Add the Connector in Studio
-
In Studio, create a Mule project.
-
In the Mule Palette view, click (X) Search in Exchange.
-
In Add Modules to Project, type "bmc" in the search field.
-
Click this connector’s name in Available modules.
-
Click Add.
-
Click Finish.
Configure in Studio
-
Click the Global Elements tab at the base of the canvas.
-
In the Global Mule Configuration Elements screen, click Create.
-
In the Choose Global Type wizard, expand Connector Configuration and select Remedy Configuration and click OK.
-
Configure the parameters according to instructions below.
Parameter Description Name
Enter a name for the configuration to reference it.
Username
Enter the user name.
Password
Enter the password.
Server
Enter the IP address of the AR server responsible for handling login requests.
Server Port
Enter the port number at which the AR server is configured to handle the requests.
Authentication
Enter the authentication string alias. The Authentication String Alias can be used to identify the correct authentication domain for the user.
Locale
Enter the locale.
The placeholder values refer to a configuration file
mule-artifact.properties
placed in thesrc/main/resources
folder of your project. You can either enter your credentials into the global configuration properties, or reference a configuration file that contains these values. For simpler maintenance and better re-usability of your project, Mule recommends that you use a configuration file. Keeping these values in a separate file is useful if you need to deploy to different environments, such as production, development, and QA, where your access credentials differ. -
Keep the Advanced tab which has Reconnection strategy with their default entries.
-
Click Test Connection to confirm that the parameters of your global configuration are accurate, and that Mule is able to successfully connect to your instance of BMC Remedy AR System.
-
Click OK to save the global connector configurations.
-
Your configuration should look like this:
XML and Maven Support
When you add the connector to your project in Studio, the namespace, schema location, and POM file information automatically are created for you. If you want to create a Mule app without using Studio, use this information:
Namespace: http://www.mulesoft.org/schema/mule/remedy
Schema Location: http://www.mulesoft.org/schema/mule/remedy/current/mule-remedy.xsd
POM file information:
<dependency>
<groupId>com.mulesoft.connectors</groupId>
<artifactId>mule-bmc-remedy-connector</artifactId>
<version>x.x.x</version>
<classifier>mule-plugin</classifier>
</dependency>
Replace x.x.x
with the version that corresponds to the connector you are using.
To obtain the most up-to-date pom.xml
file information, access the connector in Anypoint Exchange and click Dependency Snippets.
Use Case: Create a User
This Mule flow creates a user in the BMC Remedy AR System using the Create operation.
-
Create a new Mule Project in Anypoint Studio.
-
Add the following properties to the
mule-artifact.properties
file to hold your Remedy credentials and place it in the project’ssrc/main/resources
directory.config.username=<Username> config.password=<Password> config.server=<Server> config.serverPort=<Server Port>
-
Drag an HTTP Listener component onto the canvas and configure the following parameters:
Parameter Value Display Name
HTTP
Extension Configuration
If no HTTP Listener configuration has been created yet, click the plus sign to add a new HTTP Listener Configuration. Specify the Host as localhost and the Port with the 8081 value.
Path
/createUser
-
Drag Transform Message component next to the HTTP Listener and specify the necessary data.
The data mapping should be like this:
-
Drag the Remedy Connector Create operation next to the Transform Message component from the Mule Palette.
-
Configure the Remedy connector by adding a new Remedy Global Element. Click the plus sign next to the Connector Configuration field.
-
Configure the global element according to the table below:
Parameter Description Value Name
Enter a name for the configuration to reference it.
<Configuration_Name>
Username
Enter the Username
${config.username}
Password
Enter the Password
${config.password}
Server
Enter the IP of the AR server responsible for handling login requests.
${config.server}
Server Port
Enter the port number on which the AR server is configured to handle the requests.
${config.serverPort}
Your configuration should look like this:
The corresponding XML configuration should be as follows:
<remedy:config name="Remedy_Configuration" doc:name="Remedy Configuration"> <remedy:basic-connection username="${config.username}" password="${config.password}" server="${config.server}" serverPort="${config.serverPort}" /> </remedy:config>
-
Click Test Connection to confirm that Mule can connect with the BMC Remedy AR system instance. If the connection is successful, click OK to save the configuration. Otherwise, review or correct any incorrect parameters, then test again.
-
In the properties editor of the Remedy Create operation, configure the remaining parameters:
Parameter Value Display Name
Create (or any other name you prefer).
Extension Configuration
Remedy_Configuration - the reference name to the global element you have created.
Remedy Form Type
User - the form type that you want to create.
Entry
#[payload]
-
Add a Logger component after the Create operation to print the ID that is being generated from the Create operation in the Mule Console. Configure the Logger according to the table below.
Parameter Value Display Name
Logger (or any other name you prefer)
Message
#[payload]
Level
INFO
-
Save and Run the project as a Mule Application. Right-click the project in Package Explorer and click Run As > Mule Application.
-
Open a browser and check the response after entering the URL
http://localhost:8081/createUser
. You should see the generated ID in the browser and in the Mule console.
Use Case XML - Creating a User
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns:remedy="http://www.mulesoft.org/schema/mule/remedy"
xmlns:ee="http://www.mulesoft.org/schema/mule/ee/core"
xmlns:dw="http://www.mulesoft.org/schema/mule/ee/dw"
xmlns:http="http://www.mulesoft.org/schema/mule/http"
xmlns="http://www.mulesoft.org/schema/mule/core"
xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/ee/dw
http://www.mulesoft.org/schema/mule/ee/dw/current/dw.xsd
http://www.mulesoft.org/schema/mule/http
http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.mulesoft.org/schema/mule/core
http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/ee/core
http://www.mulesoft.org/schema/mule/ee/core/current/mule-ee.xsd
http://www.mulesoft.org/schema/mule/remedy
http://www.mulesoft.org/schema/mule/remedy/current/mule-remedy.xsd">
<configuration-properties file="mule-artifact.properties"/>
<http:listener-config name="HTTP_Listener_config"
doc:name="HTTP Listener config">
<http:listener-connection host="localhost" port="8081" />
</http:listener-config>
<remedy:config name="Remedy_Configuration" doc:name="Remedy Configuration">
<remedy:basic-connection
username="${config.username}"
password="${config.password}"
server="${config.server}"
serverPort="${config.serverPort}" />
</remedy:config>
<flow name="create-user-flow">
<http:listener config-ref="HTTP_Listener_config"
path="/createUser" doc:name="HTTP"/>
<ee:transform doc:name="Transform Message">
<ee:message >
<ee:set-payload ><![CDATA[%dw 2.0
output application/java
---
[{
"2": "Submitter1",
"7": "Current",
"8": "Short description1",
"Login Name": "Mule_soft"
}]]]></ee:set-payload>
</ee:message>
</ee:transform>
<remedy:create config-ref="Remedy_Configuration" type="User" doc:name="Create">
</remedy:create>
<logger message="#[payload]" level="INFO" doc:name="Logger"/>
</flow>
</mule>