Greengrass StreamManager dependency - edit LOG_LEVEL

0

I would like to configure the LOG_LEVEL parameter of the aws.greengrass.StreamManager component.

StreamManager is pulled in as a dependency in a recipe:

{
  "RecipeFormatVersion": "2020-01-25",
  "ComponentName": "com.custom.KinesisStream",
  "ComponentVersion": "1.0.0",
  "ComponentDescription": "Uses stream manager to stream data to Kinesis",
  "ComponentPublisher": "MyCompany",
  "ComponentDependencies": {
    "aws.greengrass.StreamManager": {
      "VersionRequirement": "^2.0.0"
    }
  },
  "Manifests": [
    {
      "Platform": {
        "os": "linux"
      },
      "Lifecycle": {
        "Run": "python3 {artifacts:path}/stream_manager_kinesis.py"
      }
    }
  ]
}

Could someone provide the syntax for editing the LOG_LEVEL parameter in this recipe, if that is even possible?

I wasn't able to find an example of doing this specifically.

Thanks

ttnickb
gefragt vor 2 Jahren247 Aufrufe
2 Antworten
1
Akzeptierte Antwort

Hi @ttnickb,

You cannot change the configuration of your dependencies using your recipe. Instead, you do this in a deployment. Please review the available configuration for Stream manager here: https://docs.aws.amazon.com/greengrass/v2/developerguide/stream-manager-component.html#stream-manager-component-configuration and how to set configurations in a deployment here: https://docs.aws.amazon.com/greengrass/v2/developerguide/update-component-configurations.html#merge-configuration-update.

Cheers, Michael

AWS
EXPERTE
beantwortet vor 2 Jahren
  • Thanks Michael. I created a merge config file update.json as follows:

    {
      "aws.greengrass.StreamManager": {
        "MERGE": {
          "LOG_LEVEL": "TRACE"
        }
      }
    }
    

    And issued the following command: sudo /home/user/greengrass/v2/bin/greengrass-cli deployment create --recipeDir /home/user/recipes --artifactDir /home/user/artifacts --merge "com.custom.KinesisStream=1.0.0" --update-config update.json

    However, I am still seeing the default LOG_LEVEL config of "INFO" for aws.greengrass.StreamManager.

    Do you see anything incorrect with my above workflow?

  • You did not include stream manager in your deployment. Include --merge "aws.greengrass.StreamManager=<version>"

  • Hi @MichaelDombrowski-AWS, is there a way to set a configuration for dependency during deployment through AWS console?

0

Thanks Michael, that worked.

ttnickb
beantwortet vor 2 Jahren

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen