Commit Graph

208 Commits

Author SHA1 Message Date
Artur Souza 81e6c4d907
Adds error payload to DaprException. (#1009)
* Adds error payload to DaprException.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Keep having http payload in exception message.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix example output.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Lint.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix test.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2024-02-15 10:28:48 -08:00
Cassie Coyle a3cc1384b5
Add the dapr runtime returned error details to the Java DaprException (#998)
* properly add the dapr runtime returned error details to the Java DaprException

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* add error handling to sdk docs

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* add tests for the dapr exception changes

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* try verifyNoMoreInteractions w/ channel

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* verify channel close -> channel close explicitly

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* rm verifyNoMoreInteractions

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* rm test to see if that is the orphaned managed channel issue

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* re-add test since that doesnt seem to be the issue

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* channel.close(); -> verify(channel).close();

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* Rewrite and redesign of the DaprErrorDetail in DaprException.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Update daprdocs too for DaprErrorDetails.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix README.md mm string.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix exception example.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Use runtime 1.13.0-rc.2

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix exception example to match gRPC output.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Update error message in IT as per new Dapr runtime version.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Dapr 1.13 is less tolerant of app downtime to keep timers.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
2024-02-13 13:34:50 -08:00
Cassie Coyle b2968af896
Resolve buildGrpcManagedChannel orphaned channel & ensure connections mocked (#1003)
* okhttpclient is mocked

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* mock workflowRuntime to rm log: 'The sidecar at address localhost:4001 is unavailable. Will continue retrying.'

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* fix several NetworkUtilsTest orphaned channels

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* reset workflow changes since I still see the log output

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* Close daprClient on DaprClientGrpcTelemetryTest

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* try latest runtime rc

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* Update runtime to 1.12.4

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Mvn test is now verbose, temporatily.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* try fixing RetryPolicyTest

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* comment out RetryPolicyTest

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* add RetryPolicyTest back

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* trying to figure out which test func is the issue

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* try ubuntu-20.04

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* try rm-ing GrpcChannelFacadeTest

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* try rm-ing DaprClientHttpTest

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* try t.join just in case

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is this the bad test?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* are these other healthcheck tests the problem?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it the ok test?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it due to an invoke test?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it the config/subscribeConfig tests

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it noHotMono?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it a publish test?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it the other noHotMono tests?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it a state test?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it a save state test?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it a secret test?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it a delete state test?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it the rest -1 and - ending tests?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* no client calls, only end of file remaining

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* add teardown - did it work?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* is it just needing daprClientHttpXML to be closed?

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* Reuse mock and builder.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Try dedicated executor.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Comment out the remaining tests.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Remove before and after.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Remove sdk/src/test/java/io/dapr/client/DaprClientHttpTest.java

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Remove sdk/src/test/java/io/dapr/client/DaprHttpTest.java.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Delete a batch of tests.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* restore deleted test files

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* add back in RetryPolicyTest

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

---------

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2024-02-08 14:47:32 -08:00
Artur Souza 22427c9659
Fix unit tests hanging (#1006)
* Fix DaprClientHttpTest and GrpcChannelFacadeTest

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Add timeout to build workflow.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Improve RetryPolicyTest.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix dependencies for gRPC mocking.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2024-02-08 13:55:22 -08:00
Sky Ao 7eb24ffc69
Add JDK17 and springboot 3.0 support (#975)
* add support for java17

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* upgrade spotbugs-maven-plugin version to support jdk17

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* add clean before install

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* add clean in mvn command

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* rollback spotbugs-maven-plugin version to 4.1.4

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* add jdk17 in build

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update to support jdk17

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* remove jdk versions earlier than jdk17

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* remove springboot 2.3 and 2.4 because they don't support jdk17

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update to jdk17

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update maven plugin versions to support jdk17

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* temporarily ignoring checking after upgrade to new spotbugs version to support jdk17

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* use the same version of maven-failsafe-plugin

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* hard code maven-failsafe-plugin version to 3.2.2

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* set sourceDirectory of checkstyle plugin to only check the sources directory, not test source and generated source

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* set release to jdk17 in examples subproject

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update to springboot 3.0

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* add springboot 3.0.13 in springboot version matrics

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* upgrade to springboot 3.0.13 in sdk-tests

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* remove Nullable annotation

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* force opentelemetry-sdk-metrics dependencies to be version 0.14.0

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* jakarta.servlet is needed for dapr compatibility for spring boot versions before 3.0

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update code to run with jakarta.servlet and javax.servlet

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update jakarta.annotation to latest version

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* add javax.annotation

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* trigger ci

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* revert back to using 3.0 version of the github action

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* revert back to use jdk11 for vallidate

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* jdk17 is required for vallidate

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* trigger ci

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* use jdk17 to validate

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* remove java8 support

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* use jdk11 to test springboot2.x and jdk17 to test springboot3.0

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* rollback to jdk17 to test for springboot2.x

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* rename springboot30 to springboot3

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* skip mvn test in mvn install

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* add more exclude for spotbugs

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* add more exclude for spotbugs

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* set java source and target to 17 in sdk-tests

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* rollback root pom.xml to remove sdk-tests module

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* exclude logback to avoid conflicts

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* replace ctx.getLogger() with sysout

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update stdout line according to source code

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* rollback validate line, replace ctx.getLogger() with system out in wofklow

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* rollback example code for subworkflow

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* print ctx.getLogger() and instanceId for debug

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* rollback to not exclude logback

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* add slf4j as compile dependency and upgrade its version to 2.0.9

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* print the logger implementation class

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* remove debug code

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

---------

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
2024-01-15 08:30:35 -08:00
siebenluke fdb4200a2c
Add additional CloudEvent fields (pubsubname, topic, time, etc) (#866)
* Added additional CloudEvent fields (pubsubname, topic, time, traceid, traceparent, & tracestate)

Added the com.fasterxml.jackson:jackson-datatype-jsr310 dependency to handle serdes of OffsetDateTime for the CloudEvent time field via ObjectMapper settings .configure(SerializationFeature.WRITE_DATES_AS_TIMESTAMPS, false) & .findAndRegisterModules()

Updated com.fasterxml.jackson dependencies to the latest 2.15.1

Added OffsetDateTime as timeValue to test the DefaultObjectSerializer

Added more tests for new & old CloudEvent fields in CloudEventTest & DefaultObjectSerializerTest

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Refactored new field names to be camelCase

Removed the 2 new constructors

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Added @JsonProperty("{lowercasename}")s to properly serdes camelCaseNames as JSON/OBJECT_MAPPER are case-sensitive

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Removed com.fasterxml.jackson.datatype:jackson-datatype-jsr310 dependency in favor of custom field level serdes for time

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Fixed "Line is longer than 120 characters" build issue by pushing the end of the offending lines to a new line

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Added more CloudEvent test cases to appease Codecov

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Added null binaryData test case for Codecov

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Added cloudEventDifferent test cases for Codecov

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Removed extraneous ;

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

* Added comments for time test cases

Signed-off-by: Luke Sieben <siebenluke@gmail.com>

---------

Signed-off-by: Luke Sieben <siebenluke@gmail.com>
Co-authored-by: Dapr Bot <56698301+dapr-bot@users.noreply.github.com>
Co-authored-by: Cassie Coyle <cassie@diagrid.io>
2024-01-10 17:25:14 -08:00
Cassie Coyle 49ccb31dcc
add health check to wait for sidecar and test it (#918)
* add health check to wait for sidecar and test it

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* split long line into 2

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* addRule to failing waitForSidecar test

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* update the http retry on healthcheck and add to tests

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* add success test since failure scenarios are covered

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* update the grpc logic to call the http endpoint

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* add endpoint for grpc to be successful

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* up timeout and make return more similar to http

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* up time for test again

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* added comment on getState not being implemented

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* add daprhttp to grpc to use and overload constructor

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* shorten time in grpc test

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* update grpc return to match http check

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* testing if this fixes CI issue on managed channel not closing properly

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* close daprHttp in teardown func

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* Fix telemetry test that uses GrpcChannelFacade.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* close daprHttp

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* triggering CI again

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

---------

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>
Signed-off-by: Cassie Coyle <cassie@diagrid.io>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
2023-12-18 20:31:42 -08:00
MregXN c91c4102d7
fix invoke HEAD method failure (#952)
* fix invoke HEAD method failure

Signed-off-by: MregXN <mregxn@gmail.com>

* add unit test

Signed-off-by: MregXN <mregxn@gmail.com>

* remove unused package

Signed-off-by: MregXN <mregxn@gmail.com>

---------

Signed-off-by: MregXN <mregxn@gmail.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2023-11-27 11:14:23 -08:00
kaibocai 4c63abd07d
Add determinstic UUID generation (#947)
* add determinstic UUID generation

Signed-off-by: kaibocai <89094811+kaibocai@users.noreply.github.com>

* add unit test to improve coverage

Signed-off-by: kaibocai <89094811+kaibocai@users.noreply.github.com>

* update grpc version to 1.59.0 to be compatible updated durabletask-java

Signed-off-by: kaibocai <kaibocai@microsoft.com>

---------

Signed-off-by: kaibocai <89094811+kaibocai@users.noreply.github.com>
Signed-off-by: kaibocai <kaibocai@microsoft.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2023-11-14 07:59:19 -08:00
Artur Souza 0d0d59946f
Generate updated javadocs for 1.10.0 (#937)
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2023-10-11 16:55:35 -07:00
Artur Souza d192ed8bb6
Next release 1.11.0 snapshot (#934)
* Fix release script to handle workflows sdk.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Upgrade the version to 1.11.0-SNAPSHOT

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2023-10-03 14:12:28 -07:00
Emanuel Alves 56d9270a0a
Migrate to Junit5 (#910)
* Migrating to Junit5

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* Fix spotbugs errors

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* Fix spotbugs errors

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* remove unreachable code due to expected exception being thrown

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* Increase daprRun timeout

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* wait 5 secs before launching toxiproxy

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* Rollback spotbugs bump version

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* extract junit-bom version to a property

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* Change settings in SdkResiliencyIT to reduce flakiness.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Wait for sidecar in SDKResiliencyIT

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
2023-09-22 10:25:10 -07:00
huazhongming 86893a0742
Support distributed lock API (#764)
* support distributed lock API

Signed-off-by: crazyhzm <crazyhzm@gmail.com>

* add Distributed Lock API Example

Signed-off-by: crazyhzm <crazyhzm@gmail.com>

* fix bash

Signed-off-by: crazyhzm <crazyhzm@gmail.com>

* fix bash

Signed-off-by: crazyhzm <crazyhzm@gmail.com>

* update dapr proto version

Signed-off-by: crazyhzm <crazyhzm@gmail.com>

* revert update dapr proto version

Signed-off-by: crazyhzm <crazyhzm@gmail.com>

* changed to json serializable

Signed-off-by: crazyhzm <crazyhzm@gmail.com>

* fix checkstyle

Signed-off-by: crazyhzm <crazyhzm@gmail.com>

* Fix compilation error due to Mono version change.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: crazyhzm <crazyhzm@gmail.com>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
2023-09-21 21:54:59 -07:00
Cassie Coyle 64423bdac6
Docs update examples (#908)
* fixing typos and broken links in examples

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

* rm dup init cmd

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

---------

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>
2023-09-18 23:15:05 -07:00
Sky Ao 4dbcbde14d
Support Dapr API token in workflow client(fix DCO) (#916)
* change to be public to reuse in workflow subproject

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update buildGrpcManagedChannel() method to accept optional parameters for grpc client interceptors

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* support dapr API token while build grpc management channel

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

---------

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>
2023-09-17 21:28:03 -07:00
Cassie Coyle 0543011d59
Updated enable dead letter topic (#913)
* feat: Add dead letter topic to a subscription topic.

Signed-off-by: Charlie Mk <carlosrb00@gmail.com>

* feat: Add endpoint examples

Signed-off-by: Charlie Mk <carlosrb00@gmail.com>

* feat: Add dead letter topic example to the docs.

Signed-off-by: Charlie Mk <carlosrb00@gmail.com>

* Create new methods with deadLetterTopic instead of overload existing ones.

Signed-off-by: Charlie Mk <carlosrb00@gmail.com>

* Update _index.md

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Create overloads for deadlettertopic.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* fix integration tests from names overlapping

Signed-off-by: Cassandra Coyle <cassie@diagrid.io>

---------

Signed-off-by: Charlie Mk <carlosrb00@gmail.com>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Cassandra Coyle <cassie@diagrid.io>
Co-authored-by: Charlie Mk <carlosrb00@gmail.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Co-authored-by: Yaron Schneider <schneider.yaron@live.com>
2023-09-14 17:28:29 -07:00
Mahmut Canga 056aed4d98
Workflow Implementation - Continues... (#880)
* Add ElementType.Type to ActorType (#812)

Signed-off-by: LionTao <taojiachun980831@163.com>

Signed-off-by: LionTao <taojiachun980831@163.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Bump codecov/codecov-action from 3.1.0 to 3.1.1 (#788)

Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 3.1.0 to 3.1.1.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/master/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v3.1.0...v3.1.1)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Update springboot to latest minor.patch version. (#826)

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Use runtime 1.10.0-rc.X and CLI 1.10.0-rc.X (#827)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Upgrade the version to 1.9.0-SNAPSHOT (#829)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Generate updated javadocs for 1.8.0 (#836)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Update Dapr runtime and CLI to 1.10. (#837)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Inject autoconfiguration in the Spring Boot 3 style (#831)

* Bump from spring boot 2.3.5.RELEASE to 2.7.8

Signed-off-by: Sergio <champel@gmail.com>
(cherry picked from commit 9152c91bc1f08ecf2dd3bccf8159fd5d0500e351)

* Ensure old versions of spring boot are still compatible

Signed-off-by: Sergio <champel@gmail.com>

---------

Signed-off-by: champel <champel@gmail.com>
Signed-off-by: Sergio <champel@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Bump from reactor 2.3.5.RELEASE to 2.7.8 (#830)

* Bump from reactor 2.3.5.RELEASE to 2.7.8

Signed-off-by: Sergio <champel@gmail.com>

* Simplification

Signed-off-by: Sergio <champel@gmail.com>

---------

Signed-off-by: Sergio <champel@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Test multiple reminder state types + improve timer tests. (#855)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Convert Config API to Stable endpoints. (#846)

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Add PubSub subscriber examples over gPRC (#833)

* add grpc subscriber

Signed-off-by: MregXN <mregxn@gmail.com>

* modify README.md

Signed-off-by: MregXN <mregxn@gmail.com>

* modify README.md in examples

Signed-off-by: MregXN <mregxn@gmail.com>

* Modify DaprApplication to support examples where protocol is not specified.

Signed-off-by: MregXN <mregxn@gmail.com>

* modify formatter to pass checkstyle

Signed-off-by: MregXN <mregxn@gmail.com>

* Update springboot to latest minor.patch version. (#826)

Signed-off-by: MregXN <mregxn@gmail.com>

* Use runtime 1.10.0-rc.X and CLI 1.10.0-rc.X (#827)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: MregXN <mregxn@gmail.com>

* Upgrade the version to 1.9.0-SNAPSHOT (#829)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: MregXN <mregxn@gmail.com>

* Generate updated javadocs for 1.8.0 (#836)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: MregXN <mregxn@gmail.com>

* Update Dapr runtime and CLI to 1.10. (#837)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: MregXN <mregxn@gmail.com>

* Inject autoconfiguration in the Spring Boot 3 style (#831)

* Bump from spring boot 2.3.5.RELEASE to 2.7.8

Signed-off-by: Sergio <champel@gmail.com>
(cherry picked from commit 9152c91bc1f08ecf2dd3bccf8159fd5d0500e351)

* Ensure old versions of spring boot are still compatible

Signed-off-by: Sergio <champel@gmail.com>

---------

Signed-off-by: champel <champel@gmail.com>
Signed-off-by: Sergio <champel@gmail.com>
Signed-off-by: MregXN <mregxn@gmail.com>

* Bump from reactor 2.3.5.RELEASE to 2.7.8 (#830)

* Bump from reactor 2.3.5.RELEASE to 2.7.8

Signed-off-by: Sergio <champel@gmail.com>

* Simplification

Signed-off-by: Sergio <champel@gmail.com>

---------

Signed-off-by: Sergio <champel@gmail.com>
Signed-off-by: MregXN <mregxn@gmail.com>

* rerun checks

Signed-off-by: MregXN <mregxn@gmail.com>

* modify the way of grpc server starts

Signed-off-by: MregXN <mregxn@gmail.com>

* modify README

Signed-off-by: MregXN <mregxn@gmail.com>

* Update pom.xml

Signed-off-by: MregXN <46479059+MregXN@users.noreply.github.com>

---------

Signed-off-by: MregXN <mregxn@gmail.com>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: champel <champel@gmail.com>
Signed-off-by: Sergio <champel@gmail.com>
Signed-off-by: MregXN <46479059+MregXN@users.noreply.github.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: champel <champel@gmail.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* auto validate actors (#863)

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Bump codecov/codecov-action from 3.1.1 to 3.1.4 (#862)

Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 3.1.1 to 3.1.4.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/v3.1.1...v3.1.4)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Fix 787 (#832)

* prepare before testing

* Update tests

* fix checkstyle

---------

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Upgrade to 1.11 RCs. (#867)

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Init for workflows

Signed-off-by: Bill DeRusha <billderusha@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Updating some javadocs and Years.

Signed-off-by: Hannah Kennedy <hakenned@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Add missing Header

Signed-off-by: Hannah Kennedy <hakenned@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* respond to PR feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Update workflow example README

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Address PR feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* fixup deprecated pom.xml variable

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Updates based on PR feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Update pom files per feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* GetInstanceState implementation (#1)

* addiny getInstanceMetadata, waitForInstanceStart and waitForInstanceCompletion implementation
---------

Co-authored-by: aymanmahmoud_microsoft <aymanmahmoud@microsoft.com>
Signed-off-by: Aymand Mahmoud <aymanmahmoud@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Management API

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* remove try/catch

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* implementing getIsReplaying() method for Authoring API (#7)

Co-authored-by: Julio Rezende <jsilvarezend@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>
Signed-off-by: Julio Rezende <jsilvarezend@microsoft.com>

* Implementing getCurrentInstant() authoring method (#5)

Co-authored-by: Julio Rezende <jsilvarezend@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>
Signed-off-by: Julio Rezende <jsilvarezend@microsoft.com>

* Activity Implementation (#3)

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* fixing issue with getIsReplaying() call (#8)

Co-authored-by: Julio Rezende <jsilvarezend@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>
Signed-off-by: Julio Rezende <jsilvarezend@microsoft.com>

* Generate updated javadocs for 1.9.0 (#878)

* Generate updated javadocs for 1.9.0

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Update _index.md

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Add .sdkmanrc config file and JDK installation instructions (#873)

* Add .sdkmanrc file with installation instructions

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>

* Update README.md

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Add unit testing example

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* implementing getIsReplaying() method for Authoring API (#7)

Co-authored-by: Julio Rezende <jsilvarezend@microsoft.com>

Signed-off-by: Julio Rezende <jsilvarezend@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* fix parent pom

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Send Event Implementation (#10)

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Implementing allOf, anyOf, createTimer methods (#11)

Co-authored-by: Julio Rezende <jsilvarezend@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>
Co-authored-by: Julio Rezende <jsilvarezend@microsoft.com>

* Support remote endpoint. (#877)

* Support remote endpoint.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Use GRPC_ENDPOINT and HTTP_ENDPOINT in integration tests.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix happy path for waiting for sidecar test.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Add callSubWorkflow Implementation

Co-authored-by: Aymand Mahmoud <aymanmahmoud@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>
Signed-off-by: Aymand Mahmoud <aymanmahmoud@microsoft.com>

* rename DemoSubWorkflow

Co-authored-by: Aymand Mahmoud <aymanmahmoud@microsoft.com>
Signed-off-by: Aymand Mahmoud <aymanmahmoud@microsoft.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* continueAsNew Implementation (#13)

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* remove duplicate class

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* add missing mockito test dependency

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* use new workflow client implementation

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* moved implementations to new workflow and context

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* relocate duplicate implemantation

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* remove duplicate test and increase test coverage

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* Implement retry and timeout policy for gRPC client. (#889)

* Implement retry and timeout policy for gRPC client.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix invoke actor after aborted flow.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* renamed getIsReplaying

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* rollback changes on client

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* move workflow runtime state package

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* rename workflow instance state to status

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* remove unnecessary else

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* removed unknown state

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* updated comment

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* updated workflow failure details

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* fix style issues

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* rollback merge change

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* fixed pom files

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* rollback actors pom changes on autoformat

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* fixe actors pom

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* fix styling on actors pom

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* fix pom spacing

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* move test to match the package

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* add missing dependencies

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* increased test coverage

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* moved workflow runtime package

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* add exception for missing case

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* add null check for metadata

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* add runtime exception error messages

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* update try catch scope

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* update activity definition to an interface

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* update comments

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* removed redundant method

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

* PR updates

Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>

---------

Signed-off-by: LionTao <taojiachun980831@163.com>
Signed-off-by: Mahmut Canga <cangamahmut@gmail.com>
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Signed-off-by: champel <champel@gmail.com>
Signed-off-by: Sergio <champel@gmail.com>
Signed-off-by: MregXN <mregxn@gmail.com>
Signed-off-by: MregXN <46479059+MregXN@users.noreply.github.com>
Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Signed-off-by: Bill DeRusha <billderusha@microsoft.com>
Signed-off-by: Hannah Kennedy <hakenned@microsoft.com>
Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Signed-off-by: Aymand Mahmoud <aymanmahmoud@microsoft.com>
Signed-off-by: Julio Rezende <jsilvarezend@microsoft.com>
Signed-off-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>
Signed-off-by: Mahmut Canga <macromania@users.noreply.github.com>
Co-authored-by: LionTao <taojiachun980831@163.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: champel <champel@gmail.com>
Co-authored-by: MregXN <46479059+MregXN@users.noreply.github.com>
Co-authored-by: MatejNedic <matejnedic1@gmail.com>
Co-authored-by: Bill DeRusha <billderusha@microsoft.com>
Co-authored-by: Hannah Kennedy <hakenned@microsoft.com>
Co-authored-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Co-authored-by: Aymalla <Aymalla@outlook.com>
Co-authored-by: aymanmahmoud_microsoft <aymanmahmoud@microsoft.com>
Co-authored-by: swetakumari <swetakumari@microsoft.com>
Co-authored-by: julio <107879411+julioalex-rezende@users.noreply.github.com>
Co-authored-by: Julio Rezende <jsilvarezend@microsoft.com>
Co-authored-by: Emanuel Alves <emanuel.j.b.alves@gmail.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
2023-09-12 23:12:38 -07:00
Artur Souza cf8040dd6d
Implement retry and timeout policy for gRPC client. (#889)
* Implement retry and timeout policy for gRPC client.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix invoke actor after aborted flow.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2023-08-15 22:39:16 -07:00
Bill DeRusha 6d659913b1
Initial Workflow SDK (#857)
* Init for workflows

Signed-off-by: Bill DeRusha <billderusha@microsoft.com>

* Updating some javadocs and Years.

Signed-off-by: Hannah Kennedy <hakenned@microsoft.com>

* Add missing Header

Signed-off-by: Hannah Kennedy <hakenned@microsoft.com>

* respond to PR feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Update workflow example README

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Address PR feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* fixup deprecated pom.xml variable

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Updates based on PR feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Update pom files per feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Add unit testing example

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* update pom

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Fix dependency conflict

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Use Mono and refactor GRPC managed channel builder

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Fix example unit tests

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Implement PR feedback

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* PR Feedback: Revert Mono usage + pom.xml changes

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* pom.xml version fixes

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

* Remove Mono entirely from workflows

Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>

---------

Signed-off-by: Bill DeRusha <billderusha@microsoft.com>
Signed-off-by: Hannah Kennedy <hakenned@microsoft.com>
Signed-off-by: Bill DeRusha <444835+bderusha@users.noreply.github.com>
Co-authored-by: Hannah Kennedy <hakenned@microsoft.com>
2023-08-10 17:58:09 -07:00
Artur Souza 76aec01e9a
Fix Java SDK URI parsing. (#882)
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2023-06-22 14:02:43 -07:00
Artur Souza 201dbc5344
Support remote endpoint. (#877)
* Support remote endpoint.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Use GRPC_ENDPOINT and HTTP_ENDPOINT in integration tests.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

* Fix happy path for waiting for sidecar test.

Signed-off-by: Artur Souza <asouza.pro@gmail.com>

---------

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
2023-06-18 23:34:09 -07:00
Artur Souza d34bcb8c5e
Upgrade the version to 1.10.0-SNAPSHOT (#874)
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2023-06-09 14:35:23 -07:00
Mukundan Sundararajan aaa5f7bc76
Convert Config API to Stable endpoints. (#846) 2023-05-09 10:46:54 -07:00
champel 7649ae44b0
Bump from reactor 2.3.5.RELEASE to 2.7.8 (#830)
* Bump from reactor 2.3.5.RELEASE to 2.7.8

Signed-off-by: Sergio <champel@gmail.com>

* Simplification

Signed-off-by: Sergio <champel@gmail.com>

---------

Signed-off-by: Sergio <champel@gmail.com>
2023-03-22 09:41:45 -07:00
Artur Souza 10d09619db
Upgrade the version to 1.9.0-SNAPSHOT (#829)
Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2023-02-03 09:00:17 -08:00
Artur Souza 31a47f5521
Update springboot to latest minor.patch version. (#826) 2023-02-02 12:30:22 -08:00
Artur Souza beafb5a5b3
Deprecate HTTP client with warning. (#824)
Signed-off-by: Artur Souza <asouza.pro@gmail.com>

Signed-off-by: Artur Souza <asouza.pro@gmail.com>
2023-01-24 16:50:43 -08:00
Mukundan Sundararajan 81591b9f5b
initial bulk publish impl for java (#789)
* initial bulk publish impl for java

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* add UTs and clean up java doc for new interface methods.

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* add more interface methods for bulk publish

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* adding examples and ITs for bulk publish

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* addressing review comments

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* use latest ref from dapr branch

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* add example validation

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix bindings example validation

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* make changes for latest bulk publish dapr changes

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix examples

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix examples

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix typo

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* test against java 11 only

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* change to latest dapr commit

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* run only pubsub IT, upload failsafe reports as run artifact

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix checkstyle

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix IT report upload condition

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix compile issues

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix spotbugs issue

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* run pubsubIT only

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* change upload artifact name for IT

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix tests

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* introduce sleep

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* test bulk publish with redis

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* change longvalues test to kafka

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* change bulk pub to kafka and revert long values changes

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* remove kafka pubsub from pubsub IT

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* change match order in examples

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* set fail fast as false

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix Internal Invoke exception in ITs

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* address review comments

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix IT

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix app scopes in examples

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* add content to daprdocs

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* address review comments

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix mm.py step comment

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* reset bindings examples readme

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

* fix example, IT and make classes immutable

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>

Signed-off-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Co-authored-by: Artur Souza <asouza.pro@gmail.com>
2023-01-19 12:57:06 -08:00
Shubham Sharma eb8565cca0
feat(pubsub): add bulk subscribe support (#791) 2023-01-18 17:58:03 -08:00
addjuarez bc9de9fa7e
report sdk version in user-agent (#810)
* report sdk version in user-agent

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* make private

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* close input

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* style

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* debug

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* typo

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* use try resource block

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* fix exception

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* newline

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* use defaults

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* Use getSdkVersion()

Signed-off-by: addjuarez <addiajuarez@gmail.com>

Signed-off-by: addjuarez <addiajuarez@gmail.com>
2022-11-20 22:07:02 -08:00
dependabot[bot] 95afd236d8
Bump jackson-databind from 2.12.6.1 to 2.13.4.1 in /sdk (#801)
Bumps [jackson-databind](https://github.com/FasterXML/jackson) from 2.12.6.1 to 2.13.4.1.
- [Release notes](https://github.com/FasterXML/jackson/releases)
- [Commits](https://github.com/FasterXML/jackson/commits)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.core:jackson-databind
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2022-11-06 21:17:39 -08:00
Artur Souza a53f02d3d8
Upgrade the version to 1.8.0-SNAPSHOT (#796)
Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>
2022-11-06 21:16:47 -08:00
Artur Souza 5a2833ca63
Update Dapr and CLI to 1.9 RC1 (#795)
* Update Dapr and CLI to 1.9 RC1

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

* Fix HTTP service invocation without content-type.

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

* Update RCs.

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>
2022-10-03 11:21:16 -07:00
Pravin Pushkar 04e7298702
Config API : HTTP APIs and Unsubscribe gRPC API changes (#740)
* Config API : Unsubscribe config items changes

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Unit and integration tests changes

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Addressing review comments

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* GetConfiguration HTTP API impl

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Subscribe and Unsubscribe HTTP changes

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Subscribe config http changes

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Http unsubscribe and unit tests

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Integration tests for http config apis

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Fixing lint

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Chnaging rersponse of HTTP Unsubscribe API

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Fix integration test failure

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* refactor IT tests

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* code clean up

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* setting dapr ref

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Update readme

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Modify Unit tests

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Remove failing buggy tests

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* fix review commnets and integration tests

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* trigger pr check

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Fix for getAll keys

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Fix subscribe All

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Move http subscribe handle to dapr controller

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Simplified examples

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* change dapr ref, and add unit test

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* trigger pr checks

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* trigger pr checks

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Use biConsumer to register handlers

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Re use args contructors and re add final modifier

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* put dapr run back

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* fix nitpick

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Remove the springboot HTTP "convenience".

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>
Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>
Signed-off-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2022-09-29 20:37:46 -07:00
addjuarez bbb6a1d9c0
Removed final from CloudEvent class (#775)
* Remove final from CloudEvent Class

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* Add private field

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* Changing test to not use a complex constructor and double deserialization.

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

* Remove OBJECT_MAPPER.

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

Signed-off-by: addjuarez <addiajuarez@gmail.com>
Signed-off-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2022-09-08 17:34:11 -07:00
addjuarez 2cc9e536c8
Update sdk to use configuration dictionaries (#769)
* Update sdk to use configuration maps

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* add ref

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* add ref validate

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* go 1.19

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* fix it test

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* update comments

Signed-off-by: addjuarez <addiajuarez@gmail.com>

* use immutable maps

Signed-off-by: addjuarez <addiajuarez@gmail.com>

Signed-off-by: addjuarez <addiajuarez@gmail.com>
2022-09-05 19:28:34 -07:00
Pravin Pushkar 997c86d526
Added Headers passed through metadata (#770)
* Added Headers passed through metadata

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* trigger pr check

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>
2022-08-30 11:39:28 -07:00
Artur Souza 5b2d8f482d
Upgrade the version to 1.7.0-SNAPSHOT (#753)
Signed-off-by: Artur Souza <artursouza.ms@outlook.com>
2022-06-24 10:13:33 +05:30
Phil Kedy 2235e3d978
Adding pubsub routing support (#631)
* Adding pubsub routing support

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

* remove deprecated classes (#704)

* remove deprecated classes

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* remove builder class ref in ITs

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* fix setter in IT

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>
Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

* Address PR comments.

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

Co-authored-by: Mukundan Sundararajan <65565396+mukundansundar@users.noreply.github.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2022-06-23 11:40:10 -07:00
Artur Souza bb6db2ec6b
Upgrade the version to 1.6.0-SNAPSHOT (#727)
Signed-off-by: Artur Souza <artursouza.ms@outlook.com>
2022-03-31 22:11:32 -07:00
dependabot[bot] 6bdba2244b
Bump jackson-databind from 2.11.3 to 2.12.6.1 in /sdk (#718)
Bumps [jackson-databind](https://github.com/FasterXML/jackson) from 2.11.3 to 2.12.6.1.
- [Release notes](https://github.com/FasterXML/jackson/releases)
- [Commits](https://github.com/FasterXML/jackson/commits)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.core:jackson-databind
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-03-30 16:21:27 -07:00
Mukundan Sundararajan c7cc94d6d9
fix duration parsing (#714) 2022-03-23 22:20:18 -07:00
Mukundan Sundararajan 06d92dafca
Query State Preview API implementation. (#697)
* Query State Preview API implementation.

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* Use latest dapr ref and fix grpc query state api

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* fix service invocation automatic unesacpe

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* add more unit tests

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* Add query state API docs

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* Fix example to be user friendly

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* Fix example in docs

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* make pagination immutable

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2022-03-20 21:03:11 -07:00
Sky Ao e3fa24f67b
set maxRequestsPerHost of okhttp to support slow response requests and high TPS (#708)
* set maxRequestsPerHost of okjava to support slow response requests and high TPS

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* fix typo in comments

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update comments

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>

* update javadoc

Signed-off-by: Sky Ao <aoxiaojian@gmail.com>
2022-03-20 21:00:01 -07:00
Mukundan Sundararajan 0b881d3826
remove deprecated classes (#704)
* remove deprecated classes

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* remove builder class ref in ITs

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>

* fix setter in IT

Signed-off-by: Mukundan Sundararajan <msundar.ms@outlook.com>
2022-03-15 10:59:12 -07:00
Pravin Pushkar 9989832b56
Adding javadocs to some Domain classes (#673)
* Adding javadocs to some Domain classes

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Fixing code coverage

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Incorporating review comments

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>
2022-01-27 03:00:49 -08:00
Artur Souza 0c2fcb48a2
Update for next release: 1.5.0 snapshot (#672)
* Update CLI and runtime to 1.6.0-rc.x

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

* Upgrade the version to 1.5.0-SNAPSHOT

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>
2022-01-18 12:28:35 +05:30
Pravin Pushkar 185cdba293
Config api support (#670)
* inital draft for config api

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Introducing new client for preview apis and code refactoring

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Unit tests and code refactoring

Signed-off-by: Pravin Pushkar <ppushkar@microsoft.com>

* Adding integration test

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Copyright changes

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Review comments fixes

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Removed DaprPreviewClientProxy and updated example README

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Adding validate workflow for cofiguration api example

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* fixing example autovalidation and code coverage

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Fixing autovalidation and removing getAllConfiguration

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Fixing review comments

Signed-off-by: pravinpushkar <ppushkar@microsoft.com>

* Add regex header checkstyle.

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

* Fix headers and add javadocs to some.

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2022-01-12 16:01:13 -08:00
greenie-msft d37881b469
Update LICENSE to Apache 2.0 (#657)
* Update LICENSE to Apache 2.0

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

* Update headers to Apache 2.

Signed-off-by: Artur Souza <artursouza.ms@outlook.com>

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2021-12-09 20:15:47 +05:30
Maarten Mulders be7edb17f6
Migrated out of JCenter as a Maven repository manager (#648)
* Upgrade okhttp-mock dependency

Version 1.3.2 was never deployed to Maven Central

* No longer refer to JCenter, as it has been shut down
2021-10-29 14:51:10 -07:00
Artur Souza 8404b77d8c
Filter out headers not required for W3C in service invocation. (#642) 2021-10-11 17:22:38 -07:00
Artur Souza ed1fac1f89
Upgrade the version to 1.4.0-SNAPSHOT (#632) 2021-09-15 22:03:12 -07:00
Maarten Mulders 70e18d8b5a
Prepare build for Java16 (#598)
* Upgrade Mockito to latest version

* Run GitHub Actions on Java 11 and 16

* Run JUnit tests with `--add-opens java.base/java.util=ALL-UNNAMED`

* Move Surefire JVM arguments to Maven property

* Update build.yml

* Update validate.yml

* simplily build singleton dapr http (#590)

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>

* Add Automerge workflow (#605)

* Add Automerge workflow

The automerge workflow will check for complete and approved pull requests and will merge them automatically.

Sources:
- For the python script to execute the merge: https://raw.githubusercontent.com/dapr/dapr/master/.github/scripts/automerge.py (only changed the label from "automerge" to "auto-merge")
- https://raw.githubusercontent.com/dapr/dapr/master/.github/workflows/dapr-bot-schedule.yml (only copied the automerge part, not the prune_stale part as that was not part of the issue.

Resolves https://github.com/dapr/java-sdk/issues/603

* Update automerge-bot.yml

* Update automerge-bot.yml

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>

* Cleanup Maven POM files (#604)

Added fixed versions for maven-deploy-plugin & spring-boot-maven-plugin as this would otherwise break in a future maven version.

Also fixed some indenting and removed duplicate declarations.

Co-authored-by: Dapr Bot <56698301+dapr-bot@users.noreply.github.com>

* Add support for @PostMapping("/path") to pub/sub topic subscriptions (#583)

* Remove duplicate dependency

* Transform into managed dependencies

* Remove old JUnit version from dependencies

* Add tests for DaprBeanPostProcessor

* Also register PostMappings that use value

* Modify existing pub/sub test to no use @PostMapping(path="...")

* Remove added dependencies on AssertJ, Spring Test and Servlet API

* Remove test in favour of the sdk-tests one

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>

* Run JUnit tests in all modules with java.base/java.util and java.base/java.lang opened to all modules

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: 浩 <inf2inf2@outlook.com>
Co-authored-by: Tom Cools <tom.cools@live.be>
Co-authored-by: Dapr Bot <56698301+dapr-bot@users.noreply.github.com>
2021-08-30 15:32:32 -07:00
34bf149a1a
simplily build singleton dapr http (#590)
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2021-08-20 16:21:40 -07:00
Mukundan Sundararajan f199afba95
deprecate builders and add setters for domain classes (#596)
* deprecate builders and add setters for domain classes
exclude builders from coverage checks
properly set parallelism for getbulkstaterequest
Initialize default metadata to empty HashMap PublishEventRequest
Decrease code coeverage ratio for dapr-sdk

* Fix casing
2021-08-20 14:54:01 -07:00
Maarten Mulders ae5c2a1314
Declare CloudEvent generic to allow automatic payload deserialization using Jackson (#591)
* Declare CloudEvent generic

* Fix timestamp in logging

* Declare Spring Boot version once

* Simplify administration of received events

* Update docs

* Always return a list, even if it's empty

Rather than returning `null` when no
messages are present for a topic.
2021-08-13 13:52:37 -07:00
Kevin_T 50f80d8af5
chore: format some places to make the code more standardized (#578)
* chore: format some places to make the code more standardized

* test: add unit test for {@code DaprClient#getState} to cover {@code StateOptions#getStateOptionsAsMap}
2021-07-21 14:09:38 -07:00
Bernd Verst c3e60bb2ef
Update GRPC libraries for security updates (#573)
* Update pom.xml

* Update pom.xml

* Update pom.xml

* Define GRPC version as build property

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2021-07-14 16:39:24 -07:00
Bernd Verst 48b2d44aa7
Add support for configuring actor reminder storage partitions (#574)
* Update GRPC libraries for security updates

* AdConfigurable actor reminder storage patitions

* autoformat code

* Fix test and linter error

* more autoformatting

* competing style checker :(

Co-authored-by: Ubuntu <beverst@beverst-ubuntu.4gvshbv0hrpejbsei5kugsxnoc.xx.internal.cloudapp.net>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2021-07-12 16:02:25 -07:00
halspang 2eb6e1d9e3
Upgrade the version to 1.2.0-SNAPSHOT (#549) 2021-05-19 22:01:28 -07:00
Artur Souza 33f793c186
Return empty metadata for key not found + add IT test. (#528) 2021-05-14 11:37:09 -07:00
Artur Souza 7467575a97
Revert "Adjusted the configuration of Maven. (#532)" (#536)
This reverts commit 5cc79811cb.
2021-04-29 18:48:29 -07:00
LLLLimbo 5cc79811cb
Adjusted the configuration of Maven. (#532)
* Adjusted the configuration of Maven.

* Update pom.xml

* Remove os-maven-plugin and spring-boot-maven-plugin in parent pom

* Add version of spring-boot-maven-plugin in the example pom.
Add spring-boot-dependencies dependency management in sdk-springboot.
Add maven-compiler-plugin to the parent pom's pluginManagement
Remove protoc-jar-maven-plugin in  example's dependencies.

* Update pom.xml

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
Co-authored-by: Mukundan Sundararajan <musundar@microsoft.com>
2021-04-26 23:26:11 -07:00
halspang a654861def
Add shutdown API support (#530)
* Add shutdown API support

https://github.com/dapr/java-sdk/issues/529

* Utilize POST instead of GET for shutdown API
2021-04-07 11:42:00 -07:00
Artur Souza 788eea605c Fix HTTP save state transaction. 2021-03-17 00:14:46 -07:00
Artur Souza 45c81afa06
Upgrade the version to 1.1.0-SNAPSHOT (#494) 2021-02-16 18:14:23 -08:00
Artur Souza ce7ecb9965
Allows override of content-type in pubsub publish. (#492) 2021-02-16 00:03:08 -08:00
Artur Souza e46ef319cd
Support many query strings in HTTP and binary data in Cloud Event for PubSub. (#485)
* Handles base64 data from CloudEvent.

* Support for multiple query strings.

* Addressing comments.
2021-02-09 19:38:13 -08:00
Artur Souza 1b3077071f
Update license header. (#483) 2021-02-06 00:18:47 -08:00
xiazuojie 0cd2f373d2
remove io.dapr.client.domain.Response from DaprClient APIs (#476)
* change: remove io.dapr.client.domain.Response from getState API. This is just a showcase of how to use reactor.util.context.Context

* fix: code style

* change: remove io.dapr.client.domain.Response from invokeMethod API

* change: completely remove io.dapr.client.domain.Response and update all APIs
change: remove reactor.util.context.Context from "request" classes.

* removed getStateContext test case
update README.md

* removed default impl from DaprClient

Co-authored-by: Xia Zuojie <zuojie@alibaba-inc.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2021-02-05 23:20:25 -08:00
Artur Souza a66337aa4b
Unit test to deserialize CloudEvent. (#480) 2021-02-04 14:11:39 -08:00
Artur Souza 5d7700b570
Refactor params for State class + Unit test example (#473)
* Refactor order of params for State class.

* Example for unit testing.

* Change toString() for State class.

* Add unittesting example to main README.

* Fix cmd for unittesting example.

* Add sleep to http inputing binding example validation.

* Fix unittesting example check.
2021-02-01 19:03:25 -08:00
Artur Souza 277f9958a6
Fix PubSub publish + Update IT to use RC3 bits. (#471)
* Update IT to use RC3 bits.

* Fixing publish method not to handle content-type metadata in GRPC.

* Fix flaky actor ITs.
2021-02-01 18:19:50 -08:00
Artur Souza ba496064d1
Removing OpenTelemetry and OpenCensus SDK. (#463) 2021-01-29 09:23:48 -08:00
Artur Souza d7cc7974c7 handle method not found when proto class does not have parseFrom() 2021-01-27 23:39:13 -08:00
Artur Souza 7eacfcc88f Fix error handling in http invoke.
ITs to validate invoke errors on http and grpc services.
Handle serialization of proto objects.
2021-01-27 22:22:22 -08:00
karishma-chawla efee05681e
Updating state management example to include etag mismatch exception handling (#458)
* Updating state management example to include etag mismatch exception scenario. Dapr runtime grpc exception handling was recently updated to return aborted error code on etage mismatch for mutations, the example is updated to reflect that the runtime updates will be propagated through the java sdk.

* Addressed feedback to merge block call with api call.

* Updating readme with block() call updates, missed in previous commit
2021-01-26 17:14:51 -08:00
Charlie Stanley c35f0e11c6 Added unit tests for nullable etag #442 2021-01-25 13:52:21 -08:00
Artur Souza 907748f162 Adding GetBulkSecret API. 2021-01-25 12:21:46 -08:00
Artur Souza 57345ebf3e
Use DaprChannel instead of closeable ActorProxyBuilder. (#451)
* Use DaprChannel instead of closeable ActorProxyBuilder.

* Refactor Actor channel into DaprChannel and out of ActorProxyBuilder.

* Rename DaprChannel to ActorClient and make it a DaprClient.

* Make ActorClient not implement DaprClient but implement same method.

* Update sdk-actors/src/main/java/io/dapr/actors/client/ActorProxyBuilder.java

Co-authored-by: Mukundan Sundararajan <musundar@microsoft.com>

* Update sdk-actors/src/test/java/io/dapr/actors/client/ActorProxyBuilderTest.java

Co-authored-by: Mukundan Sundararajan <musundar@microsoft.com>

* Rename ActorProxyForTestsImpl to ActorProxyImplForTests

Co-authored-by: Mukundan Sundararajan <musundar@microsoft.com>
2021-01-25 12:04:58 -08:00
Artur Souza befed4a01b
Makes service method API invocations over HTTP by default. (#450)
* Makes service method API invocations over HTTP by default.

* Add logic to avoid building managedchannel in case of http API for actor runtime.
2021-01-23 12:12:34 -08:00
Phil Kedy 38b899d8b8
Add java.lang.reflect.Type to TypeRef per #331 (#449)
* Add support deserialization of generic types per #293

* Improving test coverage
2021-01-22 15:49:51 -08:00
Artur Souza 81b47f85b3
Makes http call async and allows timeout in Mono. (#445) 2021-01-21 15:23:24 -08:00
Artur Souza d43272fdc6
Rename InvokeServiceRequest to InvokeMethodRequest. (#443)
* Rename InvokeServiceRequest to InvokeMethodRequest.

* Organize imports.
2021-01-15 04:51:48 -08:00
Artur Souza 019dee9a8b
Fix handling of metadata, headers. Removes etag from getState. (#440)
* Fix handling of metadata, headers. Removes etag from getState().

* Update CLI and runtime.

* Fix ITs.
2021-01-14 15:01:22 -08:00
xiazuojie 76d877c9c0
Fix blocking calls for gRPC even though using Reactor (#435)
* Fix blocking calls for gRPC even though using Reactor

* delete unused wrap method

* add: throw exception if fatal

* Add "NoHotMono" unit tests for DaprClientGrpc

Co-authored-by: 刘禅 <zuojie@alibaba-inc.com>
Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2021-01-11 19:40:15 -08:00
Artur Souza 6a44d51279
Adds method to wait for Dapr sidecar. (#433) 2020-12-30 19:29:23 -08:00
Artur Souza 1a6675add8
Support TTL in PubSub. Fixes + refactor of CloudEvent. Fix handling content-type in PubSub over GRPC (#431) 2020-12-30 13:37:15 -08:00
Artur Souza 2714402a0e
Fix input encoding and error parsing for HTTP calls. (#428)
* Fix input encoding and error parsing for HTTP calls.

* Adds tests for special char in HTTP call.

* Rename path to pathSegments
2020-12-29 18:17:57 -08:00
Arghya Sadhu 4c1773c8cd
refactor to move duplicate code to method (#429)
Signed-off-by: Arghya Sadhu <arghya88@gmail.com>

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2020-12-29 14:20:31 -08:00
Sky/敖小剑 b5dd421142
add metadata in get bulk state request (#401)
* add metadata in get bulk state request

* rollback DaprClientGrpcTest which should be comitted in another PR

* fix compile error after merge

* update unit test for metadata in getBulkState()

* re-trigger build again

* add test for withMetadata()

Co-authored-by: Mukundan Sundararajan <musundar@microsoft.com>
2020-12-29 14:03:41 -08:00
Artur Souza 08f133dd1b
Throws IllegalArgumentException without wrapping as DaprException. (#426) 2020-12-21 16:21:01 -08:00
Arghya Sadhu a35e41480e
set etag to be null if it's empty (#414)
Signed-off-by: Arghya Sadhu <arghya88@gmail.com>
2020-12-18 12:13:46 -08:00
Arghya Sadhu 11d9e3b0b8
Rename methods and parameters for consistency across SDKs (#410)
Signed-off-by: Arghya Sadhu <arghya88@gmail.com>
2020-12-16 00:06:54 -08:00
Artur Souza de4c37e3a5
Upgrade the version to 1.0.0-SNAPSHOT (#413) 2020-12-15 23:34:20 -08:00
Artur Souza adce91f743
Throw DaprException consistently + doc + example. (#403) 2020-12-08 15:58:07 -08:00
Sky/敖小剑 16faa43795
support metadata in get state and bulk get state response (#402) 2020-12-03 11:25:32 -08:00
Sky/敖小剑 912ff7a781
Add metadata for state save operation (#397)
* add metadata for state save

* add test case for state hashcode() and equals()

* add metadata for state tansactional

Co-authored-by: Artur Souza <artursouza.ms@outlook.com>
2020-12-01 21:13:25 -08:00
Sky/敖小剑 8cc33b5598
fix a small copy-paste issue (#398) 2020-11-30 15:49:33 -08:00
Artur Souza cf1c10d85a
Actor over GRPC. (#395) 2020-11-24 15:23:35 -08:00