In IBM® DevOps Test Integrations and APIs (Test Integrations and APIs), tests and stubs reference the logical
resources in a project. Therefore, you must create at least one logical
MQ telemetry transport connection for each MQ telemetry transport
to be used.
Ensure that there is at least one environment in your project.
If there are no environments, you must create one.
- Open the Logical View of the Architecture School perspective.
- On the toolbar of the Logical View, click .
The New MQTT Connection window
is displayed.
- In the Name field, enter a name
for the connection.
- Click OK.
The New
MQTT Connection window is closed and the new logical MQTT
connection is displayed in the canvas of the Logical View.
- When a logical connection is created, a new physical resource
is also created and bound in this environment. To view or edit this
physical resource, right-click the new connection and click Physical
Resource.
- Double-click the new logical MQTT connection.
The MQTT
Connection window is displayed.
Alternatively, right-click
the logical MQTT connection and click Open in
the pop-up menu.
- To associate the new logical MQTT connection with a different
logical resource, complete the following tasks:
- Click Parent.
The Select
a Resource window is displayed.
- Under Logical, select a different
parent resource.
- Click OK.
The Resource
Path field on the Properties tab
of the MQTT Connection window displays the updated
resource path information.
- Optional: Click the Bindings tab.
Alternatively, click in the menu
bar to open the Environment Editor window and
click the Bindings tab to modify the bindings
of the selected environment.
If you did not bind the
MQTT connection to a physical MQTT broker, UNBOUND is
displayed under Binding and you must complete
the following tasks:
- Clicking UNBOUND displays a list
of all physical MQTT brokers in your project.
- Select a physical MQTT broker. If there are no physical
MQTT brokers displayed, you must create one.
- Optional: To add a log file for the new logical
MQTT connection, click the Monitoring tab.
The log file can be monitored during the execution of a test
that involves the new logical MQTT connection.
- Optional: To enter additional information about
the new logical MQTT connection, click the Documentation tab.
Although this additional information is optional, it might help with
the maintenance of the resources in the project or help future users
of the project.
- Optional: To specify a collection of topics
that should be recorded when using an MQTT broker as a source, click
the Recording tab. This action is needed is
because MQTT brokers use topics to determine which subscribers should
receive messages published to a broker. You must insert each topic
on a new line under Filter.
For
subscriptions, the following two wildcard characters are supported:
- A number sign (
#) character represents a complete
subtree of the hierarchy, so it must be the last character in a subscription
topic string.
- A plus sign (
+) character represents a single
level of the hierarchy and is used between delimiters (/).
- Click OK.
The new logical MQTT connection is added to the project.