Download the PHP package keboola/storage-driver-bigquery without Composer

On this page you can find all versions of the php package keboola/storage-driver-bigquery. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package storage-driver-bigquery

Keboola Storage Driver Big Query

Keboola high level storage backend driver for Big Query

Install dependencies.

Setup Big Query

Install Google Cloud client (via Brew), initialize it and log in to generate default credentials.

To prepare the backend use Terraform template. Create a sub folder in the KBC Team Dev (id: 431160969986) folder and fill the folder into the terraform command.

  1. get missing pieces (organization_id and billing_id) from Connection repository.
  2. (optional) move bq-storage-backend-init.tf out of project directory so new files would be out of git
  3. Run terraform init
  4. Run terraform apply -var folder_id=[folder_id] -var billing_account_id=[billing_id] -var backend_prefix=<your prefix, eg. kbc-js> -var file_storage_backend_region=<desired region> (e.g. us-central1 region)
    1. Optionally set terraform.tfvars file with variables there is predefined terraform.tfvars.dist file
  5. New key files was created principal_key.json and big_query_key.json
  6. Set envs from the principal_key.json and big_query_key.json by running php SetBQVars.php and stop. OR continue with following steps with manual extraction.
  7. open principal_key.json set content of private_key as variable BQ_SECRET and remove (the whole entry) it from json file
    1. note: simply cut&paste it whole even with the quotes and new lines -> your .env will be like BQ_SECRET="-----BEGIN PRIVATE KEY-----XXXXZQ==\n-----END PRIVATE KEY-----\n"
  8. remove line breaks from the rest of key file (without private_key entry) and set this string as variable BQ_PRINCIPAL to .env
    1. You can convert the key to string with awk -v RS= '{$1=$1}1' principal_key.json
  9. remove line breaks from the big_query_key.json key file and set this string as variable BQ_KEY_FILE to .env
    1. You can convert the key to string with awk -v RS= '{$1=$1}1' big_query_key.json

At the end, your .env file should look like...

All done. Now you can try composer loadGcs script and run tests.

Build docker images

Xdebug

To run with xdebug use dev-xdebug container instead of dev

Tests

Run tests with following command.

To disable retry copy phpunit-retry.xml.dist

Code quality check

Full CI workflow

This command will run all checks and run tests

Using

Project ID: A globally unique identifier for your project. This lib creating project id as combinations of stackPrefix and projectId from CreateProjectCommand

A project ID is a unique string used to differentiate your project from all others in Google Cloud. You can use the Google Cloud console to generate a project ID, or you can choose your own. You can only modify the project ID when you're creating the project.

Project ID requirements:

License

MIT licensed, see LICENSE file.


All versions of storage-driver-bigquery with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
google/protobuf Version ^3.21
keboola/php-file-storage-utils Version ^0.2.5
ext-json Version *
keboola/storage-driver-common Version ^6.9
google/cloud-resource-manager Version ^0.6.1
google/cloud-service-usage Version ^0.2.7
google/apiclient Version ^2.12.1
google/cloud-bigquery Version ^1.23
google/cloud-billing Version ^1.4
google/apiclient-services Version 0.282.0
keboola/table-backend-utils Version >=2.8.0
react/async Version ^3.0
keboola/db-import-export Version >=2.7.0
symfony/polyfill-php80 Version ^1.26
keboola/retry Version ^0.5.1
google/cloud-bigquery-analyticshub Version ^0.1.0
psr/log Version ^1.1|^2.0|^3.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package keboola/storage-driver-bigquery contains the following files

Loading the files please wait ....