diff --git a/.buildkite/pipeline.yml b/.buildkite/pipeline.yml index 11e825b0c..c3f39360b 100644 --- a/.buildkite/pipeline.yml +++ b/.buildkite/pipeline.yml @@ -75,7 +75,7 @@ steps: config: docker/buildkite/docker-compose.yaml - label: ":java: Unit test with docker services sticky on" - timeout_in_minutes: 30 + timeout_in_minutes: 50 # integration tests take longer retry: automatic: - exit_status: "*" @@ -95,7 +95,7 @@ steps: config: docker/buildkite/docker-compose.yaml - label: ":java: Unit test with docker services sticky off" - timeout_in_minutes: 30 + timeout_in_minutes: 50 # integration tests take longer retry: automatic: - exit_status: "*" diff --git a/CHANGELOG.md b/CHANGELOG.md index d6d3c69ec..20c6ce42c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,32 @@ # Changelog +## 3.12.6 +- Adding logs to internal shadower to check for failures log (#918) +- Removing fossa as it is migrated to snyk (#919) +- Add codecov (#920) +- Add missing proto to thrift enum mappings and unit tests for both EnumMappers (#924) +- Remove unused code from cadence.internal package (#921) +- Refactor Test environment initialization to CadenceTestRule from WorkflowTest. (#923) +- upgrade mockito to 4.5.1 (#929) +- Report child workflow started synchronously (#928) +- Fix incorrect exception handling in WorkflowTchannelClient and add unit test coverage (#931) +- Fix WorkflowQueue#offer and increase test coverage (#932) +- Fix ActivityCompletionClient cancellation and failure by WorkflowExecution (#930) +- Fix incorrect exception for unsupported method in WorkflowService (#933) +- Fix flakiness in ManualActivityCompletionWorkflowTest (#937) +- Fix Domain GRPC->Thrift mapping and increase test coverage (#934) +- thrift install script (#939) +- Fix unimplementented methods of TestWorkflowEnvironment (#945) +- Fix bug in QueryWorkflowParameters.toString (#948) +- Fix NPE in RetryParameters and add unit tests to ExecuteActivityParameters (#946) +- Add copy function and unit tests to StartWorkflowExecutionParameters (#953) +- Fix Error handling and add test coverage for Thrift2ProtoAdapter (#950) +- Fix unhandled exceptions in WorkflowServiceTChannel (#954) +- Fix nil pointer issue (#982) +- add log and metrics on TBase message dataconverter usage (#986) +- added ExecutorWrapper in WorkerFactoryOptions (#988) +- Set skipArchival to true for getResultAsync (#990) + ## 3.12.5 - Fix transient test failures - Fix Request ID handling for server-side idempotency diff --git a/build.gradle b/build.gradle index f274cb3d9..242ddd4c7 100644 --- a/build.gradle +++ b/build.gradle @@ -29,13 +29,6 @@ apply plugin: 'org.jruyi.thrift' apply plugin: 'maven-publish' apply plugin: 'com.github.sherter.google-java-format' -if (hasProperty('signing.keyId')) { - apply plugin: 'signing' - signing { - sign configurations.archives - } -} - googleJavaFormat { toolVersion '1.5' include '**/*.java' @@ -45,7 +38,7 @@ googleJavaFormat { tasks.googleJavaFormat.dependsOn 'license' group = 'com.uber.cadence' -version = '3.12.5' +version = '3.12.6' description = '''Uber Cadence Java Client''' @@ -225,47 +218,40 @@ def ossrhUsername = hasProperty('ossrhUsername') ? property('ossrhUsername') : ' def ossrhPassword = hasProperty('ossrhPassword') ? property('ossrhPassword') : '' publishing { - publications { - // Uncomment below if you want to run "publishMavenLocal" - maven(MavenPublication) { - pom.withXml { - asNode().with { - appendNode('packaging', 'jar') - appendNode('name', 'cadence-client') - appendNode('description', description) - appendNode('url', 'https://github.com/uber-java/cadence-client') - appendNode('scm').with { - appendNode('url', 'https://github.com/uber-java/cadence-client') - appendNode('connection', 'git@github.com:uber-java/cadence-client.git') + mavenJava(MavenPublication) { + from components.java + artifact javadocJar + artifact sourcesJar + pom { + name = 'cadence-client' + description = 'Uber Cadence Java Client' + url = 'https://github.com/uber-java/cadence-client' + scm { + url = 'https://github.com/uber-java/cadence-client' + connection = 'scm:git:git@github.com:uber-java/cadence-client.git/' + developerConnection = 'scm:git:git@github.com:uber-java/cadence-client.git/' + } + licenses { + license { + name = 'The Apache License, Version 2.0' + url = 'http://www.apache.org/licenses/LICENSE-2.0.txt' } - appendNode('licenses').with { - appendNode('license').with { - appendNode('name', 'The Apache License, Version 2.0') - appendNode('url', 'http://www.apache.org/licenses/LICENSE-2.0.txt') - } + } + developers { + developer { + id = 'maxim' + name = 'Maxim Fateev' + email = 'maxim@uber.com' } - appendNode('developers').with { - appendNode('maxim').with { - appendNode('id', 'maxim') - appendNode('name', 'Maxim Fateev') - appendNode('email', 'maxim@uber.com') - } - appendNode('developer').with { - appendNode('id', 'meiliang') - appendNode('name', 'Liang Mei') - appendNode('email', 'meiliang@uber.com') - } + developer { + id = 'meiliang' + name = 'Liang Mei' + email = 'meiliang@uber.com' } } } } - - mavenJava(MavenPublication) { - from components.java - artifact javadocJar - artifact sourcesJar - } } repositories { maven { @@ -282,6 +268,14 @@ publishing { } } +if (hasProperty('signing.keyId')) { + apply plugin: 'signing' + signing { + sign configurations.archives + sign publishing.publications.mavenJava + } +} + task registerDomain(type:JavaExec) { main = 'com.uber.cadence.RegisterTestDomain' classpath = sourceSets.test.runtimeClasspath @@ -299,61 +293,6 @@ test { } } -uploadArchives { - repositories { - mavenDeployer { - beforeDeployment { MavenDeployment deployment -> signing.signPom(deployment) } - - repository(url: 'https://oss.sonatype.org/service/local/staging/deploy/maven2/') { - authentication(userName: ossrhUsername, password: ossrhPassword) - } - - snapshotRepository(url: 'https://oss.sonatype.org/content/repositories/snapshots/') { - authentication(userName: ossrhUsername, password: ossrhPassword) - } - - pom.project { - name 'cadence-client' - packaging 'jar' - // optionally artifactId can be defined here - description 'Uber Cadence Java Client' - url 'https://github.com/uber-java/cadence-client' - - scm { - connection 'scm:git:git@github.com:uber-java/cadence-client.git/' - developerConnection 'scm:git:git@github.com:uber-java/cadence-client.git/' - url 'https://github.com/uber-java/cadence-client' - } - - licenses { - license { - name 'The Apache License, Version 2.0' - url 'http://www.apache.org/licenses/LICENSE-2.0.txt' - } - } - - developers { - developer { - id 'maxim' - name 'Maxim Fateev' - email 'maxim@uber.com' - } - developer { - id 'mkol' - name 'Max K' - email 'mkol@uber.com' - } - developer { - id 'meiliang' - name 'Liang Mei' - email 'meiliang@uber.com' - } - } - } - } - } -} - jacoco { toolVersion = "0.8.2" } diff --git a/src/test/java/com/uber/cadence/converter/JsonDataConverterTest.java b/src/test/java/com/uber/cadence/converter/JsonDataConverterTest.java index 20743414a..57862ddc1 100644 --- a/src/test/java/com/uber/cadence/converter/JsonDataConverterTest.java +++ b/src/test/java/com/uber/cadence/converter/JsonDataConverterTest.java @@ -245,8 +245,6 @@ public NonSerializableException(Throwable cause) { } } - // TODO flaky test in local env: expected: but - // was: @Test public void testException() { RuntimeException rootException = new RuntimeException("root exception"); @@ -263,7 +261,9 @@ public void testException() { assertNotNull(causeFromConverted); assertEquals(DataConverterException.class, causeFromConverted.getClass()); assertNotNull(causeFromConverted.getCause()); - assertEquals(JsonIOException.class, causeFromConverted.getCause().getClass()); + assertTrue( + causeFromConverted.getCause() instanceof JsonIOException + || causeFromConverted.getCause() instanceof StackOverflowError); assertNotNull(causeFromConverted.getSuppressed()); assertEquals(1, causeFromConverted.getSuppressed().length);