Skip to content

New configuration for the package #25

@prasadtalasila

Description

@prasadtalasila

The proposal is to split the configuration into private (secret) and public parts. One suggestion is to have

Services Config

services.json having

{
  "MQTT": {
      "host": "mqtt.foo.com",
      "port": 1883,
      "userId": "",
      "password": "",
      "ClientID": "",
      "QoS": 1,
    },
  "InfluxDB": {
      "host": "mongodb.foo.com",
      "port": 1883,
      "apiToken": "",
      "organization": "",
      "bucket": "",
    },
  "MongoDB": {
      "host": "test.mosquitto.org",
      "port": 27017,
      "userId": "",
      "password": "",
      "database": "",
    },    
}

Function Blocks Config

blocks.json / functionBlocks.json having

{
  "blockName": {
    "services": {
      "MQTT": { # additional parameters only if needed
          "ClientID": "",
          "QoS": 1,
          "TopicsToSubscribe": [
            "cpsens/d8-3a-dd-f5-92-48/cpsns_Simulator/1_2/oma_results"
          ],
          "TopicsToPublish": [
            "cpsens/d8-3a-dd-f5-92-48/cpsns_Simulator/1_2/oma_results"
          ],
        },
      "InfluxDB": {}, # service to be specified only if needed
      "MongoDB": {},  # service to be specified only if needed
    },
    "parameters": {
      # function block specific parameters
  }
}

Ref: The background for this configuration is available in shared folder ("2022_IFD_CP-SENS\exchange\MQTT topics, data and metadata.pptx").

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions