Trigger cloud lambda with MQTT message

0

Is there a way to connect GG to a "normal" lambda that lives in the cloud?
I was requested to do a flow that goes like this:

device --mqtt topic--> gg lambda (gg core) --mqtt topic--> iot core (cloud) ----> cloud lambda (triggers sagemaker)

I didn't find a way to do this, so instead I did this:

device --mqtt topic--> gg lambda (gg core) (directly invoke the cloud lambda) --> cloud lambda (triggers sagemaker)

But I was told this didn't follow the flow as designed, so I need to find a way to trigger the cloud lambda differently. From what I know, if I link a lambda to an GG core it will be run locally in the core and not in the cloud and I haven't found a way to trigger a cloud lambda using an mqtt message or some other way that involves the "IoT Core" invoking it.

Is there a way of doing the designed flow? Or is that just not possible?

posta 4 anni fa1019 visualizzazioni
2 Risposte
0

Hi tgonzale:

If I understand correctly, you just want to know if it is possible for Greengrass Lambda to trigger cloud side Lambda?

If that is your question, a good solution might be setting Rules for AWS IOT, you can access many AWS services there.

Reference link:
https://docs.aws.amazon.com/iot/latest/developerguide/iot-rules.html

Best Regards

AWS
con risposta 4 anni fa
0

IoT Rules is the answer, thanks!

con risposta 4 anni fa

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