GeezerVison is showing github.com — Fixing build issues caused by dependency update. (#1055) · jcguehl/java-docs-samples@8a48f92
File treeExpand file treeCollapse file tree Open diff view settings container-registry/container-analysis main/java/com/example/containeranalysis test/java/com/example/containeranalysis
dataflow/spanner-io/src/test/java/com/example/dataflow errorreporting/src/main/java/com/example/errorreporting src/main/java/com/example/monitoring
Expand file treeCollapse file tree Open diff view settings Collapse file Copy file name to clipboardExpand all lines: .kokoro/presubmit.cfg -1Lines changed: 0 additions & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -19,4 +19,3 @@ env_vars: { | 19 | 19 | key: "TRAMPOLINE_BUILD_FILE" | 20 | 20 | value: "github/java-docs-samples/.kokoro/tests/diff_tests.sh" | 21 | 21 | } | 22 | | - |
Collapse file Copy file name to clipboardExpand all lines: appengine/datastore/pom.xml -1Lines changed: 0 additions & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
| 40 | 40 | <module>indexes-exploding</module> | 41 | 41 | <module>indexes-perfect</module> | 42 | 42 | </modules> | 43 | | - | 44 | 43 | </project> |
Collapse file Copy file name to clipboardExpand all lines: container-registry/container-analysis/pom.xml +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
| 44 | 44 | <dependency> | 45 | 45 | <groupId>com.google.cloud</groupId> | 46 | 46 | <artifactId>google-cloud-pubsub</artifactId> | 47 | | - <version>0.34.0-beta</version> | | 47 | + <version>0.38.0-beta</version> | 48 | 48 | </dependency> | 49 | 49 | <dependency> | 50 | 50 | <groupId>com.google.api</groupId> | |
Collapse file Copy file name to clipboardExpand all lines: container-registry/container-analysis/src/main/java/com/example/containeranalysis/Samples.java +5-5Lines changed: 5 additions & 5 deletions | Original file line number | Diff line number | Diff line change |
|---|
| 30 | 30 | import com.google.containeranalysis.v1alpha1.Occurrence; | 31 | 31 | import com.google.containeranalysis.v1alpha1.VulnerabilityType; | 32 | 32 | import com.google.containeranalysis.v1alpha1.VulnerabilityType.VulnerabilityDetails; | | 33 | +import com.google.pubsub.v1.ProjectSubscriptionName; | | 34 | +import com.google.pubsub.v1.ProjectTopicName; | 33 | 35 | import com.google.pubsub.v1.PubsubMessage; | 34 | 36 | import com.google.pubsub.v1.PushConfig; | 35 | 37 | import com.google.pubsub.v1.Subscription; | 36 | | -import com.google.pubsub.v1.SubscriptionName; | 37 | | -import com.google.pubsub.v1.TopicName; | 38 | 38 |
| 39 | 39 | /** | 40 | 40 | * API usage samples | @@ -292,7 +292,7 @@ public static int pubSub(String subscriptionId, int timeout, String projectId) t | 292 | 292 |
| 293 | 293 | try { | 294 | 294 | // subscribe to the requested pubsub channel | 295 | | - SubscriptionName subscriptionName = SubscriptionName.of(projectId, subscriptionId); | | 295 | + ProjectSubscriptionName subscriptionName = ProjectSubscriptionName.of(projectId, subscriptionId); | 296 | 296 | subscriber = Subscriber.newBuilder(subscriptionName, receiver).build(); | 297 | 297 | subscriber.startAsync().awaitRunning(); | 298 | 298 | // listen to messages for 'listenTimeout' seconds | @@ -339,8 +339,8 @@ public static Subscription createOccurrenceSubscription(String subscriptionId, S | 339 | 339 | String topicId = "resource-notes-occurrences-v1alpha1"; | 340 | 340 | try (SubscriptionAdminClient client = SubscriptionAdminClient.create()) { | 341 | 341 | PushConfig config = PushConfig.getDefaultInstance(); | 342 | | - TopicName topicName = TopicName.of(projectId, topicId); | 343 | | - SubscriptionName subscriptionName = SubscriptionName.of(projectId, subscriptionId); | | 342 | + ProjectTopicName topicName = ProjectTopicName.of(projectId, topicId); | | 343 | + ProjectSubscriptionName subscriptionName = ProjectSubscriptionName.of(projectId, subscriptionId); | 344 | 344 | Subscription sub = client.createSubscription(subscriptionName, topicName, config, 0); | 345 | 345 | return sub; | 346 | 346 | } | |
Collapse file Copy file name to clipboardExpand all lines: container-registry/container-analysis/src/test/java/com/example/containeranalysis/SamplesTests.java +2-2Lines changed: 2 additions & 2 deletions | Original file line number | Diff line number | Diff line change |
|---|
| 25 | 25 | import com.google.containeranalysis.v1alpha1.Note; | 26 | 26 | import com.google.containeranalysis.v1alpha1.Occurrence; | 27 | 27 | import com.google.containeranalysis.v1alpha1.VulnerabilityType.VulnerabilityDetails; | 28 | | -import com.google.pubsub.v1.SubscriptionName; | | 28 | +import com.google.pubsub.v1.ProjectSubscriptionName; | 29 | 29 | import java.util.Date; | 30 | 30 | import org.junit.After; | 31 | 31 | import org.junit.Before; | @@ -194,7 +194,7 @@ public void testPubSub() throws Exception { | 194 | 194 | int newCount; | 195 | 195 | int tries; | 196 | 196 | String subscriptionId = "drydockOccurrences"; | 197 | | - SubscriptionName subscriptionName = SubscriptionName.of(PROJECT_ID, subscriptionId); | | 197 | + ProjectSubscriptionName subscriptionName = ProjectSubscriptionName.of(PROJECT_ID, subscriptionId); | 198 | 198 |
| 199 | 199 | Samples.createOccurrenceSubscription(subscriptionId, PROJECT_ID); | 200 | 200 | Subscriber subscriber = null; | |
Collapse file Copy file name to clipboardExpand all lines: dataflow/spanner-io/src/test/java/com/example/dataflow/SpannerGroupWriteIT.java +8-8Lines changed: 8 additions & 8 deletions | Original file line number | Diff line number | Diff line change |
|---|
| 49 | 49 | @SuppressWarnings("checkstyle:abbreviationaswordinname") | 50 | 50 | public class SpannerGroupWriteIT { | 51 | 51 |
| 52 | | - String instanceId; | 53 | | - String databaseId; | | 52 | + private String instanceId; | | 53 | + private String databaseId; | 54 | 54 |
| 55 | | - Path tempPath; | 56 | | - Spanner spanner; | 57 | | - SpannerOptions spannerOptions; | | 55 | + private Path tempPath; | | 56 | + private Spanner spanner; | | 57 | + private SpannerOptions spannerOptions; | 58 | 58 |
| 59 | 59 | @Before | 60 | 60 | public void setUp() throws Exception { | @@ -93,7 +93,7 @@ public void setUp() throws Exception { | 93 | 93 |
| 94 | 94 | @Nullable | 95 | 95 | @Override | 96 | | - public Void run(TransactionContext tx) throws Exception { | | 96 | + public Void run(TransactionContext tx) { | 97 | 97 | tx.buffer(mutations); | 98 | 98 | return null; | 99 | 99 | } | @@ -106,7 +106,7 @@ public Void run(TransactionContext tx) throws Exception { | 106 | 106 | } | 107 | 107 |
| 108 | 108 | @After | 109 | | - public void tearDown() throws Exception { | | 109 | + public void tearDown() { | 110 | 110 | DatabaseAdminClient adminClient = spanner.getDatabaseAdminClient(); | 111 | 111 | try { | 112 | 112 | adminClient.dropDatabase(instanceId, databaseId); | @@ -118,7 +118,7 @@ public void tearDown() throws Exception { | 118 | 118 | } | 119 | 119 |
| 120 | 120 | @Test | 121 | | - public void testEndToEnd() throws Exception { | | 121 | + public void testEndToEnd() { | 122 | 122 | SpannerGroupWrite.main( | 123 | 123 | new String[] { "--instanceId=" + instanceId, "--databaseId=" + databaseId, | 124 | 124 | "--suspiciousUsersFile=" + tempPath, "--runner=DirectRunner" }); | |
Collapse file Copy file name to clipboardExpand all lines: dataflow/spanner-io/src/test/java/com/example/dataflow/SpannerReadIT.java +7-7Lines changed: 7 additions & 7 deletions | Original file line number | Diff line number | Diff line change |
|---|
| 43 | 43 | @SuppressWarnings("checkstyle:abbreviationaswordinname") | 44 | 44 | public class SpannerReadIT { | 45 | 45 |
| 46 | | - String instanceId; | 47 | | - String databaseId; | | 46 | + private String instanceId; | | 47 | + private String databaseId; | 48 | 48 |
| 49 | | - Spanner spanner; | 50 | | - SpannerOptions spannerOptions; | | 49 | + private Spanner spanner; | | 50 | + private SpannerOptions spannerOptions; | 51 | 51 |
| 52 | 52 | @Before | 53 | | - public void setUp() throws Exception { | | 53 | + public void setUp() { | 54 | 54 | instanceId = System.getProperty("spanner.test.instance"); | 55 | 55 | databaseId = "df-spanner-read-it"; | 56 | 56 |
| @@ -115,15 +115,15 @@ public void setUp() throws Exception { | 115 | 115 | runner.run(new TransactionRunner.TransactionCallable<Void>() { | 116 | 116 | @Nullable | 117 | 117 | @Override | 118 | | - public Void run(TransactionContext tx) throws Exception { | | 118 | + public Void run(TransactionContext tx) { | 119 | 119 | tx.buffer(mutations); | 120 | 120 | return null; | 121 | 121 | } | 122 | 122 | }); | 123 | 123 | } | 124 | 124 |
| 125 | 125 | @After | 126 | | - public void tearDown() throws Exception { | | 126 | + public void tearDown() { | 127 | 127 | DatabaseAdminClient adminClient = spanner.getDatabaseAdminClient(); | 128 | 128 | try { | 129 | 129 | adminClient.dropDatabase(instanceId, databaseId); | |
Collapse file Copy file name to clipboardExpand all lines: dataflow/spanner-io/src/test/java/com/example/dataflow/SpannerWriteIT.java +8-8Lines changed: 8 additions & 8 deletions | Original file line number | Diff line number | Diff line change |
|---|
| 43 | 43 | @SuppressWarnings("checkstyle:abbreviationaswordinname") | 44 | 44 | public class SpannerWriteIT { | 45 | 45 |
| 46 | | - String instanceId; | 47 | | - String databaseId; | | 46 | + private String instanceId; | | 47 | + private String databaseId; | 48 | 48 |
| 49 | | - Path singersPath; | 50 | | - Path albumsPath; | 51 | | - Spanner spanner; | 52 | | - SpannerOptions spannerOptions; | | 49 | + private Path singersPath; | | 50 | + private Path albumsPath; | | 51 | + private Spanner spanner; | | 52 | + private SpannerOptions spannerOptions; | 53 | 53 |
| 54 | 54 | @Before | 55 | 55 | public void setUp() throws Exception { | @@ -95,7 +95,7 @@ public void setUp() throws Exception { | 95 | 95 | } | 96 | 96 |
| 97 | 97 | @After | 98 | | - public void tearDown() throws Exception { | | 98 | + public void tearDown() { | 99 | 99 | DatabaseAdminClient adminClient = spanner.getDatabaseAdminClient(); | 100 | 100 | try { | 101 | 101 | adminClient.dropDatabase(instanceId, databaseId); | @@ -107,7 +107,7 @@ public void tearDown() throws Exception { | 107 | 107 | } | 108 | 108 |
| 109 | 109 | @Test | 110 | | - public void testEndToEnd() throws Exception { | | 110 | + public void testEndToEnd() { | 111 | 111 | SpannerWrite.main(new String[] { "--instanceId=" + instanceId, "--databaseId=" + databaseId, | 112 | 112 | "--singersFilename=" + singersPath, "--albumsFilename=" + albumsPath, | 113 | 113 | "--runner=DirectRunner" }); | |
Collapse file Copy file name to clipboardExpand all lines: errorreporting/src/main/java/com/example/errorreporting/QuickStart.java +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
@@ -38,7 +38,7 @@ public static void main(String[] args) throws Exception { | 38 | 38 |
| 39 | 39 | // Google Cloud Platform Project ID | 40 | 40 | String projectId = (args.length > 0) ? args[0] : ServiceOptions.getDefaultProjectId(); | 41 | | - ProjectName projectName = ProjectName.create(projectId); | | 41 | + ProjectName projectName = ProjectName.of(projectId); | 42 | 42 |
| 43 | 43 | // Instantiate an Error Reporting Client | 44 | 44 | try (ReportErrorsServiceClient reportErrorsServiceClient = ReportErrorsServiceClient.create()) { | |
Collapse file Copy file name to clipboardExpand all lines: monitoring/cloud-client/pom.xml +1-1Lines changed: 1 addition & 1 deletion | Original file line number | Diff line number | Diff line change |
|---|
| 55 | 55 | <dependency> | 56 | 56 | <groupId>com.google.cloud</groupId> | 57 | 57 | <artifactId>google-cloud-monitoring</artifactId> | 58 | | - <version>0.34.0-beta</version> | | 58 | + <version>0.38.0-beta</version> | 59 | 59 | </dependency> | 60 | 60 | <dependency> | 61 | 61 | <groupId>com.google.guava</groupId> | |
|