public interface PolicyRuntimeFactory
This is an SPI and will be implemented by Policy provider"configuration" : { "services" : [ { .... { "type": "oracle.apiplatform.policies.sdk.runtime.PolicyRuntimeFactory", "service": "oracle.apiplatform.policies.apirequest.ApiRequestRuntimeFactory" } ]
Modifier and Type | Method and Description |
---|---|
PolicyRuntime |
getRuntime(PolicyRuntimeInitContext initContext, JSONObject policyConfig)
Will be called by the policy execution engine at initialization time in order to "create" an instance of a given policy
|
PolicyRuntime getRuntime(PolicyRuntimeInitContext initContext, JSONObject policyConfig) throws java.lang.Exception
initContext
- a context which can be used by policy implementation to access various runtime configuration settings, such as API Id or URLpolicyConfig
- the configuration of the policyjava.lang.Exception
- if an error occurs while instantiating the policy runtime object