Interface DevResourceLifecycleManager<T extends ContainerConfig>
- All Superinterfaces:
QuarkusTestResourceLifecycleManager
public interface DevResourceLifecycleManager<T extends ContainerConfig>
extends QuarkusTestResourceLifecycleManager
Extends
QuarkusTestResourceLifecycleManager
so that classes implement both interfaces at the same time - simplifying testing.-
Nested Class Summary
Nested classes/interfaces inherited from interface io.quarkus.test.common.QuarkusTestResourceLifecycleManager
QuarkusTestResourceLifecycleManager.Context, QuarkusTestResourceLifecycleManager.TestInjector -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionDeduct current config from params.config(ModulesConfiguration configuration) Get resource's config from main observability configuration.Create container from config.container(T config, ModulesConfiguration root) Create container from config.default booleanenable()Should we enable / start this dev resource.default voidinitDev()Called even beforeQuarkusTestResourceLifecycleManager.start()so that the implementation can prepare itself to be used as dev resource (as opposed to test resource which uses a different init() method).Methods inherited from interface io.quarkus.test.common.QuarkusTestResourceLifecycleManager
init, inject, inject, order, setContext, start, stop
-
Field Details
-
METRICS
static final int METRICS- See Also:
-
SCRAPER
static final int SCRAPER- See Also:
-
GRAFANA
static final int GRAFANA- See Also:
-
JAEGER
static final int JAEGER- See Also:
-
OTEL
static final int OTEL- See Also:
-
-
Method Details
-
config
Get resource's config from main observability configuration.- Parameters:
configuration- main observability configuration- Returns:
- module's config
-
enable
default boolean enable()Should we enable / start this dev resource. e.g. we could already have actual service running Each impl should provide its own reason on why it disabled dev service.- Returns:
- true if ok to start new dev service, false otherwise
-
container
Create container from config.- Parameters:
config- the config- Returns:
- container id
-
container
Create container from config.- Parameters:
config- the configroot- the all modules config- Returns:
- container id
-
config
Deduct current config from params. If port are too dynamic / configured, it's hard to deduct, since configuration is not part of the devservice state. e.g. different ports then usual - Grafana UI is 3000, if you do not use 3000, it's hard or impossible to know which port belongs to certain property.- Returns:
- A map of system properties that should be set for the running dev-mode app
-
initDev
default void initDev()Called even beforeQuarkusTestResourceLifecycleManager.start()so that the implementation can prepare itself to be used as dev resource (as opposed to test resource which uses a different init() method).
-