Skip to content

Commit

Permalink
Add prefix to the area Map storage options for Quarkus
Browse files Browse the repository at this point in the history
Closes #13355
  • Loading branch information
ahus1 authored and hmlnarik committed Jul 27, 2022
1 parent 340fafa commit 7f355b4
Show file tree
Hide file tree
Showing 7 changed files with 120 additions and 120 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,14 +64,14 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_EVENT_ADMIN_STORE = new OptionBuilder<>("storage-event-admin", StorageType.class)
public static final Option<StorageType> STORAGE_EVENT_ADMIN_STORE = new OptionBuilder<>("storage-area-event-admin", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("admin events"))
.expectedValues(StorageType.values())
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_EVENT_AUTH_STORE = new OptionBuilder<>("storage-event-auth", StorageType.class)
public static final Option<StorageType> STORAGE_EVENT_AUTH_STORE = new OptionBuilder<>("storage-area-event-auth", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("authentication and authorization events"))
.expectedValues(StorageType.values())
Expand All @@ -89,7 +89,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_REALM_STORE = new OptionBuilder<>("storage-realm", StorageType.class)
public static final Option<StorageType> STORAGE_REALM_STORE = new OptionBuilder<>("storage-area-realm", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("realms"))
.expectedValues(StorageType.values())
Expand All @@ -102,7 +102,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_CLIENT_STORE = new OptionBuilder<>("storage-client", StorageType.class)
public static final Option<StorageType> STORAGE_CLIENT_STORE = new OptionBuilder<>("storage-area-client", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("clients"))
.expectedValues(StorageType.values())
Expand All @@ -115,7 +115,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_CLIENT_SCOPE_STORE = new OptionBuilder<>("storage-client-scope", StorageType.class)
public static final Option<StorageType> STORAGE_CLIENT_SCOPE_STORE = new OptionBuilder<>("storage-area-client-scope", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("client scopes"))
.expectedValues(StorageType.values())
Expand All @@ -128,7 +128,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_GROUP_STORE = new OptionBuilder<>("storage-group", StorageType.class)
public static final Option<StorageType> STORAGE_GROUP_STORE = new OptionBuilder<>("storage-area-group", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("groups"))
.expectedValues(StorageType.values())
Expand All @@ -141,7 +141,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_ROLE_STORE = new OptionBuilder<>("storage-role", StorageType.class)
public static final Option<StorageType> STORAGE_ROLE_STORE = new OptionBuilder<>("storage-area-role", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("roles"))
.expectedValues(StorageType.values())
Expand All @@ -154,7 +154,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_USER_STORE = new OptionBuilder<>("storage-user", StorageType.class)
public static final Option<StorageType> STORAGE_USER_STORE = new OptionBuilder<>("storage-area-user", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("users"))
.expectedValues(StorageType.values())
Expand All @@ -173,7 +173,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_AUTH_SESSION_STORE = new OptionBuilder<>("storage-auth-session", StorageType.class)
public static final Option<StorageType> STORAGE_AUTH_SESSION_STORE = new OptionBuilder<>("storage-area-auth-session", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("authentication sessions"))
.expectedValues(StorageType.values())
Expand All @@ -186,7 +186,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_USER_SESSION_STORE = new OptionBuilder<>("storage-user-session", StorageType.class)
public static final Option<StorageType> STORAGE_USER_SESSION_STORE = new OptionBuilder<>("storage-area-user-session", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("user and client sessions"))
.expectedValues(StorageType.values())
Expand All @@ -199,7 +199,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_LOGIN_FAILURE_STORE = new OptionBuilder<>("storage-login-failure", StorageType.class)
public static final Option<StorageType> STORAGE_LOGIN_FAILURE_STORE = new OptionBuilder<>("storage-area-login-failure", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("login failures"))
.expectedValues(StorageType.values())
Expand All @@ -212,7 +212,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_AUTHORIZATION_STORE = new OptionBuilder<>("storage-authorization", StorageType.class)
public static final Option<StorageType> STORAGE_AUTHORIZATION_STORE = new OptionBuilder<>("storage-area-authorization", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("authorizations"))
.expectedValues(StorageType.values())
Expand All @@ -231,7 +231,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_ACTION_TOKEN_STORE = new OptionBuilder<>("storage-action-token", StorageType.class)
public static final Option<StorageType> STORAGE_ACTION_TOKEN_STORE = new OptionBuilder<>("storage-area-action-token", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("action tokens"))
.expectedValues(StorageType.values())
Expand Down Expand Up @@ -280,7 +280,7 @@ public String getProvider() {
.buildTime(true)
.build();

public static final Option<StorageType> STORAGE_SINGLE_USE_OBJECT_STORE = new OptionBuilder<>("storage-single-use-object", StorageType.class)
public static final Option<StorageType> STORAGE_SINGLE_USE_OBJECT_STORE = new OptionBuilder<>("storage-area-single-use-object", StorageType.class)
.category(OptionCategory.STORAGE)
.description(descriptionForStorageAreas("single use objects"))
.expectedValues(StorageType.values())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -488,7 +488,7 @@ public void testLogHandlerConfig() {

@Test
public void testStorageMixedStorageOptions() {
System.setProperty(CLI_ARGS, "--storage=jpa" + ARG_SEPARATOR + "--storage-realm=chm");
System.setProperty(CLI_ARGS, "--storage=jpa" + ARG_SEPARATOR + "--storage-area-realm=chm");
SmallRyeConfig config = createConfig();
assertEquals("jpa", config.getConfigValue("kc.storage").getValue());
assertNull(config.getConfigValue("kc.spi-map-storage-provider").getValue());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

@DistributionTest
@RawDistOnly(reason = "Containers are immutable")
@WithDatabase(alias = "postgres", buildOptions = {"storage=jpa", "storage-realm=chm"})
@WithDatabase(alias = "postgres", buildOptions = {"storage=jpa", "storage-area-realm=chm"})
public class MixedStoreDistTest {

@Test
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,30 +31,48 @@ Storage (Experimental):

--storage <type> Experimental: Sets the default storage mechanism for all areas. Possible
values are: jpa, chm, hotrod.
--storage-action-token <type>
--storage-area-action-token <type>
Experimental: Sets a storage mechanism for action tokens. Possible values are:
jpa, chm, hotrod.
--storage-auth-session <type>
--storage-area-auth-session <type>
Experimental: Sets a storage mechanism for authentication sessions. Possible
values are: jpa, chm, hotrod.
--storage-authorization <type>
--storage-area-authorization <type>
Experimental: Sets a storage mechanism for authorizations. Possible values
are: jpa, chm, hotrod.
--storage-client <type>
--storage-area-client <type>
Experimental: Sets a storage mechanism for clients. Possible values are: jpa,
chm, hotrod.
--storage-client-scope <type>
--storage-area-client-scope <type>
Experimental: Sets a storage mechanism for client scopes. Possible values are:
jpa, chm, hotrod.
--storage-event-admin <type>
--storage-area-event-admin <type>
Experimental: Sets a storage mechanism for admin events. Possible values are:
jpa, chm, hotrod.
--storage-event-auth <type>
--storage-area-event-auth <type>
Experimental: Sets a storage mechanism for authentication and authorization
events. Possible values are: jpa, chm, hotrod.
--storage-group <type>
--storage-area-group <type>
Experimental: Sets a storage mechanism for groups. Possible values are: jpa,
chm, hotrod.
--storage-area-login-failure <type>
Experimental: Sets a storage mechanism for login failures. Possible values
are: jpa, chm, hotrod.
--storage-area-realm <type>
Experimental: Sets a storage mechanism for realms. Possible values are: jpa,
chm, hotrod.
--storage-area-role <type>
Experimental: Sets a storage mechanism for roles. Possible values are: jpa,
chm, hotrod.
--storage-area-single-use-object <type>
Experimental: Sets a storage mechanism for single use objects. Possible values
are: jpa, chm, hotrod.
--storage-area-user <type>
Experimental: Sets a storage mechanism for users. Possible values are: jpa,
chm, hotrod.
--storage-area-user-session <type>
Experimental: Sets a storage mechanism for user and client sessions. Possible
values are: jpa, chm, hotrod.
--storage-hotrod-cache-configure <true|false>
Experimental: When set to true, Keycloak will create and configure Infinispan
caches on startup. Default: true.
Expand All @@ -69,24 +87,6 @@ Storage (Experimental):
Experimental: Sets the port of the Infinispan server.
--storage-hotrod-username <username>
Experimental: Sets the username of the Infinispan user.
--storage-login-failure <type>
Experimental: Sets a storage mechanism for login failures. Possible values
are: jpa, chm, hotrod.
--storage-realm <type>
Experimental: Sets a storage mechanism for realms. Possible values are: jpa,
chm, hotrod.
--storage-role <type>
Experimental: Sets a storage mechanism for roles. Possible values are: jpa,
chm, hotrod.
--storage-single-use-object <type>
Experimental: Sets a storage mechanism for single use objects. Possible values
are: jpa, chm, hotrod.
--storage-user <type>
Experimental: Sets a storage mechanism for users. Possible values are: jpa,
chm, hotrod.
--storage-user-session <type>
Experimental: Sets a storage mechanism for user and client sessions. Possible
values are: jpa, chm, hotrod.

Database:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,30 +31,48 @@ Storage (Experimental):

--storage <type> Experimental: Sets the default storage mechanism for all areas. Possible
values are: jpa, chm, hotrod.
--storage-action-token <type>
--storage-area-action-token <type>
Experimental: Sets a storage mechanism for action tokens. Possible values are:
jpa, chm, hotrod.
--storage-auth-session <type>
--storage-area-auth-session <type>
Experimental: Sets a storage mechanism for authentication sessions. Possible
values are: jpa, chm, hotrod.
--storage-authorization <type>
--storage-area-authorization <type>
Experimental: Sets a storage mechanism for authorizations. Possible values
are: jpa, chm, hotrod.
--storage-client <type>
--storage-area-client <type>
Experimental: Sets a storage mechanism for clients. Possible values are: jpa,
chm, hotrod.
--storage-client-scope <type>
--storage-area-client-scope <type>
Experimental: Sets a storage mechanism for client scopes. Possible values are:
jpa, chm, hotrod.
--storage-event-admin <type>
--storage-area-event-admin <type>
Experimental: Sets a storage mechanism for admin events. Possible values are:
jpa, chm, hotrod.
--storage-event-auth <type>
--storage-area-event-auth <type>
Experimental: Sets a storage mechanism for authentication and authorization
events. Possible values are: jpa, chm, hotrod.
--storage-group <type>
--storage-area-group <type>
Experimental: Sets a storage mechanism for groups. Possible values are: jpa,
chm, hotrod.
--storage-area-login-failure <type>
Experimental: Sets a storage mechanism for login failures. Possible values
are: jpa, chm, hotrod.
--storage-area-realm <type>
Experimental: Sets a storage mechanism for realms. Possible values are: jpa,
chm, hotrod.
--storage-area-role <type>
Experimental: Sets a storage mechanism for roles. Possible values are: jpa,
chm, hotrod.
--storage-area-single-use-object <type>
Experimental: Sets a storage mechanism for single use objects. Possible values
are: jpa, chm, hotrod.
--storage-area-user <type>
Experimental: Sets a storage mechanism for users. Possible values are: jpa,
chm, hotrod.
--storage-area-user-session <type>
Experimental: Sets a storage mechanism for user and client sessions. Possible
values are: jpa, chm, hotrod.
--storage-hotrod-cache-configure <true|false>
Experimental: When set to true, Keycloak will create and configure Infinispan
caches on startup. Default: true.
Expand All @@ -69,24 +87,6 @@ Storage (Experimental):
Experimental: Sets the port of the Infinispan server.
--storage-hotrod-username <username>
Experimental: Sets the username of the Infinispan user.
--storage-login-failure <type>
Experimental: Sets a storage mechanism for login failures. Possible values
are: jpa, chm, hotrod.
--storage-realm <type>
Experimental: Sets a storage mechanism for realms. Possible values are: jpa,
chm, hotrod.
--storage-role <type>
Experimental: Sets a storage mechanism for roles. Possible values are: jpa,
chm, hotrod.
--storage-single-use-object <type>
Experimental: Sets a storage mechanism for single use objects. Possible values
are: jpa, chm, hotrod.
--storage-user <type>
Experimental: Sets a storage mechanism for users. Possible values are: jpa,
chm, hotrod.
--storage-user-session <type>
Experimental: Sets a storage mechanism for user and client sessions. Possible
values are: jpa, chm, hotrod.

Database:

Expand Down

0 comments on commit 7f355b4

Please sign in to comment.