Class CamelMicroProfileHealthCheckRegistry

java.lang.Object
org.apache.camel.support.service.BaseService
org.apache.camel.support.service.ServiceSupport
org.apache.camel.impl.health.DefaultHealthCheckRegistry
org.apache.camel.microprofile.health.CamelMicroProfileHealthCheckRegistry
All Implemented Interfaces:
AutoCloseable, org.apache.camel.CamelContextAware, org.apache.camel.health.HealthCheckRegistry, org.apache.camel.Service, org.apache.camel.ShutdownableService, org.apache.camel.spi.HasCamelContext, org.apache.camel.spi.HasId, org.apache.camel.spi.IdAware, org.apache.camel.StartupListener, org.apache.camel.StatefulService, org.apache.camel.StaticService, org.apache.camel.SuspendableService

public class CamelMicroProfileHealthCheckRegistry extends org.apache.camel.impl.health.DefaultHealthCheckRegistry implements org.apache.camel.StartupListener
HealthCheckRegistry implementation to register Camel health checks as MicroProfile health checks on SmallRye Health.
  • Field Summary

    Fields inherited from class org.apache.camel.support.service.BaseService

    BUILT, FAILED, INITIALIZED, INITIALIZING, lock, NEW, SHUTDOWN, SHUTTING_DOWN, STARTED, STARTING, status, STOPPED, STOPPING, SUSPENDED, SUSPENDING

    Fields inherited from interface org.apache.camel.health.HealthCheckRegistry

    FACTORY, NAME
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    CamelMicroProfileHealthCheckRegistry(org.apache.camel.CamelContext camelContext)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected boolean
    canRegister(org.apache.camel.health.HealthCheckRepository repository)
     
    protected void
     
    protected io.smallrye.health.api.HealthRegistry
     
    protected io.smallrye.health.api.HealthRegistry
     
    void
    onCamelContextFullyStarted(org.apache.camel.CamelContext context, boolean alreadyStarted)
     
    void
    onCamelContextStarted(org.apache.camel.CamelContext context, boolean alreadyStarted)
     
    boolean
     
    protected boolean
    registerEagerly(org.apache.camel.health.HealthCheckRepository repository)
     
    protected void
    registerMicroProfileHealthCheck(org.apache.camel.health.HealthCheck camelHealthCheck)
     
    protected void
    registerRepositoryChecks(org.apache.camel.health.HealthCheckRepository repository)
     
    protected void
    removeMicroProfileHealthCheck(org.apache.camel.health.HealthCheck camelHealthCheck)
     
    boolean
     

    Methods inherited from class org.apache.camel.impl.health.DefaultHealthCheckRegistry

    doStart, doStop, getCamelContext, getExcludePattern, getExposureLevel, getId, getInitialState, getRepository, isEnabled, isExcluded, loadHealthChecks, resolveById, setCamelContext, setEnabled, setExcludePattern, setExposureLevel, setId, setInitialState, stream

    Methods inherited from class org.apache.camel.support.service.BaseService

    build, doBuild, doFail, doLifecycleChange, doResume, doShutdown, doSuspend, fail, getInternalLock, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspend

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.apache.camel.health.HealthCheckRegistry

    getCheck, getCheckIDs

    Methods inherited from interface org.apache.camel.spi.IdAware

    setGeneratedId

    Methods inherited from interface org.apache.camel.Service

    build, close, init, start, stop

    Methods inherited from interface org.apache.camel.ShutdownableService

    shutdown

    Methods inherited from interface org.apache.camel.StartupListener

    onCamelContextStarting

    Methods inherited from interface org.apache.camel.StatefulService

    getStatus, isRunAllowed, isStarted, isStarting, isStopped, isStopping, isSuspending

    Methods inherited from interface org.apache.camel.SuspendableService

    isSuspended, resume, suspend
  • Constructor Details

    • CamelMicroProfileHealthCheckRegistry

      public CamelMicroProfileHealthCheckRegistry()
    • CamelMicroProfileHealthCheckRegistry

      public CamelMicroProfileHealthCheckRegistry(org.apache.camel.CamelContext camelContext)
  • Method Details

    • doInit

      protected void doInit() throws Exception
      Overrides:
      doInit in class org.apache.camel.impl.health.DefaultHealthCheckRegistry
      Throws:
      Exception
    • register

      public boolean register(Object obj)
      Specified by:
      register in interface org.apache.camel.health.HealthCheckRegistry
      Overrides:
      register in class org.apache.camel.impl.health.DefaultHealthCheckRegistry
    • unregister

      public boolean unregister(Object obj)
      Specified by:
      unregister in interface org.apache.camel.health.HealthCheckRegistry
      Overrides:
      unregister in class org.apache.camel.impl.health.DefaultHealthCheckRegistry
    • onCamelContextStarted

      public void onCamelContextStarted(org.apache.camel.CamelContext context, boolean alreadyStarted) throws Exception
      Specified by:
      onCamelContextStarted in interface org.apache.camel.StartupListener
      Throws:
      Exception
    • onCamelContextFullyStarted

      public void onCamelContextFullyStarted(org.apache.camel.CamelContext context, boolean alreadyStarted) throws Exception
      Specified by:
      onCamelContextFullyStarted in interface org.apache.camel.StartupListener
      Throws:
      Exception
    • registerRepositoryChecks

      protected void registerRepositoryChecks(org.apache.camel.health.HealthCheckRepository repository)
    • registerMicroProfileHealthCheck

      protected void registerMicroProfileHealthCheck(org.apache.camel.health.HealthCheck camelHealthCheck)
    • removeMicroProfileHealthCheck

      protected void removeMicroProfileHealthCheck(org.apache.camel.health.HealthCheck camelHealthCheck)
    • canRegister

      protected boolean canRegister(org.apache.camel.health.HealthCheckRepository repository)
    • registerEagerly

      protected boolean registerEagerly(org.apache.camel.health.HealthCheckRepository repository)
    • getLivenessRegistry

      protected io.smallrye.health.api.HealthRegistry getLivenessRegistry()
    • getReadinessRegistry

      protected io.smallrye.health.api.HealthRegistry getReadinessRegistry()