Message Image  

Editing properties in IBM Integration Bus v10 via the web UI and REST

 View Only
Tue July 14, 2020 06:44 AM

This article outlines the new ways that properties can be edited on IBM Integration Bus v10 objects now that MBX is no longer available.

Web UI

In IIB v10 the web UI replaces the functionality of MBX. One of the capabilities that has been added to the web UI to achieve this is the ability to edit properties on an integration node, integration server and on a message flow.

Editing the properties is as simple as selecting the resource from the tree view and then selecting the edit button in the top-right corner.

The editable properties are then listed in a table with a button on each row that allows the property to be edited.

It is possible to edit one or many properties before saving the changes and you will be warned if you try to close the edit panel without saving your changes.

The properties listed for the resources have been increased so that the set available for editing match the set that were available in MBX. These include component properties on an integration node, resource manager properties on an integration server and user-defined properties on a message flow.

REST API

New REST calls have been implemented so that properties can be viewed and edited. The calls allow editing of single properties or a group of properties with a single call.

Items in italics should be replaced with the values that you want to work with.

Integration node APIs

apiv1/properties
– PUT with a JSON array of properties allows setting of a group of properties on the execution group. The group can contain one or many properties.

apiv1/properties
– GET returns a list of properties of the EG and components.

apiv1/properties/property name?value=new value
– PUT allows setting of a single named property on the node

apiv1/components
– GET views all components

apiv1/components/component name
– GET views named component

apiv1/components/component name/properties
– GET views the named components properties

apiv1/components/component name/properties/property name?value=new value
– PUT allows setting of a single named property on the component

Integration server APIs

apiv1/executiongroups/eg name/properties
– PUT with a JSON array of properties allows setting of a group of properties on the execution group. The group can contain one or many properties.

apiv1/executiongroups/eg name/properties
– GET returns a list of properties of the EG and resource managers.

apiv1/executiongroups/eg name/properties/property name?value=new value
– PUT allows setting of a single named property on the execution group

apiv1/executiongroups/eg name/resourcemanagers
– GET views all resource managers

apiv1/executiongroups/eg name/resourcemanagers/RM name
– GET views named resource manager

apiv1/executiongroups/eg name/resourcemanagers/RM name/properties
– GET views named resource managers’s properties

apiv1/executiongroups/eg name/resourcemanagers/RM name/properties/property name?value=new value
– PUT allows setting of a single named property on the resource manager

Message Flow APIs

apiv1/.../messageflows/flowName/properties
– PUT with a JSON array of properties allows setting of a group of properties on the flow. The group can contain one or many properties.

apiv1/.../messageflows/flowName/properties/propertyName?value=new value
– allows setting of a single named property on the flow

N.B the URI to identify the message flow will change depending on the location of the flow when it is deployed to the server e.g. inside an application or library.

5 comments on"Editing properties in IBM Integration Bus v10 via the web UI and REST"

  1. Larisa Uspenskaya November 21, 2018

    Hi Jan,
    Thank you again! I repeat these steps without issues.
    One more question. REST API supports several types of Content-type: i.e. application/json, application/xml. Are there some advantages/disadvantages by choosing/using one of these formats? Or are they identical in terms of performance ? or where could I read about it ?
    Regards,
    Larisa

    Reply (Edit)
  2. Larisa October 29, 2018

    Hi,

    I wish to change the property maximumRateMsgsPerSec of the flow abcMaximumRateMsgSec, aber without results.

    I do:
    /apiv1/executiongroups/test/messageflows/abcMaximumRateMsgSec/properties/maximumRateMsgsPerSec?100=1

    & get no response from REST API. What do I do wrong?

    The command /apiv1/executiongroups/test/messageflows/abcMaximumRateMsgSec/properties gives me partly:

    Kind regards,
    Larisa Uspenskaya

    Reply (Edit)
    • Ian_Larner November 02, 2018

      @Larisa Hi,
      You should use a workload management policy for this. Create a WLM policy and then attach it to the flow. You can then update the WLM policy through the web UI/API. For more information about workload management policy, see https://www.ibm.com/support/knowledgecenter/en/SSMKHH_10.0.0/com.ibm.etools.mft.doc/bj58320_.htm
      Regards, Ian

      Reply (Edit)
      • Larisa Uspenskaya November 12, 2018

        Hi Jan,

        Thank you for the answer. A workload management policy is a good solution for a business case.

        My task is small & practical. I try to find an API REST alternative for the Integration API method setMaximumRateMsgsPerSec(int newValue)

        i.e. BrokerProxy.getLocalInstance().getExecutionGroupByName(“abc”).getMessageFlowByName(“abcMaximumRateMsgSec”).setMaximumRateMsgsPerSec(5);

        My questions are:
        – Could I edit the deployment property MaximumRateMsgsPerSec via REST API ?
        – How could I edit the property MaximumRateMsgsPerSec of a workload management policy via REST API ?

        Kind regards,
        Larisa

        Reply (Edit)
        • Ian_Larner November 15, 2018

          Hi Larisa,
          Thanks for the reply.

          In V10 the decision was made that any flow level properties covered by a WLM Policy could not be altered through the API/UI directly on the flow. Instead a WLMPolicy needs to be created and attached to the flow. The WLMPolicy can then be updated through the UI/API

          To edit the property MaximumRateMsgsPerSec of a workload management policy via REST API, you update (PUT) a new copy of the policy. For example, I tried this with the following steps:
          (See REST API doc for policyType/policyName.)

          You can check the policy before and after by command/API or in the web UI, which also gives you the policy URL.

          1) Get a copy of the current policy:
          curl 'localhost:4414/apiv1/policy/WorkloadManagement/MaxRate1' -H 'Accept: application/json'

          Response:
          {"type":"policy","uri":"/apiv1/policy/WorkloadManagement/MaxRate1","policyType":"WorkloadManagement","name":"MaxRate1","documentURI":"/apiv1/policy/WorkloadManagement/MaxRate1","data":[{"name":"additionalInstances","value":""},{"name":"commitCount","value":""},{"name":"commitInterval","value":""},{"name":"maximumRateMsgsPerSec","value":"1"},{"name":"notificationThresholdMsgsPerSec","value":""},{"name":"startInstancesWhenFlowStarts","value":""},{"name":"startMode","value":""},{"name":"processingTimeoutAction","value":""},{"name":"processingTimeoutSec","value":""}]}

          2) Change the maximumRateMsgsPerSec value in the policy structure, and then PUT the updated policy back:

          curl -X PUT 'localhost:4414/apiv1/policy/WorkloadManagement/MaxRate1' -H 'Content-type: application/json' -d '{"type":"policy","uri":"/apiv1/policy/WorkloadManagement/MaxRate1","policyType":"WorkloadManagement","name":"MaxRate1","documentURI":"/apiv1/policy/WorkloadManagement/MaxRate1","data":[{"name":"additionalInstances","value":""},{"name":"commitCount","value":""},{"name":"commitInterval","value":""},{"name":"maximumRateMsgsPerSec","value":"0"},{"name":"notificationThresholdMsgsPerSec","value":""},{"name":"startInstancesWhenFlowStarts","value":""},{"name":"startMode","value":""},{"name":"processingTimeoutAction","value":""},{"name":"processingTimeoutSec","value":""}]}'

          (You should get a 204 response.)

          Regards,
          Ian

          Reply (Edit)

#IntegrationBus(IIB)
#IIBV10
#REST