//
// Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license agreements.  See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership.  The ASF licenses this file
// to you under the Apache License, Version 2.0 (the
// "License"); you may not use this file except in compliance
// with the License.  You may obtain a copy of the License at
//
//   http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing,
// software distributed under the License is distributed on an
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
// KIND, either express or implied.  See the License for the
// specific language governing permissions and limitations
// under the License.
//
=== Actuator Endpoints

Spring Boot's actuator endpoints let you monitor and interact with Syncope components.

Each individual endpoint can be enabled / disabled and exposed over HTTP (pre-defined, under the `/actuator` subcontext)
or JMX.

Besides a number of https://docs.spring.io/spring-boot/3.4/reference/actuator/endpoints.html[built-in endpoints^],
more are made available for each component, as reported below.

[NOTE]
The pre-defined `health` and `info` endpoints are extended by each Syncope component, to add sensible data for the
given component.

[TIP]
The pre-defined `health` endpoint is typically used for liveness and readiness probes, even with Kubernetes.

[[actuator-core]]
==== Core

[cols="1,2"]
|===

| `entityCache`
a| Allows to work with https://openjpa.apache.org/builds/4.0.1/apache-openjpa/docs/ref_guide_caching.html#ref_guide_cache_statistics[JPA cache statistics^]

* `GET` - shows JPA cache statistics
* `POST {ENABLE,DISABLE,RESET}` - performs the requested operation onto JPA cache
* `DELETE` - clears JPA cache's current content
| `job`
a| Allows to work with the various jobs defined after <<tasks>> and <<reports>>.

* `GET` - shows the existing job data
* `POST {START,STOP,DELETE}` - performs the requested action on a given Job

|===

[[actuator-wa]]
==== WA

[cols="1,2"]
|===

| `ssoSessions`
| https://apereo.github.io/cas/7.2.x/authentication/Configuring-SSO.html#actuator-endpoints[More details^]
| `registeredServices`
| https://apereo.github.io/cas/7.2.x/services/Service-Management.html#actuator-endpoints[More details^]
| `authenticationHandlers`
| https://apereo.github.io/cas/7.2.x/authentication/Configuring-Authentication-Components.html#actuator-endpoints[More details^]
| `authenticationPolicies`
| https://apereo.github.io/cas/7.2.x/authentication/Configuring-Authentication-Policy.html#actuator-endpoints[More details^]
| `resolveAttributes`
| https://apereo.github.io/cas/7.2.x/integration/Attribute-Resolution.html#actuator-endpoints[More details^]

|===

[[actuator-sra]]
==== SRA

[cols="1,2"]
|===

| `sraSessions`
a| 
* `GET` - lists the current sessions
* `GET {id}` - reads the session with given `id`
* `DELETE {id}` - removes the session with given `id`

| `gateway`
| https://docs.spring.io/spring-cloud-gateway/reference/4.2/spring-cloud-gateway/actuator-api.html[More details^]

|===
