Greengrass V2 Shadow Manager Manage all assigned devices

0

While setting up ShadowManager + MQTT Bridge + Moquette, we have the desire to configure the ShadowManager to manage all shadows for devices under its control.

By "under its control", I mean the devices you see listed if you go to Greengrass devices > Core devices > [MY GG DEVICE] > Client devices > Associated client devices

It looks like, right now, it will only sync from Greengrass-Instance -> Cloud on a "wildcard" basis (any shadow topic that pops up on the Moquette broker is automatically synced to the local shadow service regardless whether it's in the ShadowManager config), but wont necessarily sync all shadows from the Cloud -> Greengrass-Instance. We don't need all shadows, but would like to have the ShadowManager keep the assigned devices to it in-sync without having to call them out in the general group-deployment.

We're currently targeting Greengrass deployments at Groups rather than individual Greengrass-Instances, so configuring the ShadowManager during deployment wont work since each Greengrass-Instances in the group will have different device assignments. I think the workaround will be to create a union of thing-ids and just have all Greengrass-Instances under a group sync that superset.

Is there a better way to do this?

Casey
posta 2 anni fa313 visualizzazioni
1 Risposta
2
Risposta accettata

Hi Casey,

as you mention, the cloud to ShadowManager edge sync is based purely on the configuration of the ShadowManager component. You could do as you point out, include all possible DeviceId in the Shadow Manager configuration but that will imply: 1/ all Greengrass Cores sync all the shadows with an impact on local storage 2/ depending on the number of devices you might hit a deployment document size limit

My suggestion would be to deploy just the ShadowManager component using each core device as target. In this way each configuration can be tailored to reflect the devices which are attached to the Greengrass Core device. I would recommend to implement some automatic logic to manage these deployments.

I also encourage you to create a feature request in https://github.com/aws-greengrass/aws-greengrass-shadow-manager.

Cheers,

Massimiliano

AWS
ESPERTO
con risposta 2 anni fa
profile picture
ESPERTO
verificato un mese fa
  • Awesome, thank you.

    I haven't experimented much with distributing deployments across targets, so I just want to make sure I understand. We can have a deployment that targets a group with the bulk of the component configuration, minus the ShadowManager, then create unique deployments targeting each GG-Instance with just the ShadowManager. Then Nucleus will handle merging those deployments together to create the desired effective-configuration?

  • Just tested with just that and it seems all good. The effectiveConfig.yaml looks like it's keeping track of which Components came from which Deployment, which is cool.

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande