Repository: googleapis/sdk-platform-java (java)

Issue:
generator: Consider removing @BetaApi from client HTTP JSON surface
1. Client service settings HTTP JSON builder
    * Example: https://github.com/googleapis/google-cloud-java/blob/main/java-iot/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerSettings.java#L244-L248
    * Generation logic: https://github.com/googleapis/sdk-platform-java/blame/decd7f60017d45288e6c12493fa21e06f9c5f77c/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/grpcrest/ServiceSettingsClassComposer.java#L81

2. Client service settings builder HTTP JSON default
    * Example: https://github.com/googleapis/google-cloud-java/blob/main/java-iot/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/DeviceManagerSettings.java#L287-L290
    * Generation logic: https://github.com/googleapis/sdk-platform-java/blame/decd7f60017d45288e6c12493fa21e06f9c5f77c/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/grpcrest/ServiceSettingsClassComposer.java#L49

3. Client HTTP JSON service stub classes
    * Example: https://github.com/googleapis/google-cloud-java/blob/main/java-iot/google-cloud-iot/src/main/java/com/google/cloud/iot/v1/stub/HttpJsonDeviceManagerStub.java#L83
    * Generation logic: https://github.com/googleapis/sdk-platform-java/blob/decd7f60017d45288e6c12493fa21e06f9c5f77c/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/rest/HttpJsonServiceStubClassComposer.java#L217

Pull request:
chore: remove beta httpjson
Fixes #2101 ☕️

Patch:
diff --git a/.github/workflows/create_additional_release_tag.yaml b/.github/workflows/create_additional_release_tag.yaml
index 892a82178..0bc731c12 100644
--- a/.github/workflows/create_additional_release_tag.yaml
+++ b/.github/workflows/create_additional_release_tag.yaml
@@ -38,6 +38,8 @@ jobs:
         # Use fixed tag so that checks in handwritten libraries do not need to
         # update the version.
         CHECK_LATEST_TAG="unmanaged-dependencies-check-latest"
+        # delete and create the tag locally.
+        git tag --delete ${CHECK_LATEST_TAG}
         git tag ${CHECK_LATEST_TAG}
         # delete the tag in remote repo and push again.
         git push --delete origin ${CHECK_LATEST_TAG}
diff --git a/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/grpcrest/ServiceSettingsClassComposer.java b/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/grpcrest/ServiceSettingsClassComposer.java
index c597be4c8..c5a735aca 100644
--- a/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/grpcrest/ServiceSettingsClassComposer.java
+++ b/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/grpcrest/ServiceSettingsClassComposer.java
@@ -45,8 +45,6 @@ public class ServiceSettingsClassComposer extends AbstractServiceSettingsClassCo
       String newBuilderMethodName,
       String createDefaultMethodName,
       List<AnnotationNode> annotations) {
-    AnnotationNode betaApiAnnotaiton =
-        AnnotationNode.builder().setType(FIXED_TYPESTORE.get("BetaApi")).build();
 
     List<MethodDefinition> methods = new ArrayList<>();
     methods.addAll(
@@ -59,10 +57,7 @@ public class ServiceSettingsClassComposer extends AbstractServiceSettingsClassCo
               typeStore,
               "newHttpJsonBuilder",
               "createHttpJsonDefault",
-              ImmutableList.<AnnotationNode>builder()
-                  .addAll(annotations)
-                  .add(betaApiAnnotaiton)
-                  .build()));
+              ImmutableList.<AnnotationNode>builder().addAll(annotations).build()));
     }
     return methods;
   }
@@ -77,9 +72,6 @@ public class ServiceSettingsClassComposer extends AbstractServiceSettingsClassCo
       CommentStatement comment) {
     List<MethodDefinition> methods = new ArrayList<>();
 
-    AnnotationNode betaApiAnnotaiton =
-        AnnotationNode.builder().setType(FIXED_TYPESTORE.get("BetaApi")).build();
-
     Iterator<String> transportNames = getTransportContext().transportNames().iterator();
 
     methods.addAll(
@@ -98,10 +90,7 @@ public class ServiceSettingsClassComposer extends AbstractServiceSettingsClassCo
               typeStore,
               "newHttpJsonBuilder",
               "createHttpJsonDefault",
-              ImmutableList.<AnnotationNode>builder()
-                  .addAll(annotations)
-                  .add(betaApiAnnotaiton)
-                  .build(),
+              ImmutableList.<AnnotationNode>builder().addAll(annotations).build(),
               new SettingsCommentComposer(transportNames.next())
                   .getNewTransportBuilderMethodComment()));
     }
diff --git a/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/rest/HttpJsonServiceStubClassComposer.java b/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/rest/HttpJsonServiceStubClassComposer.java
index 19e7cfbcb..e631dce36 100644
--- a/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/rest/HttpJsonServiceStubClassComposer.java
+++ b/gapic-generator-java/src/main/java/com/google/api/generator/gapic/composer/rest/HttpJsonServiceStubClassComposer.java
@@ -210,19 +210,6 @@ public class HttpJsonServiceStubClassComposer extends AbstractTransportServiceSt
     return super.createOperationsStubGetterMethod(service, operationsStubVarExpr);
   }
 
-  @Override
-  protected List<AnnotationNode> createClassAnnotations(Service service) {
-    List<AnnotationNode> annotations = super.createClassAnnotations(service);
-
-    TypeNode betaApiType = FIXED_TYPESTORE.get("BetaApi");
-
-    if (annotations.stream().noneMatch(a -> betaApiType.equals(a.type()))) {
-      annotations.add(AnnotationNode.builder().setType(betaApiType).build());
-    }
-
-    return annotations;
-  }
-
   @Override
   protected List<MethodDefinition> createGetMethodDescriptorsMethod(
       Service service,
diff --git a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/ComplianceSettings.java b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/ComplianceSettings.java
index 823f9ccb1..f07f55a8c 100644
--- a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/ComplianceSettings.java
+++ b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/ComplianceSettings.java
@@ -212,7 +212,6 @@ public class ComplianceSettings extends ClientSettings<ComplianceSettings> {
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -254,7 +253,6 @@ public class ComplianceSettings extends ClientSettings<ComplianceSettings> {
       return new Builder(ComplianceStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(ComplianceStubSettings.newHttpJsonBuilder());
     }
diff --git a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/EchoSettings.java b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/EchoSettings.java
index 360d136ff..aed2c2ea7 100644
--- a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/EchoSettings.java
+++ b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/EchoSettings.java
@@ -228,7 +228,6 @@ public class EchoSettings extends ClientSettings<EchoSettings> {
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -270,7 +269,6 @@ public class EchoSettings extends ClientSettings<EchoSettings> {
       return new Builder(EchoStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(EchoStubSettings.newHttpJsonBuilder());
     }
diff --git a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/IdentitySettings.java b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/IdentitySettings.java
index 5b425ed70..252c9aba3 100644
--- a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/IdentitySettings.java
+++ b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/IdentitySettings.java
@@ -190,7 +190,6 @@ public class IdentitySettings extends ClientSettings<IdentitySettings> {
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -232,7 +231,6 @@ public class IdentitySettings extends ClientSettings<IdentitySettings> {
       return new Builder(IdentityStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(IdentityStubSettings.newHttpJsonBuilder());
     }
diff --git a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/MessagingSettings.java b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/MessagingSettings.java
index a28bd4806..22670dcd5 100644
--- a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/MessagingSettings.java
+++ b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/MessagingSettings.java
@@ -248,7 +248,6 @@ public class MessagingSettings extends ClientSettings<MessagingSettings> {
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -290,7 +289,6 @@ public class MessagingSettings extends ClientSettings<MessagingSettings> {
       return new Builder(MessagingStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(MessagingStubSettings.newHttpJsonBuilder());
     }
diff --git a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/SequenceServiceSettings.java b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/SequenceServiceSettings.java
index 111119b94..a323894e0 100644
--- a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/SequenceServiceSettings.java
+++ b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/SequenceServiceSettings.java
@@ -200,7 +200,6 @@ public class SequenceServiceSettings extends ClientSettings<SequenceServiceSetti
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -242,7 +241,6 @@ public class SequenceServiceSettings extends ClientSettings<SequenceServiceSetti
       return new Builder(SequenceServiceStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(SequenceServiceStubSettings.newHttpJsonBuilder());
     }


Test patch:
diff --git a/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/grpcrest/goldens/EchoSettings.golden b/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/grpcrest/goldens/EchoSettings.golden
index 0abf62bae..2456b6cb0 100644
--- a/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/grpcrest/goldens/EchoSettings.golden
+++ b/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/grpcrest/goldens/EchoSettings.golden
@@ -177,7 +177,6 @@ public class EchoSettings extends ClientSettings<EchoSettings> {
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -219,7 +218,6 @@ public class EchoSettings extends ClientSettings<EchoSettings> {
       return new Builder(EchoStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(EchoStubSettings.newHttpJsonBuilder());
     }
diff --git a/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/rest/goldens/HttpJsonAutoPopulateFieldTestingStub.golden b/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/rest/goldens/HttpJsonAutoPopulateFieldTestingStub.golden
index 9b5d7c3b8..6b390feb6 100644
--- a/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/rest/goldens/HttpJsonAutoPopulateFieldTestingStub.golden
+++ b/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/rest/goldens/HttpJsonAutoPopulateFieldTestingStub.golden
@@ -1,6 +1,5 @@
 package com.google.auto.populate.field.stub;
 
-import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.api.gax.core.BackgroundResource;
 import com.google.api.gax.core.BackgroundResourceAggregation;
@@ -36,7 +35,6 @@ import javax.annotation.Generated;
  * <p>This class is for advanced usage and reflects the underlying API directly.
  */
 @Generated("by gapic-generator-java")
-@BetaApi
 public class HttpJsonAutoPopulateFieldTestingStub extends AutoPopulateFieldTestingStub {
   private static final TypeRegistry typeRegistry = TypeRegistry.newBuilder().build();
 
diff --git a/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/rest/goldens/HttpJsonRoutingHeadersStub.golden b/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/rest/goldens/HttpJsonRoutingHeadersStub.golden
index 1987cbc59..b377fe3a1 100644
--- a/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/rest/goldens/HttpJsonRoutingHeadersStub.golden
+++ b/gapic-generator-java/src/test/java/com/google/api/generator/gapic/composer/rest/goldens/HttpJsonRoutingHeadersStub.golden
@@ -1,6 +1,5 @@
 package com.google.explicit.dynamic.routing.header.stub;
 
-import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.api.gax.core.BackgroundResource;
 import com.google.api.gax.core.BackgroundResourceAggregation;
@@ -35,7 +34,6 @@ import javax.annotation.Generated;
  * <p>This class is for advanced usage and reflects the underlying API directly.
  */
 @Generated("by gapic-generator-java")
-@BetaApi
 public class HttpJsonExplicitDynamicRoutingHeaderTestingStub
     extends ExplicitDynamicRoutingHeaderTestingStub {
   private static final TypeRegistry typeRegistry = TypeRegistry.newBuilder().build();
diff --git a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/TestingSettings.java b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/TestingSettings.java
index 13d6defe5..8d49238eb 100644
--- a/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/TestingSettings.java
+++ b/showcase/gapic-showcase/src/main/java/com/google/showcase/v1beta1/TestingSettings.java
@@ -207,7 +207,6 @@ public class TestingSettings extends ClientSettings<TestingSettings> {
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -249,7 +248,6 @@ public class TestingSettings extends ClientSettings<TestingSettings> {
       return new Builder(TestingStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(TestingStubSettings.newHttpJsonBuilder());
     }
diff --git a/test/integration/goldens/apigeeconnect/src/com/google/cloud/apigeeconnect/v1/ConnectionServiceSettings.java b/test/integration/goldens/apigeeconnect/src/com/google/cloud/apigeeconnect/v1/ConnectionServiceSettings.java
index 6127ea2ae..4e26180f9 100644
--- a/test/integration/goldens/apigeeconnect/src/com/google/cloud/apigeeconnect/v1/ConnectionServiceSettings.java
+++ b/test/integration/goldens/apigeeconnect/src/com/google/cloud/apigeeconnect/v1/ConnectionServiceSettings.java
@@ -134,7 +134,6 @@ public class ConnectionServiceSettings extends ClientSettings<ConnectionServiceS
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -176,7 +175,6 @@ public class ConnectionServiceSettings extends ClientSettings<ConnectionServiceS
       return new Builder(ConnectionServiceStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(ConnectionServiceStubSettings.newHttpJsonBuilder());
     }
diff --git a/test/integration/goldens/apigeeconnect/src/com/google/cloud/apigeeconnect/v1/stub/HttpJsonConnectionServiceStub.java b/test/integration/goldens/apigeeconnect/src/com/google/cloud/apigeeconnect/v1/stub/HttpJsonConnectionServiceStub.java
index 434cecd95..8077e8110 100644
--- a/test/integration/goldens/apigeeconnect/src/com/google/cloud/apigeeconnect/v1/stub/HttpJsonConnectionServiceStub.java
+++ b/test/integration/goldens/apigeeconnect/src/com/google/cloud/apigeeconnect/v1/stub/HttpJsonConnectionServiceStub.java
@@ -18,7 +18,6 @@ package com.google.cloud.apigeeconnect.v1.stub;
 
 import static com.google.cloud.apigeeconnect.v1.ConnectionServiceClient.ListConnectionsPagedResponse;
 
-import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.api.gax.core.BackgroundResource;
 import com.google.api.gax.core.BackgroundResourceAggregation;
@@ -49,7 +48,6 @@ import javax.annotation.Generated;
  * <p>This class is for advanced usage and reflects the underlying API directly.
  */
 @Generated("by gapic-generator-java")
-@BetaApi
 public class HttpJsonConnectionServiceStub extends ConnectionServiceStub {
   private static final TypeRegistry typeRegistry = TypeRegistry.newBuilder().build();
 
diff --git a/test/integration/goldens/asset/src/com/google/cloud/asset/v1/AssetServiceSettings.java b/test/integration/goldens/asset/src/com/google/cloud/asset/v1/AssetServiceSettings.java
index d490f6d67..81a6e9bae 100644
--- a/test/integration/goldens/asset/src/com/google/cloud/asset/v1/AssetServiceSettings.java
+++ b/test/integration/goldens/asset/src/com/google/cloud/asset/v1/AssetServiceSettings.java
@@ -262,7 +262,6 @@ public class AssetServiceSettings extends ClientSettings<AssetServiceSettings> {
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -304,7 +303,6 @@ public class AssetServiceSettings extends ClientSettings<AssetServiceSettings> {
       return new Builder(AssetServiceStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(AssetServiceStubSettings.newHttpJsonBuilder());
     }
diff --git a/test/integration/goldens/asset/src/com/google/cloud/asset/v1/stub/HttpJsonAssetServiceStub.java b/test/integration/goldens/asset/src/com/google/cloud/asset/v1/stub/HttpJsonAssetServiceStub.java
index fde890bd6..d4825f918 100644
--- a/test/integration/goldens/asset/src/com/google/cloud/asset/v1/stub/HttpJsonAssetServiceStub.java
+++ b/test/integration/goldens/asset/src/com/google/cloud/asset/v1/stub/HttpJsonAssetServiceStub.java
@@ -21,7 +21,6 @@ import static com.google.cloud.asset.v1.AssetServiceClient.ListSavedQueriesPaged
 import static com.google.cloud.asset.v1.AssetServiceClient.SearchAllIamPoliciesPagedResponse;
 import static com.google.cloud.asset.v1.AssetServiceClient.SearchAllResourcesPagedResponse;
 
-import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.api.gax.core.BackgroundResource;
 import com.google.api.gax.core.BackgroundResourceAggregation;
@@ -91,7 +90,6 @@ import javax.annotation.Generated;
  * <p>This class is for advanced usage and reflects the underlying API directly.
  */
 @Generated("by gapic-generator-java")
-@BetaApi
 public class HttpJsonAssetServiceStub extends AssetServiceStub {
   private static final TypeRegistry typeRegistry =
       TypeRegistry.newBuilder()
diff --git a/test/integration/goldens/compute/src/com/google/cloud/compute/v1small/stub/HttpJsonAddressesStub.java b/test/integration/goldens/compute/src/com/google/cloud/compute/v1small/stub/HttpJsonAddressesStub.java
index a0caf3d27..3eac03ac8 100644
--- a/test/integration/goldens/compute/src/com/google/cloud/compute/v1small/stub/HttpJsonAddressesStub.java
+++ b/test/integration/goldens/compute/src/com/google/cloud/compute/v1small/stub/HttpJsonAddressesStub.java
@@ -19,7 +19,6 @@ package com.google.cloud.compute.v1small.stub;
 import static com.google.cloud.compute.v1small.AddressesClient.AggregatedListPagedResponse;
 import static com.google.cloud.compute.v1small.AddressesClient.ListPagedResponse;
 
-import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.api.gax.core.BackgroundResource;
 import com.google.api.gax.core.BackgroundResourceAggregation;
@@ -59,7 +58,6 @@ import javax.annotation.Generated;
  * <p>This class is for advanced usage and reflects the underlying API directly.
  */
 @Generated("by gapic-generator-java")
-@BetaApi
 public class HttpJsonAddressesStub extends AddressesStub {
   private static final TypeRegistry typeRegistry =
       TypeRegistry.newBuilder().add(Operation.getDescriptor()).build();
diff --git a/test/integration/goldens/compute/src/com/google/cloud/compute/v1small/stub/HttpJsonRegionOperationsStub.java b/test/integration/goldens/compute/src/com/google/cloud/compute/v1small/stub/HttpJsonRegionOperationsStub.java
index 81f0e4838..3eb2ee3c2 100644
--- a/test/integration/goldens/compute/src/com/google/cloud/compute/v1small/stub/HttpJsonRegionOperationsStub.java
+++ b/test/integration/goldens/compute/src/com/google/cloud/compute/v1small/stub/HttpJsonRegionOperationsStub.java
@@ -16,7 +16,6 @@
 
 package com.google.cloud.compute.v1small.stub;
 
-import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.api.gax.core.BackgroundResource;
 import com.google.api.gax.core.BackgroundResourceAggregation;
@@ -54,7 +53,6 @@ import javax.annotation.Generated;
  * <p>This class is for advanced usage and reflects the underlying API directly.
  */
 @Generated("by gapic-generator-java")
-@BetaApi
 public class HttpJsonRegionOperationsStub extends RegionOperationsStub {
   private static final TypeRegistry typeRegistry = TypeRegistry.newBuilder().build();
 
diff --git a/test/integration/goldens/credentials/src/com/google/cloud/iam/credentials/v1/IamCredentialsSettings.java b/test/integration/goldens/credentials/src/com/google/cloud/iam/credentials/v1/IamCredentialsSettings.java
index 221ee9c4b..421e04050 100644
--- a/test/integration/goldens/credentials/src/com/google/cloud/iam/credentials/v1/IamCredentialsSettings.java
+++ b/test/integration/goldens/credentials/src/com/google/cloud/iam/credentials/v1/IamCredentialsSettings.java
@@ -147,7 +147,6 @@ public class IamCredentialsSettings extends ClientSettings<IamCredentialsSetting
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -189,7 +188,6 @@ public class IamCredentialsSettings extends ClientSettings<IamCredentialsSetting
       return new Builder(IamCredentialsStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(IamCredentialsStubSettings.newHttpJsonBuilder());
     }
diff --git a/test/integration/goldens/credentials/src/com/google/cloud/iam/credentials/v1/stub/HttpJsonIamCredentialsStub.java b/test/integration/goldens/credentials/src/com/google/cloud/iam/credentials/v1/stub/HttpJsonIamCredentialsStub.java
index 5cb18810c..4e0a28aa0 100644
--- a/test/integration/goldens/credentials/src/com/google/cloud/iam/credentials/v1/stub/HttpJsonIamCredentialsStub.java
+++ b/test/integration/goldens/credentials/src/com/google/cloud/iam/credentials/v1/stub/HttpJsonIamCredentialsStub.java
@@ -16,7 +16,6 @@
 
 package com.google.cloud.iam.credentials.v1.stub;
 
-import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.api.gax.core.BackgroundResource;
 import com.google.api.gax.core.BackgroundResourceAggregation;
@@ -53,7 +52,6 @@ import javax.annotation.Generated;
  * <p>This class is for advanced usage and reflects the underlying API directly.
  */
 @Generated("by gapic-generator-java")
-@BetaApi
 public class HttpJsonIamCredentialsStub extends IamCredentialsStub {
   private static final TypeRegistry typeRegistry = TypeRegistry.newBuilder().build();
 
diff --git a/test/integration/goldens/library/src/com/google/cloud/example/library/v1/LibraryServiceSettings.java b/test/integration/goldens/library/src/com/google/cloud/example/library/v1/LibraryServiceSettings.java
index 410830a7f..d6e3b5a5b 100644
--- a/test/integration/goldens/library/src/com/google/cloud/example/library/v1/LibraryServiceSettings.java
+++ b/test/integration/goldens/library/src/com/google/cloud/example/library/v1/LibraryServiceSettings.java
@@ -202,7 +202,6 @@ public class LibraryServiceSettings extends ClientSettings<LibraryServiceSetting
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -244,7 +243,6 @@ public class LibraryServiceSettings extends ClientSettings<LibraryServiceSetting
       return new Builder(LibraryServiceStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(LibraryServiceStubSettings.newHttpJsonBuilder());
     }
diff --git a/test/integration/goldens/library/src/com/google/cloud/example/library/v1/stub/HttpJsonLibraryServiceStub.java b/test/integration/goldens/library/src/com/google/cloud/example/library/v1/stub/HttpJsonLibraryServiceStub.java
index 7c2e50108..116e6b761 100644
--- a/test/integration/goldens/library/src/com/google/cloud/example/library/v1/stub/HttpJsonLibraryServiceStub.java
+++ b/test/integration/goldens/library/src/com/google/cloud/example/library/v1/stub/HttpJsonLibraryServiceStub.java
@@ -19,7 +19,6 @@ package com.google.cloud.example.library.v1.stub;
 import static com.google.cloud.example.library.v1.LibraryServiceClient.ListBooksPagedResponse;
 import static com.google.cloud.example.library.v1.LibraryServiceClient.ListShelvesPagedResponse;
 
-import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.api.gax.core.BackgroundResource;
 import com.google.api.gax.core.BackgroundResourceAggregation;
@@ -64,7 +63,6 @@ import javax.annotation.Generated;
  * <p>This class is for advanced usage and reflects the underlying API directly.
  */
 @Generated("by gapic-generator-java")
-@BetaApi
 public class HttpJsonLibraryServiceStub extends LibraryServiceStub {
   private static final TypeRegistry typeRegistry = TypeRegistry.newBuilder().build();
 
diff --git a/test/integration/goldens/redis/src/com/google/cloud/redis/v1beta1/CloudRedisSettings.java b/test/integration/goldens/redis/src/com/google/cloud/redis/v1beta1/CloudRedisSettings.java
index f3045607b..089c7c5a2 100644
--- a/test/integration/goldens/redis/src/com/google/cloud/redis/v1beta1/CloudRedisSettings.java
+++ b/test/integration/goldens/redis/src/com/google/cloud/redis/v1beta1/CloudRedisSettings.java
@@ -236,7 +236,6 @@ public class CloudRedisSettings extends ClientSettings<CloudRedisSettings> {
   }
 
   /** Returns a new REST builder for this class. */
-  @BetaApi
   public static Builder newHttpJsonBuilder() {
     return Builder.createHttpJsonDefault();
   }
@@ -278,7 +277,6 @@ public class CloudRedisSettings extends ClientSettings<CloudRedisSettings> {
       return new Builder(CloudRedisStubSettings.newBuilder());
     }
 
-    @BetaApi
     private static Builder createHttpJsonDefault() {
       return new Builder(CloudRedisStubSettings.newHttpJsonBuilder());
     }