Yang Gao | 084ef52 | 2015-04-15 11:34:15 -0700 | [diff] [blame] | 1 | NOTE: This example does not build and is being updated. |
Abhishek Kumar | 85f9963 | 2015-02-25 11:45:05 -0800 | [diff] [blame] | 2 | Experimental example code, likely to change. |
| 3 | Users should not attempt to run this code till this warning is removed. |
| 4 | |
Chen wang | 8423251 | 2015-02-12 17:29:18 -0800 | [diff] [blame] | 5 | C++ Client implementation for Cloud Pub/Sub service |
Chen Wang | 4402b70 | 2015-02-03 12:11:29 -0800 | [diff] [blame] | 6 | (https://developers.google.com/apis-explorer/#p/pubsub/v1beta1/). |
| 7 | |
| 8 | "Google Cloud Pub/Sub" API needs to be enabled at |
| 9 | https://console.developers.google.com/project to open the access for a client. |
| 10 | Select the project name, select the "APIs" under "APIs & auth", and turn |
| 11 | on "Google Cloud Pub/Sub" API. |
| 12 | |
| 13 | To run the client from Google Compute Engine (GCE), the GCE instance needs to |
| 14 | be created with scope "https://www.googleapis.com/auth/cloud-platform" as below: |
| 15 | |
| 16 | gcloud compute instances create instance-name |
| 17 | --image debian-7 --scopes https://www.googleapis.com/auth/cloud-platform |
Chen wang | 8423251 | 2015-02-12 17:29:18 -0800 | [diff] [blame] | 18 | |
Chen Wang | 4402b70 | 2015-02-03 12:11:29 -0800 | [diff] [blame] | 19 | |
Abhishek Kumar | 85f9963 | 2015-02-25 11:45:05 -0800 | [diff] [blame] | 20 | To run the client: |
| 21 | make pubsub_client |
| 22 | bins/opt/pubsub_client --project_id="your project id" |