Google Pub/Sub

Plainsight allows users to connect their model's Inference API to Google Pub/Sub, publish messages to a topic, and receive inference data. Check out Google's Pub/Sub guide for more information on how you can get started using Pub/Sub:
To configure the Inference API to publish to your Google Pub/Sub, you will need to create a topic to publish messages to if you do not already have one. You will also need to create a subscription to the topic in order to receive messages. Check out Google's documentation on topics and subscriptions:

Configure Pub/Sub Integration

Once you have a topic set up, you can configure the Pub/Sub integration in Plainsight.
  1. 1.
    Navigate to the model version details of the model whose API data you want to publish to your topic.
  2. 2.
    Click the "Setup Pub/Sub" button.
  3. 3.
    Enter your Google Project ID.
  4. 4.
    Enter the "Pub/Sub Topic" relative name. Only the relative name is needed, not the full name. For example, if the full topic name is projects/myproject/topics/mytopic then only mytopic should be entered.
  5. 5.
    Click "Choose File" and select the Service Account JSON file. The service account must have Pub/Sub publish permissions.
  6. 6.
    Click "Save Pub/Sub" to complete the connection.

Receiving Messages

To retrieve your messages with a subscription, see Google's overview for Subscribers:

Disable Publishing

To disable publishing, click the "Setup Pub/Sub" button and toggle "Enable publishing" to off. This will stop API messages from being published to your topic.

Updating Topic

You can update your topic name at any time by changing the "Pub/Sub Topic" name and saving the Pub/Sub settings. Messages will be published to the new topic.