How to install BillingTier in BigQuery Ruby API

Some of my queries return a billingTierLimitExceeded error and troubleshooting, this leads me to documents telling me to change the configuration of my query job.

I found configuration.query.maximumBillingTier in the REST API, but not for the Ruby client library.

How to set configuration.query.maximumBillingTier using Ruby SDK?

+6
source share
1 answer

To execute the request at a higher price level, pass the new value for maximumBillingTier as part of the request request, just like the other properties. See link here .

For example, you can do something like configuration.query.createDisposition or configuration.query.allowLargeResults

It should be noted that maximumBillingTier is a positive integer that serves as a base price multiplier of $ 5 per TB. See Link and more details here .

You can also achieve this from the bq command line:

 USAGE: bq.py [--global_flags] <command> [--command_flags] [args] 

If necessary, change the global flag job_property :

- job_property: additional key-value pairs to be included in the job configuration properties field; repeat this option specify a list of values

0
source

Source: https://habr.com/ru/post/1014778/


All Articles