Package dev.restate.sdk.testing
Class RestateRunnerBuilder
java.lang.Object
dev.restate.sdk.testing.RestateRunnerBuilder
Builder for
RestateRunner
.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbind
(ServiceDefinition<?> serviceDefinition) Add a Restate service to the endpoint.bind
(ServiceDefinition<O> serviceDefinition, O options) Add a Restate service to the endpoint, setting the options.Add a Restate service to the endpoint.Deprecated.static RestateRunnerBuilder
create()
static RestateRunnerBuilder
of
(RestateHttpEndpointBuilder endpointBuilder) Create fromRestateHttpEndpointBuilder
.withAdditionalEnv
(String key, String value) Add additional environment variables to the Restate container.withConfigFile
(String configFile) Mount a config file in the Restate container.withRestateContainerImage
(String restateContainerImage) Override the container image to use for the Restate runtime.
-
Method Details
-
withRestateContainerImage
Override the container image to use for the Restate runtime. -
withAdditionalEnv
Add additional environment variables to the Restate container. -
withConfigFile
Mount a config file in the Restate container. -
bind
Add a Restate service to the endpoint. This will automatically discover the generated factory based on the class name.You can also manually instantiate the
ServiceDefinition
usingbind(ServiceDefinition)
. -
bind
Add a Restate service to the endpoint.To set the options, use
bind(ServiceDefinition, Object)
. -
bind
Add a Restate service to the endpoint, setting the options. -
buildManualRunner
- Returns:
- a
ManualRestateRunner
to start and stop the test infra manually.
-
buildRunner
Deprecated.If you use JUnit 5, useRestateTest
- Returns:
- a
RestateRunner
to be used as JUnit 5 Extension.
-
create
-
of
Create fromRestateHttpEndpointBuilder
.
-
RestateTest