research-virtualfortknox / node-red-contrib-msb

Nodes to connect to the Manufacturing Service Bus (MSB) developed by VFK Research (Fraunhofer IPA)
Apache License 2.0
2 stars 1 forks source link

It is not possible to use more than one msb-object nodes in one node-red instance #15

Open vfkceo opened 1 year ago

vfkceo commented 1 year ago

Describe the bug It is not possible to use more than one msb-object nodes in one node-red instance to connect different "smart objects" to an msb instance. It doesn't matter if you place the additional msb-object nodes in the same or different node-red flow.

To Reproduce Steps to reproduce the behavior:

  1. Precondition: First you can use the sample on Github or create a new flow with a working msb-object node, deploy and add it to the MSB-Instance. 20220829_NodeRed_Bug_0001 20220829_NodeRed_Bug_0002

Check that the data is transferred correctly. Use therefore MSB Logging mechanisms.

  1. Pick and place another msb-object nodes in the same flow. 20220829_NodeRed_Bug_0003

  2. Konfigure a different "smart object", name, uuid, token but the same MSB URL.

20220829_NodeRed_Bug_0004

  1. Create an event of the new smart object.

20220829_NodeRed_Bug_0005

  1. Deploy it. Then you see two connected msb-object nodes.

20220829_NodeRed_Bug_0006

  1. Register the new smart object into the corresponding msb instance via token.

20220829_NodeRed_Bug_0007

  1. After the new smart object is registered, the running smart object (XDK_1_Data) was disconnected (see black color of the object). You see the new smart Object has only sent 2 messages.

20220829_NodeRed_Bug_0008

  1. The former running smart object doesn't send any more. You can check this via logging mechanisms of the smart object in the msb.

20220829_NodeRed_Bug_0009

  1. Back in the node-red UI you can see the behavior of the disconnected smart object too . Some times you can see toggling of the connected status or both are in reconnecting state.

20220829_NodeRed_Bug_0010

  1. Additionally if you add an msb-event-node you can't chose the events of the newly added smart object "DigitalShaddow_1".

  2. If you delete the added smart object "DigitalShaddow_1" and deploy the flow, the smart object "XDK_1_Data" connects again and is running as intended.

  3. This bug is reproduceable in several implementations and instances.

Expected behavior You can use more than one msb-event-nodes in one node-red-instance to create more than one "smart object/application" with different characteristics in the msb and transfer data. It has to be possible to choose different msb-object-nodes in the msb-event-node (and msb-config node), so that you can choose corresponding data, events, etc. of the object.

Screenshots See above.

Environment (please complete the following information):

Additional context No.

ipamaas commented 1 year ago

Thank you for reporting this issue and the detailed description! We aggree that it would be useful to have more than one "smart object" represented by one node-red instance. We will analyze the issue and improve this behaviour in a future release.