From 3fe98a886d2fb1e31db4875bf8c84d09e6b4f3a0 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Wed, 19 Jan 2022 17:58:31 +0000 Subject: [PATCH] build(node): switch back to keystore for publication (#1328) (#243) --- .github/.OwlBot.lock.yaml | 2 +- .kokoro/publish.sh | 2 +- .kokoro/release/publish.cfg | 11 +++++- README.md | 4 +++ samples/README.md | 72 +++++++++++++++++++++++++++++++++++++ 5 files changed, 88 insertions(+), 3 deletions(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index cbbb1758..2c37ca7a 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/cloud-devrel-public-resources/owlbot-nodejs:latest - digest: sha256:2d850512335d7adca3a4b08e02f8e63192978aea88c042dacb3e382aa996ae7c + digest: sha256:89c5b2f3decec8ad64febbebea671076c119d1ab43700da380846a315600de8a diff --git a/.kokoro/publish.sh b/.kokoro/publish.sh index 4db6bf1c..77a5defb 100755 --- a/.kokoro/publish.sh +++ b/.kokoro/publish.sh @@ -24,7 +24,7 @@ python3 -m releasetool publish-reporter-script > /tmp/publisher-script; source / cd $(dirname $0)/.. -NPM_TOKEN=$(cat $KOKORO_GFILE_DIR/secret_manager/npm_publish_token) +NPM_TOKEN=$(cat $KOKORO_KEYSTORE_DIR/73713_google-cloud-npm-token-1) echo "//wombat-dressing-room.appspot.com/:_authToken=${NPM_TOKEN}" > ~/.npmrc npm install diff --git a/.kokoro/release/publish.cfg b/.kokoro/release/publish.cfg index 6e84cf46..ba6547f4 100644 --- a/.kokoro/release/publish.cfg +++ b/.kokoro/release/publish.cfg @@ -7,9 +7,18 @@ before_action { } } +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "google-cloud-npm-token-1" + } + } +} + env_vars: { key: "SECRET_MANAGER_KEYS" - value: "npm_publish_token,releasetool-publish-reporter-app,releasetool-publish-reporter-googleapis-installation,releasetool-publish-reporter-pem" + value: "releasetool-publish-reporter-app,releasetool-publish-reporter-googleapis-installation,releasetool-publish-reporter-pem" } # Download trampoline resources. diff --git a/README.md b/README.md index 8b0a9a79..ed71e35d 100644 --- a/README.md +++ b/README.md @@ -185,7 +185,11 @@ Samples are in the [`samples/`](https://github.com/googleapis/nodejs-bigquery-st | Sample | Source Code | Try it | | --------------------------- | --------------------------------- | ------ | +| Append_rows_pending | [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/append_rows_pending.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/append_rows_pending.js,samples/README.md) | +| Append_rows_proto2 | [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/append_rows_proto2.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/append_rows_proto2.js,samples/README.md) | +| Customer_record_pb | [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/customer_record_pb.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/customer_record_pb.js,samples/README.md) | | BigQuery Storage Quickstart | [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/quickstart.js,samples/README.md) | +| Sample_data_pb2 | [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/sample_data_pb2.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/sample_data_pb2.js,samples/README.md) | diff --git a/samples/README.md b/samples/README.md index 953b83c0..26adb60c 100644 --- a/samples/README.md +++ b/samples/README.md @@ -12,7 +12,11 @@ * [Before you begin](#before-you-begin) * [Samples](#samples) + * [Append_rows_pending](#append_rows_pending) + * [Append_rows_proto2](#append_rows_proto2) + * [Customer_record_pb](#customer_record_pb) * [BigQuery Storage Quickstart](#bigquery-storage-quickstart) + * [Sample_data_pb2](#sample_data_pb2) ## Before you begin @@ -29,6 +33,57 @@ Before running the samples, make sure you've followed the steps outlined in +### Append_rows_pending + +View the [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/append_rows_pending.js). + +[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/append_rows_pending.js,samples/README.md) + +__Usage:__ + + +`node samples/append_rows_pending.js` + + +----- + + + + +### Append_rows_proto2 + +View the [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/append_rows_proto2.js). + +[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/append_rows_proto2.js,samples/README.md) + +__Usage:__ + + +`node samples/append_rows_proto2.js` + + +----- + + + + +### Customer_record_pb + +View the [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/customer_record_pb.js). + +[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/customer_record_pb.js,samples/README.md) + +__Usage:__ + + +`node samples/customer_record_pb.js` + + +----- + + + + ### BigQuery Storage Quickstart Read data from a table via read stream. @@ -43,6 +98,23 @@ __Usage:__ `node quickstart.js` +----- + + + + +### Sample_data_pb2 + +View the [source code](https://github.com/googleapis/nodejs-bigquery-storage/blob/main/samples/sample_data_pb2.js). + +[![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/nodejs-bigquery-storage&page=editor&open_in_editor=samples/sample_data_pb2.js,samples/README.md) + +__Usage:__ + + +`node samples/sample_data_pb2.js` + +