public enum SandboxApp extends Enum<SandboxApp>
runnable(StarterContext)
is called in own thread). This way all services are launched in same JVM and we can easily manipulate
their state. Shared context (except system classes!) is not a problem, because it is shaded by Spring - each
application has its own class loader and context.
Each application will receive spring profile based on its lowercase name. I.e. LEDGERS_GATEWAY assumes to have
sandbox/application-test-ledgers-gateway.yml as well as common sandbox/application-test-common.yml
property files on resources path.
You can specify database type using System property / Environment variable (in order of precedence) `DB_TYPE`:
1. DB_TYPE = LOCAL_POSTGRES - will connect to local postgres db on port 5432
2. (DEFAULT) DB_TYPE = TEST_CONTAINERS_POSTGRES - will start Postgres using TestContainers and use port 15432 for it
(you need to prepare schema and users - see prepare-postgres.sql)
Startup order is roughly adherent to:
https://github.com/adorsys/XS2A-Sandbox/blob/master/docker-compose.ymlEnum Constant and Description |
---|
ASPSP_PROFILE |
CERT_GENERATOR |
CONSENT_MGMT |
LEDGERS_APP |
LEDGERS_GATEWAY |
ONLINE_BANKING |
ONLINE_BANKING_UI |
TPP_REST |
Modifier and Type | Field and Description |
---|---|
static String |
DB_TYPE |
static String |
SANDBOX_LOG_LEVEL |
static String |
TEST_CONTAINERS_POSTGRES |
Modifier and Type | Method and Description |
---|---|
static boolean |
allReadyToUse(StarterContext ctx) |
static long |
countReadyToUse(StarterContext ctx) |
Set<String> |
extraProfiles() |
boolean |
isReadyToUse(StarterContext ctx) |
Runnable |
runnable(StarterContext ctx) |
static SandboxApp |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static SandboxApp[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final SandboxApp ONLINE_BANKING_UI
public static final SandboxApp LEDGERS_APP
public static final SandboxApp LEDGERS_GATEWAY
public static final SandboxApp ASPSP_PROFILE
public static final SandboxApp CONSENT_MGMT
public static final SandboxApp ONLINE_BANKING
public static final SandboxApp TPP_REST
public static final SandboxApp CERT_GENERATOR
public static final String SANDBOX_LOG_LEVEL
public static final String DB_TYPE
public static final String TEST_CONTAINERS_POSTGRES
public static SandboxApp[] values()
for (SandboxApp c : SandboxApp.values()) System.out.println(c);
public static SandboxApp valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic Runnable runnable(StarterContext ctx)
public boolean isReadyToUse(StarterContext ctx)
public static boolean allReadyToUse(StarterContext ctx)
public static long countReadyToUse(StarterContext ctx)
Copyright © 2020. All rights reserved.