Google IoT Core registry with additional telemetry topic and wildcard in subfolder?

316 Views Asked by At

I want to add telemetry topics to a registry and distribute telemetry streams to different pubsub topics. Since our MQTT topics on the devices use more than one subfolder, the registry's subfolder string does not match exactly to the pubsub topic.

For example, our device sends telemetry to the topic: /devices/devId/events/pubsubTopicId/additionalInfo/evenMoreInfo

I'd wish the resulting pubsub messages to be placed in the topic /projects/projectId/topics/pubsubTopicId and to have the pubsub subfolder property like /additionalInfo/evenMoreInfo.

Instead currently, all messages are published in the registry's default pubsub topic.

So this question is more of a feature request to the google team to enable wildcards in the subfolderMatches property of registry's EventNotificationConfig. Than a positive match could be evaluted if the first subfolder after /devices/devId/events would match.

Thx for your answer!

1

There are 1 best solutions below

2
On

I hear the feature request, and I can bring that to our engineering team.

As a possible solution for now...what if you set up something where the telemetry always goes to the /devices/devId/events/pubsubTopicId/ folder. And then inside the telemetry payload, you had subfolders where you wanted things going in addition to that, and you ran a cloud function, or a dataflow pipeline to parse the payload, and send the telemetry to the appropriate bucket?