Skip to content

Commit f89b9a1

Browse files
chore: generate libraries at Mon Oct 14 16:58:14 UTC 2024
1 parent 54131e8 commit f89b9a1

File tree

4 files changed

+20
-21
lines changed

4 files changed

+20
-21
lines changed

README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ If you are using Maven with [BOM][libraries-bom], add this to your pom.xml file:
3636

3737
If you are using Maven without the BOM, add this to your dependencies:
3838

39-
<!-- {x-version-update-start:google-cloud-datastore:released} -->
4039

4140
```xml
4241
<dependency>
@@ -57,15 +56,14 @@ implementation 'com.google.cloud:google-cloud-datastore'
5756
If you are using Gradle without BOM, add this to your dependencies:
5857

5958
```Groovy
60-
implementation 'com.google.cloud:google-cloud-datastore:2.22.0'
59+
implementation 'com.google.cloud:google-cloud-datastore:2.23.0'
6160
```
6261

6362
If you are using SBT, add this to your dependencies:
6463

6564
```Scala
66-
libraryDependencies += "com.google.cloud" % "google-cloud-datastore" % "2.22.0"
65+
libraryDependencies += "com.google.cloud" % "google-cloud-datastore" % "2.23.0"
6766
```
68-
<!-- {x-version-update-end} -->
6967

7068
## Authentication
7169

@@ -481,7 +479,7 @@ Java is a registered trademark of Oracle and/or its affiliates.
481479
[kokoro-badge-link-5]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-datastore/java11.html
482480
[stability-image]: https://img.shields.io/badge/stability-stable-green
483481
[maven-version-image]: https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-datastore.svg
484-
[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-datastore/2.22.0
482+
[maven-version-link]: https://central.sonatype.com/artifact/com.google.cloud/google-cloud-datastore/2.23.0
485483
[authentication]: https://github.com/googleapis/google-cloud-java#authentication
486484
[auth-scopes]: https://developers.google.com/identity/protocols/oauth2/scopes
487485
[predefined-iam-roles]: https://cloud.google.com/iam/docs/understanding-roles#predefined_roles

samples/snippets/src/main/java/com/example/datastore/filters/IndexingConsiderationQuery.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
import com.google.cloud.datastore.Query;
3030
import com.google.cloud.datastore.QueryResults;
3131
import com.google.cloud.datastore.StructuredQuery.CompositeFilter;
32-
import com.google.cloud.datastore.StructuredQuery.Filter;
3332
import com.google.cloud.datastore.StructuredQuery.OrderBy;
3433
import com.google.cloud.datastore.StructuredQuery.PropertyFilter;
3534

@@ -40,11 +39,12 @@ public static void invoke() throws Exception {
4039
Datastore datastore = DatastoreOptions.getDefaultInstance().getService();
4140

4241
// Build a query with multi inequal filters and optimized index order of index properties.
43-
Query<Entity> query = Query.newEntityQueryBuilder()
42+
Query<Entity> query =
43+
Query.newEntityQueryBuilder()
4444
.setKind("employees")
45-
.setFilter(CompositeFilter.and(
46-
PropertyFilter.gt("salary", 100000),
47-
PropertyFilter.gt("experience", 0)))
45+
.setFilter(
46+
CompositeFilter.and(
47+
PropertyFilter.gt("salary", 100000), PropertyFilter.gt("experience", 0)))
4848
.setOrderBy(OrderBy.asc("salary"), OrderBy.asc("experience"))
4949
.build();
5050

samples/snippets/src/main/java/com/example/datastore/filters/OrderFieldsQuery.java

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
import com.google.cloud.datastore.Entity;
2929
import com.google.cloud.datastore.Query;
3030
import com.google.cloud.datastore.QueryResults;
31-
import com.google.cloud.datastore.StructuredQuery.Filter;
3231
import com.google.cloud.datastore.StructuredQuery.OrderBy;
3332
import com.google.cloud.datastore.StructuredQuery.PropertyFilter;
3433

@@ -40,11 +39,11 @@ public static void invoke() throws Exception {
4039

4140
// Build a query with order properties in the decreasing order of query constraint selectivity.
4241
Query<Entity> query =
43-
Query.newEntityQueryBuilder()
44-
.setKind("employees")
45-
.setFilter(PropertyFilter.gt("salary", 100000))
46-
.setOrderBy(OrderBy.asc("salary"))
47-
.build();
42+
Query.newEntityQueryBuilder()
43+
.setKind("employees")
44+
.setFilter(PropertyFilter.gt("salary", 100000))
45+
.setOrderBy(OrderBy.asc("salary"))
46+
.build();
4847

4948
// Get the results back from Datastore
5049
QueryResults<Entity> results = datastore.run(query);

samples/snippets/src/test/java/com/example/datastore/filters/MultiIneqQuerySampleIT.java

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,27 +38,29 @@ public class MultiIneqQuerySampleIT {
3838
private Key employeeKey2;
3939
private Key employeeKey3;
4040

41-
@Rule
42-
public final SystemsOutRule systemsOutRule = new SystemsOutRule();
41+
@Rule public final SystemsOutRule systemsOutRule = new SystemsOutRule();
4342

4443
@Before
4544
public void setUp() {
4645
employeeKey1 = datastore.newKeyFactory().setKind("employees").newKey("employee1");
47-
Entity employee1 = Entity.newBuilder(employeeKey1)
46+
Entity employee1 =
47+
Entity.newBuilder(employeeKey1)
4848
.set("name", "Alice")
4949
.set("salary", 100001)
5050
.set("experience", 10)
5151
.build();
5252

5353
employeeKey2 = datastore.newKeyFactory().setKind("employees").newKey("employee2");
54-
Entity employee2 = Entity.newBuilder(employeeKey2)
54+
Entity employee2 =
55+
Entity.newBuilder(employeeKey2)
5556
.set("name", "Bob")
5657
.set("salary", 90000)
5758
.set("experience", 5)
5859
.build();
5960

6061
employeeKey3 = datastore.newKeyFactory().setKind("employees").newKey("employee3");
61-
Entity employee3 = Entity.newBuilder(employeeKey3)
62+
Entity employee3 =
63+
Entity.newBuilder(employeeKey3)
6264
.set("name", "Jay")
6365
.set("salary", 120000)
6466
.set("experience", 15)

0 commit comments

Comments
 (0)