Skip to content

Commit

Permalink
revert unecessary changes during conflict resolution
Browse files Browse the repository at this point in the history
  • Loading branch information
mpeddada1 committed Aug 27, 2024
1 parent 707c33a commit d998788
Show file tree
Hide file tree
Showing 80 changed files with 22,039 additions and 1,638 deletions.
4 changes: 4 additions & 0 deletions .github/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,7 @@ branches:
bumpMinorPreMajor: true
handleGHRelease: true
branch: 6.67.x
- releaseType: java-backport
bumpMinorPreMajor: true
handleGHRelease: true
branch: 6.66.x
19 changes: 19 additions & 0 deletions .github/sync-repo-settings.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,25 @@ branchProtectionRules:
- checkstyle
- compile (8)
- compile (11)
- pattern: 6.66.x
isAdminEnforced: true
requiredApprovingReviewCount: 1
requiresCodeOwnerReviews: true
requiresStrictStatusChecks: false
requiredStatusCheckContexts:
- dependencies (17)
- lint
- javadoc
- units (8)
- units (11)
- 'Kokoro - Test: Integration'
- 'Kokoro - Test: Integration with Multiplexed Sessions'
- cla/google
- checkstyle
- compile (8)
- compile (11)
- units-with-multiplexed-session (8)
- units-with-multiplexed-session (11)
permissionRules:
- team: yoshi-admins
permission: admin
Expand Down
15 changes: 7 additions & 8 deletions .repo-metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,20 @@
"api_shortname": "spanner",
"name_pretty": "Cloud Spanner",
"product_documentation": "https://cloud.google.com/spanner/docs/",
"api_description": "is a fully managed, mission-critical, relational database service that offers transactional consistency at global scale, \\nschemas, SQL (ANSI 2011 with extensions), and automatic, synchronous replication \\nfor high availability.\\n\\nBe sure to activate the Cloud Spanner API on the Developer's Console to\\nuse Cloud Spanner from your project.",
"client_documentation": "https://cloud.google.com/java/docs/reference/google-cloud-spanner/latest/history",
"api_description": "is a fully managed, mission-critical, \nrelational database service that offers transactional consistency at global scale, \nschemas, SQL (ANSI 2011 with extensions), and automatic, synchronous replication \nfor high availability.\n\nBe sure to activate the Cloud Spanner API on the Developer's Console to\nuse Cloud Spanner from your project.",
"issue_tracker": "https://issuetracker.google.com/issues?q=componentid:190851%2B%20status:open",
"release_level": "stable",
"transport": "both",
"language": "java",
"min_java_version": 8,
"repo": "googleapis/java-spanner",
"repo_short": "java-spanner",
"distribution_name": "com.google.cloud:google-cloud-spanner",
"api_id": "spanner.googleapis.com",
"transport": "grpc",
"library_type": "GAPIC_COMBO",
"requires_billing": true,
"codeowner_team": "@googleapis/api-spanner-java",
"library_type": "GAPIC_COMBO",
"excluded_poms": "google-cloud-spanner-bom",
"recommended_package": "com.google.cloud.spanner"
}

"issue_tracker": "https://issuetracker.google.com/issues?q=componentid:190851%2B%20status:open",
"recommended_package": "com.google.cloud.spanner",
"min_java_version": 8
}
12 changes: 3 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ If you are using Maven without the BOM, add this to your dependencies:
If you are using Gradle 5.x or later, add this to your dependencies:

```Groovy
implementation platform('com.google.cloud:libraries-bom:26.42.0')
implementation platform('com.google.cloud:libraries-bom:26.43.0')
implementation 'com.google.cloud:google-cloud-spanner'
```
Expand Down Expand Up @@ -93,13 +93,7 @@ to add `google-cloud-spanner` as a dependency in your code.
## About Cloud Spanner


[Cloud Spanner][product-docs] is a fully managed, mission-critical,
relational database service that offers transactional consistency at global scale,
schemas, SQL (ANSI 2011 with extensions), and automatic, synchronous replication
for high availability.

Be sure to activate the Cloud Spanner API on the Developer's Console to
use Cloud Spanner from your project.
[Cloud Spanner][product-docs] is a fully managed, mission-critical, relational database service that offers transactional consistency at global scale, \nschemas, SQL (ANSI 2011 with extensions), and automatic, synchronous replication \nfor high availability.\n\nBe sure to activate the Cloud Spanner API on the Developer's Console to\nuse Cloud Spanner from your project.

See the [Cloud Spanner client library docs][javadocs] to learn how to
use this Cloud Spanner Client Library.
Expand Down Expand Up @@ -627,7 +621,7 @@ To get help, follow the instructions in the [shared Troubleshooting document][tr

## Transport

Cloud Spanner uses gRPC for the transport layer.
Cloud Spanner uses both gRPC and HTTP/JSON for the transport layer.

## Supported Java Versions

Expand Down
4 changes: 2 additions & 2 deletions generation_config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
gapic_generator_version: 2.42.0
googleapis_commitish: 6f289d775912966eb0cf04bda91e5e355c998d30
libraries_bom_version: 26.38.0
googleapis_commitish: 19577edb4d439db98d2fb1f6f48f2e1b29fba099
libraries_bom_version: 26.43.0
libraries:
- api_shortname: spanner
name_pretty: Cloud Spanner
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1709,6 +1709,42 @@
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.BackupSchedule",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.BackupSchedule$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.BackupScheduleSpec",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.BackupScheduleSpec$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.CopyBackupEncryptionConfig",
"queryAllDeclaredConstructors": true,
Expand Down Expand Up @@ -1835,6 +1871,24 @@
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.CreateBackupScheduleRequest",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.CreateBackupScheduleRequest$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.CreateDatabaseMetadata",
"queryAllDeclaredConstructors": true,
Expand Down Expand Up @@ -1871,6 +1925,24 @@
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.CrontabSpec",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.CrontabSpec$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.Database",
"queryAllDeclaredConstructors": true,
Expand Down Expand Up @@ -1961,6 +2033,24 @@
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.DeleteBackupScheduleRequest",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.DeleteBackupScheduleRequest$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.DropDatabaseRequest",
"queryAllDeclaredConstructors": true,
Expand Down Expand Up @@ -2024,6 +2114,24 @@
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.FullBackupSpec",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.FullBackupSpec$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.GetBackupRequest",
"queryAllDeclaredConstructors": true,
Expand All @@ -2042,6 +2150,24 @@
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.GetBackupScheduleRequest",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.GetBackupScheduleRequest$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.GetDatabaseDdlRequest",
"queryAllDeclaredConstructors": true,
Expand Down Expand Up @@ -2132,6 +2258,42 @@
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.ListBackupSchedulesRequest",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.ListBackupSchedulesRequest$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.ListBackupSchedulesResponse",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.ListBackupSchedulesResponse$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.ListBackupsRequest",
"queryAllDeclaredConstructors": true,
Expand Down Expand Up @@ -2420,6 +2582,24 @@
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.UpdateBackupScheduleRequest",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.UpdateBackupScheduleRequest$Builder",
"queryAllDeclaredConstructors": true,
"queryAllPublicConstructors": true,
"queryAllDeclaredMethods": true,
"allPublicMethods": true,
"allDeclaredClasses": true,
"allPublicClasses": true
},
{
"name": "com.google.spanner.admin.database.v1.UpdateDatabaseDdlMetadata",
"queryAllDeclaredConstructors": true,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
/*
* Copyright 2024 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.
*/

package com.google.cloud.spanner;

import com.google.api.core.BetaApi;
import javax.annotation.Nonnull;

/**
* The {@link ErrorHandler} interface can be used to implement custom error and retry handling for
* specific cases. The default implementation does nothing and falls back to the standard error and
* retry handling in Gax and the Spanner client.
*/
@BetaApi
interface ErrorHandler {
@Nonnull
Throwable translateException(@Nonnull Throwable exception);

int getMaxAttempts();

class DefaultErrorHandler implements ErrorHandler {
static final DefaultErrorHandler INSTANCE = new DefaultErrorHandler();

private DefaultErrorHandler() {}

@Nonnull
@Override
public Throwable translateException(@Nonnull Throwable exception) {
return exception;
}

@Override
public int getMaxAttempts() {
return 0;
}
}
}
Loading

0 comments on commit d998788

Please sign in to comment.