From cfe90d8fc5dca73439b833a209d1fef1288c2638 Mon Sep 17 00:00:00 2001 From: henrybell Date: Wed, 15 Nov 2023 10:48:21 +0000 Subject: [PATCH] License compliance updates --- .eslintrc.js | 16 +++++++++++++++ .github/workflows/linters.yaml | 14 +++++++++++++ .github/workflows/unit_tests.yaml | 14 +++++++++++++ .mdl.rb | 14 +++++++++++++ LICENSE | 2 +- src/scaler/scaler-core/state.js | 20 ++++++++++--------- .../cloud-functions/distributed/README.md | 2 +- 7 files changed, 71 insertions(+), 11 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index a4c046e3..f2c47fdf 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,3 +1,19 @@ +/** + * Copyright 2023 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + module.exports = { "parserOptions": { "ecmaVersion": 8 diff --git a/.github/workflows/linters.yaml b/.github/workflows/linters.yaml index f7442acf..054e9c57 100644 --- a/.github/workflows/linters.yaml +++ b/.github/workflows/linters.yaml @@ -1,3 +1,17 @@ +# Copyright 2023 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + name: markdownlint on: [push, pull_request] diff --git a/.github/workflows/unit_tests.yaml b/.github/workflows/unit_tests.yaml index bf821e66..fb3fd591 100644 --- a/.github/workflows/unit_tests.yaml +++ b/.github/workflows/unit_tests.yaml @@ -1,3 +1,17 @@ +# Copyright 2023 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + name: Node.js unit tests on: [push, pull_request] diff --git a/.mdl.rb b/.mdl.rb index d8dc3fb6..5a027f80 100644 --- a/.mdl.rb +++ b/.mdl.rb @@ -1,3 +1,17 @@ +# Copyright 2023 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + # Enable all rules by default all diff --git a/LICENSE b/LICENSE index ac4d332f..d6456956 100644 --- a/LICENSE +++ b/LICENSE @@ -187,7 +187,7 @@ same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright 2020 Google LLC + Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/src/scaler/scaler-core/state.js b/src/scaler/scaler-core/state.js index 922e3a48..0355fec6 100644 --- a/src/scaler/scaler-core/state.js +++ b/src/scaler/scaler-core/state.js @@ -1,5 +1,7 @@ -/* Copyright 2020 Google LLC +/** + * Copyright 2023 Google LLC * + * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * @@ -9,7 +11,7 @@ * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and - * limitations under the License + * limitations under the License. */ /* @@ -18,8 +20,8 @@ * By default, this implementation uses a Firestore instance in the same * project as the Spanner instance. To use a different project, set the * `stateProjectId` parameter in the Cloud Scheduler configuration. - * - * To use another database to save autoscaler state, set the + * + * To use another database to save autoscaler state, set the * `stateDatabase.name` parameter in the Cloud Scheduler configuration. * The default database is Firestore. */ @@ -66,11 +68,11 @@ module.exports = State; /* * Manages the Autoscaler persistent state in spanner. - * + * * To manage the Autoscaler state in a spanner database, * set the `stateDatabase.name` parameter to 'spanner' in the Cloud Scheduler configuration. * The following is an example. - * + * * { * "stateDatabase": { * "name": "spanner", @@ -167,12 +169,12 @@ class StateSpanner { /* * Manages the Autoscaler persistent state in firestore. - * + * * The default database for state management is firestore. - * It is also possible to manage with firestore + * It is also possible to manage with firestore * by explicitly setting `stateDatabase.name` to 'firestore'. * The following is an example. - * + * * { * "stateDatabase": { * "name": "firestore" diff --git a/terraform/cloud-functions/distributed/README.md b/terraform/cloud-functions/distributed/README.md index 75252abb..62df71d3 100644 --- a/terraform/cloud-functions/distributed/README.md +++ b/terraform/cloud-functions/distributed/README.md @@ -411,5 +411,5 @@ its configuration issues independently. [cloud-console]: https://console.cloud.google.com [cloud-shell]: https://console.cloud.google.com/?cloudshell=true&_ga=2.43377068.820133692.1587377411-71235912.1585654570&_gac=1.118947195.1584696876.Cj0KCQjw09HzBRDrARIsAG60GP9u6OBk_qQ02rkzBXpwpMd6YZ30A2D4gSl2Wwte1CqPW_sY6mH_xbIaAmIgEALw_wcB [provider-issue]: https://github.com/hashicorp/terraform-provider-google/issues/6782 -[logs-viewer]: https://pantheon.corp.google.com/logs/query +[logs-viewer]: https://console.cloud.google.com/logs/query [firestore-native]: https://cloud.google.com/datastore/docs/firestore-or-datastore#in_native_mode