Search code examples
google-cloud-platformgoogle-cloud-pubsubgoogle-cloud-runevent-arc

How can we enable ordering in cloud pub sub subscription created via EventARc trigger?


When we create an subscription in Cloud Pub Sub we have the ability to enable ordering of messages. However, when a subscription is created through EventArc, there is no option to enable ordering. Once the subscription is created, it is not possible to enable ordering.How can we enable ordering in cloud pub sub subscription created via EventARc trigger ?


Solution

  • The short answer is NO.

    However, you have to understand what is ordering feature on PubSub. Pubsub is able to send message in order only on the same ordering-key. It's, in general, the case when you have message related to the same thing (for example to the same IoT device).

    In the case of eventarc, that bases the PubSub message on the audit logs, what could be the ordering key? The account email? What would you like?