All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.dropwizard.health.conf.HealthCheckConfiguration Maven / Gradle / Ivy

Go to download

Provides a health check implementation that performs ongoing monitoring of an application's dependencies and includes an endpoint that can be called by a load balancer to determine if the application is healthy and thus able to retrieve traffic.

The newest version!
package io.dropwizard.health.conf;

import com.fasterxml.jackson.annotation.JsonProperty;

import javax.validation.Valid;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

public class HealthCheckConfiguration {

    @NotNull
    @Size(min = 1)
    @JsonProperty
    private String name;

    @NotNull
    @JsonProperty
    private HealthCheckType type = HealthCheckType.READY;

    @JsonProperty
    private boolean critical = false;

    @JsonProperty
    private boolean initialState = true;

    @Valid
    @NotNull
    @JsonProperty
    private Schedule schedule = new Schedule();

    public String getName() {
        return name;
    }

    public void setName(final String name) {
        this.name = name;
    }

    public HealthCheckType getType() {
        return type;
    }

    public void setType(HealthCheckType type) {
        this.type = type;
    }

    public boolean isCritical() {
        return critical;
    }

    public void setCritical(final boolean critical) {
        this.critical = critical;
    }

    public boolean isInitialState() {
        return initialState;
    }

    public void setInitialState(boolean initialState) {
        this.initialState = initialState;
    }

    public Schedule getSchedule() {
        return schedule;
    }

    public void setSchedule(final Schedule schedule) {
        this.schedule = schedule;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy