Skip to content

Commit 23734dc

Browse files
authored
Update dependencies and protos (temporalio#1625)
1 parent 4696302 commit 23734dc

File tree

10 files changed

+31
-64
lines changed

10 files changed

+31
-64
lines changed

.buildkite/pipeline.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
steps:
2-
- label: ":java: JDK18 Unit test with in-memory test service"
2+
- label: ":java: [Edge] Unit test with in-memory test service"
33
agents:
44
queue: "default"
55
docker: "*"
66
command: "./gradlew --no-daemon test -x checkLicenseMain -x checkLicenses -x spotlessCheck -x spotlessApply -x spotlessJava -P edgeDepsTest"
77
timeout_in_minutes: 15
88
plugins:
99
- docker-compose#v3.8.0:
10-
run: unit-test-test-service-jdk18
10+
run: unit-test-test-service-edge
1111
config: docker/buildkite/docker-compose.yaml
1212

1313
- label: ":docker: JDK8 Unit test with docker service"

build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ plugins {
1010
id 'org.cadixdev.licenser' version '0.6.1'
1111
id 'com.palantir.git-version' version "${palantirGitVersionVersion}" apply false
1212
id 'io.github.gradle-nexus.publish-plugin' version '1.1.0'
13-
id 'com.diffplug.spotless' version '6.14.0' apply false
13+
id 'com.diffplug.spotless' version '6.14.1' apply false
1414
id 'com.github.nbaztec.coveralls-jacoco' version "1.2.15" apply false
1515

1616
// id 'org.jetbrains.kotlin.jvm' version '1.4.32'
@@ -54,7 +54,7 @@ ext {
5454
// test scoped
5555
// we don't upgrade to 1.3 and 1.4 because they require slf4j 2.x
5656
logbackVersion = project.hasProperty("edgeDepsTest") ? '1.3.5' : '1.2.11'
57-
mockitoVersion = '5.1.0'
57+
mockitoVersion = '5.1.1'
5858
junitVersion = '4.13.2'
5959
}
6060

docker/buildkite/Dockerfile-JDK18 docker/buildkite/Dockerfile-JDK19

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM eclipse-temurin:18-focal
1+
FROM eclipse-temurin:19-jdk-focal
22

33
# Git is needed in order to update the dls submodule
44
RUN apt-get update && apt-get install -y protobuf-compiler git

docker/buildkite/docker-compose.yaml

+3-12
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ services:
2424
- 9042
2525

2626
temporal:
27-
image: temporaliotest/auto-setup:sha-cc2e0c0
27+
image: temporaliotest/auto-setup:latest
2828
ports:
2929
- "7233:7233"
3030
- "7234:7234"
@@ -59,10 +59,10 @@ services:
5959
volumes:
6060
- "../../:/temporal-java-client"
6161

62-
unit-test-test-service-jdk18:
62+
unit-test-test-service-edge:
6363
build:
6464
context: ../../
65-
dockerfile: ./docker/buildkite/Dockerfile-JDK18
65+
dockerfile: ./docker/buildkite/Dockerfile-JDK19
6666
environment:
6767
- "USER=unittest"
6868
- "USE_DOCKER_SERVICE=false"
@@ -75,14 +75,5 @@ services:
7575
dockerfile: ./docker/buildkite/Dockerfile-JDK11
7676
environment:
7777
- "USER=unittest"
78-
volumes:
79-
- "../../:/temporal-java-client"
80-
81-
jdk18:
82-
build:
83-
context: ../../
84-
dockerfile: ./docker/buildkite/Dockerfile-JDK18
85-
environment:
86-
- "USER=unittest"
8778
volumes:
8879
- "../../:/temporal-java-client"

gradle/linting.gradle

+1-6
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,7 @@ subprojects {
1010
}
1111

1212
kotlin {
13-
ktlint('0.47.1')
14-
.setUseExperimental(true)
15-
// needs to be aligned with .editorconfig
16-
// https://github.com/diffplug/spotless/tree/main/plugin-gradle#ktlint
17-
// reenable filename rule after https://github.com/pinterest/ktlint/issues/1521
18-
.editorConfigOverride(['indent_size': '2', 'ktlint_disabled_rules': 'filename'])
13+
ktlint('0.48.2')
1914
}
2015
}
2116

temporal-kotlin/.editorconfig

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1+
root = true
2+
13
[*.{kt,kts}]
24
indent_size = 2
3-
# reenable filename rule after https://github.com/pinterest/ktlint/issues/1521
4-
ktlint_disabled_rules = filename
5+
6+
ij_kotlin_allow_trailing_comma = false
7+
ij_kotlin_allow_trailing_comma_on_call_site = false

temporal-serviceclient/build.gradle

+6-19
Original file line numberDiff line numberDiff line change
@@ -63,27 +63,14 @@ protobuf {
6363
// version/variables substitution is not supported in protobuf section.
6464
// protoc and protoc-gen-grpc-java versions are selected to be compatible
6565
// with the oldest supported versions of protoc and grpc artifacts.
66-
// For aarch64 (M1) using oldest version with binary available for this platform
67-
if (System.getProperty("os.arch") == 'aarch64') {
68-
protoc {
69-
artifact = 'com.google.protobuf:protoc:3.21.12'
70-
}
71-
plugins {
72-
grpc {
73-
artifact = 'io.grpc:protoc-gen-grpc-java:1.48.2'
74-
}
75-
}
76-
} else {
77-
protoc {
78-
artifact = 'com.google.protobuf:protoc:3.10.1'
79-
}
80-
plugins {
81-
grpc {
82-
artifact = 'io.grpc:protoc-gen-grpc-java:1.34.1'
83-
}
66+
protoc {
67+
artifact = 'com.google.protobuf:protoc:3.10.1' + (System.getProperty("os.arch") == 'aarch64' ? ':osx-x86_64' : '')
68+
}
69+
plugins {
70+
grpc {
71+
artifact = 'io.grpc:protoc-gen-grpc-java:1.34.1' + (System.getProperty("os.arch") == 'aarch64' ? ':osx-x86_64' : '')
8472
}
8573
}
86-
8774
generateProtoTasks {
8875
all().each { task -> task.dependsOn updateSubmodules }
8976
all()*.plugins {

temporal-serviceclient/src/main/proto

temporal-test-server/build.gradle

+6-18
Original file line numberDiff line numberDiff line change
@@ -67,24 +67,12 @@ protobuf {
6767
// version/variables substitution is not supported in protobuf section.
6868
// protoc and protoc-gen-grpc-java versions are selected to be compatible
6969
// with the oldest supported versions of protoc and grpc artifacts.
70-
// For aarch64 (M1) using oldest version with binary available for this platform
71-
if (System.getProperty("os.arch") == 'aarch64') {
72-
protoc {
73-
artifact = 'com.google.protobuf:protoc:3.21.12'
74-
}
75-
plugins {
76-
grpc {
77-
artifact = 'io.grpc:protoc-gen-grpc-java:1.48.2'
78-
}
79-
}
80-
} else {
81-
protoc {
82-
artifact = 'com.google.protobuf:protoc:3.10.1'
83-
}
84-
plugins {
85-
grpc {
86-
artifact = 'io.grpc:protoc-gen-grpc-java:1.34.1'
87-
}
70+
protoc {
71+
artifact = 'com.google.protobuf:protoc:3.10.1' + (System.getProperty("os.arch") == 'aarch64' ? ':osx-x86_64' : '')
72+
}
73+
plugins {
74+
grpc {
75+
artifact = 'io.grpc:protoc-gen-grpc-java:1.34.1' + (System.getProperty("os.arch") == 'aarch64' ? ':osx-x86_64' : '')
8876
}
8977
}
9078
generateProtoTasks {

temporal-testing/src/main/java/io/temporal/testing/TestWorkflowEnvironmentInternal.java

+4-1
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,10 @@ public boolean registerSearchAttribute(String name, IndexedValueType type) {
204204
"Class " + type + " can't be used as a search attribute type");
205205
}
206206
AddSearchAttributesRequest request =
207-
AddSearchAttributesRequest.newBuilder().putSearchAttributes(name, type).build();
207+
AddSearchAttributesRequest.newBuilder()
208+
.setNamespace(getNamespace())
209+
.putSearchAttributes(name, type)
210+
.build();
208211
try {
209212
operatorServiceStubs.blockingStub().addSearchAttributes(request);
210213
return true;

0 commit comments

Comments
 (0)