Class ConfigApiResource
- java.lang.Object
-
- io.jans.configapi.core.rest.BaseResource
-
- io.jans.configapi.rest.resource.auth.ConfigBaseResource
-
- io.jans.configapi.rest.resource.auth.ConfigApiResource
-
@Path("/api-config") @Produces("application/json") @Consumes("application/json") public class ConfigApiResource extends ConfigBaseResource
-
-
Constructor Summary
Constructors Constructor Description ConfigApiResource()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description jakarta.ws.rs.core.ResponsegetAppConfiguration()Retrieve the current config-api application configuration.jakarta.ws.rs.core.ResponsepatchAppConfigurationProperty(@NotNull String jsonPatchString)Apply a JSON Patch to the config-api dynamic configuration and return the updated application configuration.-
Methods inherited from class io.jans.configapi.rest.resource.auth.ConfigBaseResource
getMaxCount
-
Methods inherited from class io.jans.configapi.core.rest.BaseResource
checkNotEmpty, checkNotEmpty, checkNotNull, checkNotNull, checkNotNull, checkResourceNotNull, createSearchRequest, findRootError, getBadRequestException, getBadRequestException, getBadRequestException, getHttpHeaders, getHttpRequest, getInternalServerException, getInternalServerException, getMissingAttributeError, getNotAcceptableException, getNotFoundError, getNotFoundError, getUriInfo, throwBadRequestException, throwBadRequestException, throwBadRequestException, throwInternalServerException, throwInternalServerException, throwInternalServerException, throwInternalServerException, throwMissingAttributeError, throwNotFoundException, throwNotFoundException
-
-
-
-
Method Detail
-
getAppConfiguration
@GET public jakarta.ws.rs.core.Response getAppConfiguration()
Retrieve the current config-api application configuration.- Returns:
- the current ApiAppConfiguration
-
patchAppConfigurationProperty
@PATCH @Consumes("application/json-patch+json") public jakarta.ws.rs.core.Response patchAppConfigurationProperty(@NotNull @NotNull String jsonPatchString) throws com.github.fge.jsonpatch.JsonPatchException, IOExceptionApply a JSON Patch to the config-api dynamic configuration and return the updated application configuration.The provided JSON Patch document is applied to the stored dynamic configuration, the change is persisted, and the latest ApiAppConfiguration is returned.
- Parameters:
jsonPatchString- a JSON Patch document (RFC 6902) as a string describing the modifications to apply- Returns:
- the updated ApiAppConfiguration after the patch has been applied and persisted
- Throws:
com.github.fge.jsonpatch.JsonPatchException- if the JSON Patch cannot be applied to the current configurationIOException- if there is an I/O or JSON processing error while applying the patch
-
-