Commit e674d751 authored by Phillip Webb's avatar Phillip Webb

Polish Javadoc

parent e07df7e4
...@@ -61,7 +61,7 @@ public class AuditEvent implements Serializable { ...@@ -61,7 +61,7 @@ public class AuditEvent implements Serializable {
/** /**
* Create a new audit event for the current time from data provided as name-value * Create a new audit event for the current time from data provided as name-value
* pairs * pairs.
* @param principal The user principal responsible * @param principal The user principal responsible
* @param type the event type * @param type the event type
* @param data The event data in the form 'key=value' or simply 'key' * @param data The event data in the form 'key=value' or simply 'key'
......
...@@ -46,7 +46,8 @@ public class InMemoryAuditEventRepository implements AuditEventRepository { ...@@ -46,7 +46,8 @@ public class InMemoryAuditEventRepository implements AuditEventRepository {
} }
/** /**
* @param capacity the capacity to set * Set the capacity of this event repository.
* @param capacity the capacity
*/ */
public synchronized void setCapacity(int capacity) { public synchronized void setCapacity(int capacity) {
this.events = new AuditEvent[capacity]; this.events = new AuditEvent[capacity];
......
...@@ -82,6 +82,7 @@ public class AuditApplicationEvent extends ApplicationEvent { ...@@ -82,6 +82,7 @@ public class AuditApplicationEvent extends ApplicationEvent {
} }
/** /**
* Get the audit event.
* @return the audit event * @return the audit event
*/ */
public AuditEvent getAuditEvent() { public AuditEvent getAuditEvent() {
......
...@@ -21,7 +21,7 @@ import java.util.List; ...@@ -21,7 +21,7 @@ import java.util.List;
import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.boot.context.properties.ConfigurationProperties;
/** /**
* Configuration properties for some health properties * Configuration properties for some health properties.
* *
* @author Christian Dupuis * @author Christian Dupuis
* @since 1.2.0 * @since 1.2.0
......
...@@ -52,7 +52,7 @@ public class ManagementContextResolver { ...@@ -52,7 +52,7 @@ public class ManagementContextResolver {
} }
/** /**
* Return the management {@link ApplicationContext} * Return the management {@link ApplicationContext}.
* @return the management {@link ApplicationContext} * @return the management {@link ApplicationContext}
*/ */
public ApplicationContext getApplicationContext() { public ApplicationContext getApplicationContext() {
......
...@@ -185,7 +185,7 @@ public class ManagementWebSecurityAutoConfiguration { ...@@ -185,7 +185,7 @@ public class ManagementWebSecurityAutoConfiguration {
} }
/** /**
* WebSecurityEnabler condition * WebSecurityEnabler condition.
*/ */
static class WebSecurityEnablerCondition extends SpringBootCondition { static class WebSecurityEnablerCondition extends SpringBootCondition {
......
...@@ -221,7 +221,7 @@ public class ShellProperties { ...@@ -221,7 +221,7 @@ public class ShellProperties {
} }
/** /**
* SSH properties * SSH properties.
*/ */
public static class Ssh extends CrshShellProperties { public static class Ssh extends CrshShellProperties {
...@@ -279,7 +279,7 @@ public class ShellProperties { ...@@ -279,7 +279,7 @@ public class ShellProperties {
} }
/** /**
* Telnet properties * Telnet properties.
*/ */
public static class Telnet extends CrshShellProperties { public static class Telnet extends CrshShellProperties {
...@@ -322,7 +322,7 @@ public class ShellProperties { ...@@ -322,7 +322,7 @@ public class ShellProperties {
} }
/** /**
* Auth specific properties for JAAS authentication * Auth specific properties for JAAS authentication.
*/ */
@ConfigurationProperties(prefix = "shell.auth.jaas", ignoreUnknownFields = false) @ConfigurationProperties(prefix = "shell.auth.jaas", ignoreUnknownFields = false)
public static class JaasAuthenticationProperties extends public static class JaasAuthenticationProperties extends
...@@ -351,7 +351,7 @@ public class ShellProperties { ...@@ -351,7 +351,7 @@ public class ShellProperties {
} }
/** /**
* Auth specific properties for key authentication * Auth specific properties for key authentication.
*/ */
@ConfigurationProperties(prefix = "shell.auth.key", ignoreUnknownFields = false) @ConfigurationProperties(prefix = "shell.auth.key", ignoreUnknownFields = false)
public static class KeyAuthenticationProperties extends public static class KeyAuthenticationProperties extends
...@@ -382,7 +382,7 @@ public class ShellProperties { ...@@ -382,7 +382,7 @@ public class ShellProperties {
} }
/** /**
* Auth specific properties for simple authentication * Auth specific properties for simple authentication.
*/ */
@ConfigurationProperties(prefix = "shell.auth.simple", ignoreUnknownFields = false) @ConfigurationProperties(prefix = "shell.auth.simple", ignoreUnknownFields = false)
public static class SimpleAuthenticationProperties extends public static class SimpleAuthenticationProperties extends
...@@ -457,7 +457,7 @@ public class ShellProperties { ...@@ -457,7 +457,7 @@ public class ShellProperties {
} }
/** /**
* Auth specific properties for Spring authentication * Auth specific properties for Spring authentication.
*/ */
@ConfigurationProperties(prefix = "shell.auth.spring", ignoreUnknownFields = false) @ConfigurationProperties(prefix = "shell.auth.spring", ignoreUnknownFields = false)
public static class SpringAuthenticationProperties extends public static class SpringAuthenticationProperties extends
......
...@@ -37,9 +37,9 @@ import org.springframework.cache.CacheManager; ...@@ -37,9 +37,9 @@ import org.springframework.cache.CacheManager;
* Base {@link CacheStatisticsProvider} implementation that uses JMX to retrieve the cache * Base {@link CacheStatisticsProvider} implementation that uses JMX to retrieve the cache
* statistics. * statistics.
* *
* @param <C> The cache type
* @author Stephane Nicoll * @author Stephane Nicoll
* @since 1.3.0 * @since 1.3.0
* @param <C> The cache type
*/ */
public abstract class AbstractJmxCacheStatisticsProvider<C extends Cache> implements public abstract class AbstractJmxCacheStatisticsProvider<C extends Cache> implements
CacheStatisticsProvider<C> { CacheStatisticsProvider<C> {
......
...@@ -144,6 +144,10 @@ public class ConfigurationPropertiesReportEndpoint extends ...@@ -144,6 +144,10 @@ public class ConfigurationPropertiesReportEndpoint extends
/** /**
* Cautiously serialize the bean to a map (returning a map with an error message * Cautiously serialize the bean to a map (returning a map with an error message
* instead of throwing an exception if there is a problem). * instead of throwing an exception if there is a problem).
* @param mapper the object mapper
* @param bean the source bean
* @param prefix the prefix
* @return the serialized instance
*/ */
private Map<String, Object> safeSerialize(ObjectMapper mapper, Object bean, private Map<String, Object> safeSerialize(ObjectMapper mapper, Object bean,
String prefix) { String prefix) {
...@@ -173,6 +177,7 @@ public class ConfigurationPropertiesReportEndpoint extends ...@@ -173,6 +177,7 @@ public class ConfigurationPropertiesReportEndpoint extends
/** /**
* Ensure only bindable and non-cyclic bean properties are reported. * Ensure only bindable and non-cyclic bean properties are reported.
* @param mapper the object mapper
*/ */
private void applySerializationModifier(ObjectMapper mapper) { private void applySerializationModifier(ObjectMapper mapper) {
SerializerFactory factory = BeanSerializerFactory.instance SerializerFactory factory = BeanSerializerFactory.instance
...@@ -183,6 +188,7 @@ public class ConfigurationPropertiesReportEndpoint extends ...@@ -183,6 +188,7 @@ public class ConfigurationPropertiesReportEndpoint extends
/** /**
* Configure PropertyFilter to make sure Jackson doesn't process CGLIB generated bean * Configure PropertyFilter to make sure Jackson doesn't process CGLIB generated bean
* properties. * properties.
* @param mapper the object mapper
*/ */
private void applyCglibFilters(ObjectMapper mapper) { private void applyCglibFilters(ObjectMapper mapper) {
mapper.setAnnotationIntrospector(new CglibAnnotationIntrospector()); mapper.setAnnotationIntrospector(new CglibAnnotationIntrospector());
...@@ -192,7 +198,11 @@ public class ConfigurationPropertiesReportEndpoint extends ...@@ -192,7 +198,11 @@ public class ConfigurationPropertiesReportEndpoint extends
/** /**
* Extract configuration prefix from {@link ConfigurationProperties} annotation. * Extract configuration prefix from {@link ConfigurationProperties} annotation.
* @param beanFactoryMetaData * @param context the application context
* @param beanFactoryMetaData the bean factory meta-data
* @param beanName the bean name
* @param bean the bean
* @return the prefix
*/ */
private String extractPrefix(ApplicationContext context, private String extractPrefix(ApplicationContext context,
ConfigurationBeanFactoryMetaData beanFactoryMetaData, String beanName, ConfigurationBeanFactoryMetaData beanFactoryMetaData, String beanName,
...@@ -216,6 +226,8 @@ public class ConfigurationPropertiesReportEndpoint extends ...@@ -216,6 +226,8 @@ public class ConfigurationPropertiesReportEndpoint extends
/** /**
* Sanitize all unwanted configuration properties to avoid leaking of sensitive * Sanitize all unwanted configuration properties to avoid leaking of sensitive
* information. * information.
* @param map the source map
* @return the sanitized map
*/ */
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
private Map<String, Object> sanitize(Map<String, Object> map) { private Map<String, Object> sanitize(Map<String, Object> map) {
......
...@@ -113,6 +113,7 @@ public class DataSourcePublicMetrics implements PublicMetrics { ...@@ -113,6 +113,7 @@ public class DataSourcePublicMetrics implements PublicMetrics {
* Attempt to locate the primary {@link DataSource} (i.e. either the only data source * Attempt to locate the primary {@link DataSource} (i.e. either the only data source
* available or the one amongst the candidates marked as {@link Primary}. Return * available or the one amongst the candidates marked as {@link Primary}. Return
* {@code null} if there no primary data source could be found. * {@code null} if there no primary data source could be found.
* @return the primary datasource
*/ */
private DataSource getPrimaryDataSource() { private DataSource getPrimaryDataSource() {
try { try {
......
...@@ -55,6 +55,9 @@ public class FlywayEndpoint extends AbstractEndpoint<List<FlywayMigration>> { ...@@ -55,6 +55,9 @@ public class FlywayEndpoint extends AbstractEndpoint<List<FlywayMigration>> {
return migrations; return migrations;
} }
/**
* Migration properties.
*/
public static class FlywayMigration { public static class FlywayMigration {
private MigrationType type; private MigrationType type;
......
...@@ -83,6 +83,8 @@ public class HealthEndpoint extends AbstractEndpoint<Health> { ...@@ -83,6 +83,8 @@ public class HealthEndpoint extends AbstractEndpoint<Health> {
/** /**
* Turns the bean name into a key that can be used in the map of health information. * Turns the bean name into a key that can be used in the map of health information.
* @param name the bean name
* @return the key
*/ */
private String getKey(String name) { private String getKey(String name) {
int index = name.toLowerCase().indexOf("healthindicator"); int index = name.toLowerCase().indexOf("healthindicator");
......
...@@ -29,7 +29,8 @@ import org.springframework.boot.actuate.metrics.Metric; ...@@ -29,7 +29,8 @@ import org.springframework.boot.actuate.metrics.Metric;
public interface PublicMetrics { public interface PublicMetrics {
/** /**
* @return an indication of current state through metrics * Return an indication of current state through metrics.
* @return the public metrics
*/ */
Collection<Metric<?>> metrics(); Collection<Metric<?>> metrics();
......
...@@ -58,14 +58,16 @@ public class RequestMappingEndpoint extends AbstractEndpoint<Map<String, Object> ...@@ -58,14 +58,16 @@ public class RequestMappingEndpoint extends AbstractEndpoint<Map<String, Object>
} }
/** /**
* @param handlerMappings the mappings to set * Set the handler mappings.
* @param handlerMappings the handler mappings
*/ */
public void setHandlerMappings(List<AbstractUrlHandlerMapping> handlerMappings) { public void setHandlerMappings(List<AbstractUrlHandlerMapping> handlerMappings) {
this.handlerMappings = handlerMappings; this.handlerMappings = handlerMappings;
} }
/** /**
* @param methodMappings the method mappings to set * Set the method mappings.
* @param methodMappings the method mappings
*/ */
public void setMethodMappings(List<AbstractHandlerMethodMapping<?>> methodMappings) { public void setMethodMappings(List<AbstractHandlerMethodMapping<?>> methodMappings) {
this.methodMappings = methodMappings; this.methodMappings = methodMappings;
......
...@@ -76,6 +76,7 @@ public class SystemPublicMetrics implements PublicMetrics, Ordered { ...@@ -76,6 +76,7 @@ public class SystemPublicMetrics implements PublicMetrics, Ordered {
/** /**
* Add metrics from ManagementFactory if possible. Note that ManagementFactory is not * Add metrics from ManagementFactory if possible. Note that ManagementFactory is not
* available on Google App Engine. * available on Google App Engine.
* @param result the result
*/ */
private void addManagementMetrics(Collection<Metric<?>> result) { private void addManagementMetrics(Collection<Metric<?>> result) {
try { try {
...@@ -153,6 +154,8 @@ public class SystemPublicMetrics implements PublicMetrics, Ordered { ...@@ -153,6 +154,8 @@ public class SystemPublicMetrics implements PublicMetrics, Ordered {
/** /**
* Turn GC names like 'PS Scavenge' or 'PS MarkSweep' into something that is more * Turn GC names like 'PS Scavenge' or 'PS MarkSweep' into something that is more
* metrics friendly. * metrics friendly.
* @param name the source name
* @return a metric friendly name
*/ */
private String beautifyGcName(String name) { private String beautifyGcName(String name) {
return StringUtils.replace(name, " ", "_").toLowerCase(); return StringUtils.replace(name, " ", "_").toLowerCase();
......
...@@ -61,6 +61,9 @@ import com.fasterxml.jackson.databind.ObjectMapper; ...@@ -61,6 +61,9 @@ import com.fasterxml.jackson.databind.ObjectMapper;
public class EndpointMBeanExporter extends MBeanExporter implements SmartLifecycle, public class EndpointMBeanExporter extends MBeanExporter implements SmartLifecycle,
ApplicationContextAware { ApplicationContextAware {
/**
* The default JMX domain.
*/
public static final String DEFAULT_DOMAIN = "org.springframework.boot"; public static final String DEFAULT_DOMAIN = "org.springframework.boot";
private static Log logger = LogFactory.getLog(EndpointMBeanExporter.class); private static Log logger = LogFactory.getLog(EndpointMBeanExporter.class);
......
...@@ -32,6 +32,14 @@ import org.springframework.web.servlet.resource.ResourceTransformer; ...@@ -32,6 +32,14 @@ import org.springframework.web.servlet.resource.ResourceTransformer;
import org.springframework.web.servlet.resource.ResourceTransformerChain; import org.springframework.web.servlet.resource.ResourceTransformerChain;
import org.springframework.web.servlet.resource.TransformedResource; import org.springframework.web.servlet.resource.TransformedResource;
/**
* {@link MvcEndpoint} to expose a HAL browser.
*
* @author Dave Syer
* @author Phillip Webb
* @author Andy Wilkinson
* @since 1.3.0
*/
public class ActuatorHalBrowserEndpoint extends ActuatorHalJsonEndpoint implements public class ActuatorHalBrowserEndpoint extends ActuatorHalJsonEndpoint implements
ResourceLoaderAware { ResourceLoaderAware {
...@@ -93,6 +101,9 @@ public class ActuatorHalBrowserEndpoint extends ActuatorHalJsonEndpoint implemen ...@@ -93,6 +101,9 @@ public class ActuatorHalBrowserEndpoint extends ActuatorHalJsonEndpoint implemen
return null; return null;
} }
/**
* HAL Browser properties.
*/
public static class HalBrowserLocation { public static class HalBrowserLocation {
private final String resourceLocation; private final String resourceLocation;
......
...@@ -29,12 +29,12 @@ import org.springframework.web.bind.annotation.ResponseBody; ...@@ -29,12 +29,12 @@ import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter; import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;
/** /**
* {@link MvcEndpoint} for the actuator. Uses content negotiation to provide access to the * {@link MvcEndpoint} to expose HAL-formatted JSON.
* HAL browser (when on the classpath), and to HAL-formatted JSON.
* *
* @author Dave Syer * @author Dave Syer
* @author Phil Webb * @author Phillip Webb
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.3.0
*/ */
@ConfigurationProperties("endpoints.actuator") @ConfigurationProperties("endpoints.actuator")
public class ActuatorHalJsonEndpoint extends WebMvcConfigurerAdapter implements public class ActuatorHalJsonEndpoint extends WebMvcConfigurerAdapter implements
......
...@@ -97,7 +97,7 @@ public class EndpointHandlerMapping extends RequestMappingHandlerMapping { ...@@ -97,7 +97,7 @@ public class EndpointHandlerMapping extends RequestMappingHandlerMapping {
/** /**
* Since all handler beans are passed into the constructor there is no need to detect * Since all handler beans are passed into the constructor there is no need to detect
* anything here * anything here.
*/ */
@Override @Override
protected boolean isHandler(Class<?> beanType) { protected boolean isHandler(Class<?> beanType) {
...@@ -149,7 +149,8 @@ public class EndpointHandlerMapping extends RequestMappingHandlerMapping { ...@@ -149,7 +149,8 @@ public class EndpointHandlerMapping extends RequestMappingHandlerMapping {
} }
/** /**
* @param prefix the prefix to set * Set the prefix used in mappings.
* @param prefix the prefix
*/ */
public void setPrefix(String prefix) { public void setPrefix(String prefix) {
Assert.isTrue("".equals(prefix) || StringUtils.startsWithIgnoreCase(prefix, "/"), Assert.isTrue("".equals(prefix) || StringUtils.startsWithIgnoreCase(prefix, "/"),
...@@ -158,13 +159,15 @@ public class EndpointHandlerMapping extends RequestMappingHandlerMapping { ...@@ -158,13 +159,15 @@ public class EndpointHandlerMapping extends RequestMappingHandlerMapping {
} }
/** /**
* @return the prefix used in mappings * Get the prefix used in mappings.
* @return the prefix
*/ */
public String getPrefix() { public String getPrefix() {
return this.prefix; return this.prefix;
} }
/** /**
* Get the path of the endpoint.
* @param endpoint the endpoint * @param endpoint the endpoint
* @return the path used in mappings * @return the path used in mappings
*/ */
...@@ -189,7 +192,7 @@ public class EndpointHandlerMapping extends RequestMappingHandlerMapping { ...@@ -189,7 +192,7 @@ public class EndpointHandlerMapping extends RequestMappingHandlerMapping {
} }
/** /**
* Return the endpoints * Return the endpoints.
* @return the endpoints * @return the endpoints
*/ */
public Set<? extends MvcEndpoint> getEndpoints() { public Set<? extends MvcEndpoint> getEndpoints() {
......
...@@ -25,7 +25,7 @@ package org.springframework.boot.actuate.endpoint.mvc; ...@@ -25,7 +25,7 @@ package org.springframework.boot.actuate.endpoint.mvc;
public interface EndpointHandlerMappingCustomizer { public interface EndpointHandlerMappingCustomizer {
/** /**
* Customize the specified {@link EndpointHandlerMapping} * Customize the specified {@link EndpointHandlerMapping}.
* @param mapping the {@link EndpointHandlerMapping} to customize * @param mapping the {@link EndpointHandlerMapping} to customize
*/ */
void customize(EndpointHandlerMapping mapping); void customize(EndpointHandlerMapping mapping);
......
...@@ -74,10 +74,9 @@ public class EndpointMvcAdapter implements MvcEndpoint { ...@@ -74,10 +74,9 @@ public class EndpointMvcAdapter implements MvcEndpoint {
/** /**
* Returns the response that should be returned when the endpoint is disabled. * Returns the response that should be returned when the endpoint is disabled.
*
* @see Endpoint#isEnabled()
* @since 1.2.4
* @return The response to be returned when the endpoint is disabled * @return The response to be returned when the endpoint is disabled
* @since 1.2.4
* @see Endpoint#isEnabled()
*/ */
protected ResponseEntity<?> getDisabledResponse() { protected ResponseEntity<?> getDisabledResponse() {
return MvcEndpoint.DISABLED_RESPONSE; return MvcEndpoint.DISABLED_RESPONSE;
......
...@@ -34,6 +34,9 @@ import org.springframework.http.ResponseEntity; ...@@ -34,6 +34,9 @@ import org.springframework.http.ResponseEntity;
*/ */
public interface MvcEndpoint { public interface MvcEndpoint {
/**
* A {@link ResponseEntity} returned for disabled endpoints.
*/
ResponseEntity<Map<String, String>> DISABLED_RESPONSE = new ResponseEntity<Map<String, String>>( ResponseEntity<Map<String, String>> DISABLED_RESPONSE = new ResponseEntity<Map<String, String>>(
Collections.singletonMap("message", "This endpoint is disabled"), Collections.singletonMap("message", "This endpoint is disabled"),
HttpStatus.NOT_FOUND); HttpStatus.NOT_FOUND);
......
...@@ -26,9 +26,9 @@ import java.util.regex.Pattern; ...@@ -26,9 +26,9 @@ import java.util.regex.Pattern;
* must provide implementations of {@link #getValue(Object, String)} and * must provide implementations of {@link #getValue(Object, String)} and
* {@link #getNames(Object, NameCallback)}. * {@link #getNames(Object, NameCallback)}.
* *
* @param <T> The source data type
* @author Phillip Webb * @author Phillip Webb
* @author Sergei Egorov * @author Sergei Egorov
* @param <T> The source data type
* @since 1.3.0 * @since 1.3.0
*/ */
abstract class NamePatternFilter<T> { abstract class NamePatternFilter<T> {
...@@ -66,12 +66,18 @@ abstract class NamePatternFilter<T> { ...@@ -66,12 +66,18 @@ abstract class NamePatternFilter<T> {
protected abstract Object getValue(T source, String name); protected abstract Object getValue(T source, String name);
/**
* Callback used to add a name.
*/
protected interface NameCallback { protected interface NameCallback {
void addName(String name); void addName(String name);
} }
/**
* {@link NameCallback} implementation to collect results.
*/
private class ResultCollectingNameCallback implements NameCallback { private class ResultCollectingNameCallback implements NameCallback {
private final Pattern pattern; private final Pattern pattern;
......
...@@ -185,6 +185,9 @@ public class DataSourceHealthIndicator extends AbstractHealthIndicator implement ...@@ -185,6 +185,9 @@ public class DataSourceHealthIndicator extends AbstractHealthIndicator implement
} }
/**
* Known database products.
*/
protected enum Product { protected enum Product {
HSQLDB("HSQL Database Engine", HSQLDB("HSQL Database Engine",
......
...@@ -37,7 +37,7 @@ public class DiskSpaceHealthIndicator extends AbstractHealthIndicator { ...@@ -37,7 +37,7 @@ public class DiskSpaceHealthIndicator extends AbstractHealthIndicator {
private final DiskSpaceHealthIndicatorProperties properties; private final DiskSpaceHealthIndicatorProperties properties;
/** /**
* Create a new {@code DiskSpaceHealthIndicator} * Create a new {@code DiskSpaceHealthIndicator}.
* @param properties the disk space properties * @param properties the disk space properties
*/ */
@Autowired @Autowired
......
...@@ -22,7 +22,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties; ...@@ -22,7 +22,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.util.Assert; import org.springframework.util.Assert;
/** /**
* External configuration properties for {@link DiskSpaceHealthIndicator} * External configuration properties for {@link DiskSpaceHealthIndicator}.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.2.0 * @since 1.2.0
......
...@@ -22,7 +22,7 @@ import java.util.List; ...@@ -22,7 +22,7 @@ import java.util.List;
import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.boot.context.properties.ConfigurationProperties;
/** /**
* External configuration properties for {@link ElasticsearchHealthIndicator} * External configuration properties for {@link ElasticsearchHealthIndicator}.
* *
* @author Binwei Yang * @author Binwei Yang
* @author Andy Wilkinson * @author Andy Wilkinson
......
...@@ -68,7 +68,8 @@ public final class Health { ...@@ -68,7 +68,8 @@ public final class Health {
} }
/** /**
* @return the status of the health (never {@code null}) * Return the status of the health.
* @return the status (never {@code null})
*/ */
@JsonUnwrapped @JsonUnwrapped
public Status getStatus() { public Status getStatus() {
...@@ -76,7 +77,8 @@ public final class Health { ...@@ -76,7 +77,8 @@ public final class Health {
} }
/** /**
* @return the details of the health or an empty map. * Return the details of the health.
* @return the details (or an empty map)
*/ */
@JsonAnyGetter @JsonAnyGetter
public Map<String, Object> getDetails() { public Map<String, Object> getDetails() {
...@@ -280,7 +282,7 @@ public final class Health { ...@@ -280,7 +282,7 @@ public final class Health {
} }
/** /**
* Set status to given {@link Status} instance * Set status to given {@link Status} instance.
* @param status the status * @param status the status
* @return this {@link Builder} instance * @return this {@link Builder} instance
*/ */
......
...@@ -25,7 +25,8 @@ package org.springframework.boot.actuate.health; ...@@ -25,7 +25,8 @@ package org.springframework.boot.actuate.health;
public interface HealthIndicator { public interface HealthIndicator {
/** /**
* @return an indication of health * Return an indication of health.
* @return the health for
*/ */
Health health(); Health health();
......
...@@ -38,22 +38,22 @@ import com.fasterxml.jackson.annotation.JsonProperty; ...@@ -38,22 +38,22 @@ import com.fasterxml.jackson.annotation.JsonProperty;
public final class Status { public final class Status {
/** /**
* Convenient constant value representing unknown state * Convenient constant value representing unknown state.
*/ */
public static final Status UNKNOWN = new Status("UNKNOWN"); public static final Status UNKNOWN = new Status("UNKNOWN");
/** /**
* Convenient constant value representing up state * Convenient constant value representing up state.
*/ */
public static final Status UP = new Status("UP"); public static final Status UP = new Status("UP");
/** /**
* Convenient constant value representing down state * Convenient constant value representing down state.
*/ */
public static final Status DOWN = new Status("DOWN"); public static final Status DOWN = new Status("DOWN");
/** /**
* Convenient constant value representing out-of-service state * Convenient constant value representing out-of-service state.
*/ */
public static final Status OUT_OF_SERVICE = new Status("OUT_OF_SERVICE"); public static final Status OUT_OF_SERVICE = new Status("OUT_OF_SERVICE");
...@@ -82,7 +82,8 @@ public final class Status { ...@@ -82,7 +82,8 @@ public final class Status {
} }
/** /**
* @return the code for this status * Return the code for this status.
* @return the code
*/ */
@JsonProperty("status") @JsonProperty("status")
public String getCode() { public String getCode() {
...@@ -90,7 +91,8 @@ public final class Status { ...@@ -90,7 +91,8 @@ public final class Status {
} }
/** /**
* @return the description of this status * Return the description of this status.
* @return the description
*/ */
@JsonInclude(Include.NON_EMPTY) @JsonInclude(Include.NON_EMPTY)
public String getDescription() { public String getDescription() {
......
...@@ -30,7 +30,7 @@ package org.springframework.boot.actuate.metrics; ...@@ -30,7 +30,7 @@ package org.springframework.boot.actuate.metrics;
public interface GaugeService { public interface GaugeService {
/** /**
* Set the specified gauge value * Set the specified gauge value.
* @param metricName the name of the gauge to set * @param metricName the name of the gauge to set
* @param value the value of the gauge * @param value the value of the gauge
*/ */
......
...@@ -19,9 +19,9 @@ package org.springframework.boot.actuate.metrics.buffer; ...@@ -19,9 +19,9 @@ package org.springframework.boot.actuate.metrics.buffer;
/** /**
* Base class for a mutable buffer containing a timestamp and a value. * Base class for a mutable buffer containing a timestamp and a value.
* *
* @param <T> The value type
* @author Dave Syer * @author Dave Syer
* @author Phillip Webb * @author Phillip Webb
* @param <T> The value type
*/ */
abstract class Buffer<T extends Number> { abstract class Buffer<T extends Number> {
......
...@@ -32,8 +32,7 @@ import com.codahale.metrics.Timer; ...@@ -32,8 +32,7 @@ import com.codahale.metrics.Timer;
/** /**
* A {@link GaugeService} and {@link CounterService} that sends data to a Dropwizard * A {@link GaugeService} and {@link CounterService} that sends data to a Dropwizard
* {@link MetricRegistry} based on a naming convention: * {@link MetricRegistry} based on a naming convention.
*
* <ul> * <ul>
* <li>Updates to {@link #increment(String)} with names in "meter.*" are treated as * <li>Updates to {@link #increment(String)} with names in "meter.*" are treated as
* {@link Meter} events</li> * {@link Meter} events</li>
......
...@@ -109,6 +109,9 @@ public class MetricExportProperties extends TriggerProperties { ...@@ -109,6 +109,9 @@ public class MetricExportProperties extends TriggerProperties {
return this; return this;
} }
/**
* Aggregate properties.
*/
public static class Aggregate { public static class Aggregate {
/** /**
...@@ -147,6 +150,9 @@ public class MetricExportProperties extends TriggerProperties { ...@@ -147,6 +150,9 @@ public class MetricExportProperties extends TriggerProperties {
} }
/**
* Redis properties.
*/
public static class Redis { public static class Redis {
/** /**
......
...@@ -127,6 +127,9 @@ public class JmxMetricWriter implements MetricWriter { ...@@ -127,6 +127,9 @@ public class JmxMetricWriter implements MetricWriter {
return this.namingStrategy.getObjectName(value, key); return this.namingStrategy.getObjectName(value, key);
} }
/**
* A single metric value.
*/
@ManagedResource @ManagedResource
public static class MetricValue { public static class MetricValue {
......
...@@ -38,8 +38,14 @@ import org.springframework.util.ObjectUtils; ...@@ -38,8 +38,14 @@ import org.springframework.util.ObjectUtils;
*/ */
public class DefaultOpenTsdbNamingStrategy implements OpenTsdbNamingStrategy { public class DefaultOpenTsdbNamingStrategy implements OpenTsdbNamingStrategy {
/**
* The domain key.
*/
public static final String DOMAIN_KEY = "domain"; public static final String DOMAIN_KEY = "domain";
/**
* The process key.
*/
public static final String PROCESS_KEY = "process"; public static final String PROCESS_KEY = "process";
/** /**
......
...@@ -25,7 +25,7 @@ package org.springframework.boot.actuate.metrics.opentsdb; ...@@ -25,7 +25,7 @@ package org.springframework.boot.actuate.metrics.opentsdb;
public interface OpenTsdbNamingStrategy { public interface OpenTsdbNamingStrategy {
/** /**
* Convert the metric name into a {@link OpenTsdbName} * Convert the metric name into a {@link OpenTsdbName}.
* @param metricName the name of the metric * @param metricName the name of the metric
* @return an Open TSDB name * @return an Open TSDB name
*/ */
......
...@@ -28,13 +28,14 @@ import org.springframework.boot.actuate.metrics.writer.PrefixMetricWriter; ...@@ -28,13 +28,14 @@ import org.springframework.boot.actuate.metrics.writer.PrefixMetricWriter;
public interface MultiMetricRepository extends PrefixMetricReader, PrefixMetricWriter { public interface MultiMetricRepository extends PrefixMetricReader, PrefixMetricWriter {
/** /**
* The names of all the groups known to this repository * The names of all the groups known to this repository.
* @return all available group names * @return all available group names
*/ */
Iterable<String> groups(); Iterable<String> groups();
/** /**
* @return the number of groups available * The number of groups available in this repository.
* @return the number of groups
*/ */
long countGroups(); long countGroups();
......
...@@ -31,16 +31,34 @@ import org.springframework.util.Assert; ...@@ -31,16 +31,34 @@ import org.springframework.util.Assert;
*/ */
public final class RichGauge { public final class RichGauge {
/**
* The suffix for count gauges.
*/
public static final String COUNT = ".count"; public static final String COUNT = ".count";
/**
* The suffix for max gauges.
*/
public static final String MAX = ".max"; public static final String MAX = ".max";
/**
* The suffix for min gauges.
*/
public static final String MIN = ".min"; public static final String MIN = ".min";
/**
* The suffix for average value gauges.
*/
public static final String AVG = ".avg"; public static final String AVG = ".avg";
/**
* The suffix for alpha gauges.
*/
public static final String ALPHA = ".alpha"; public static final String ALPHA = ".alpha";
/**
* The suffix for value gauges.
*/
public static final String VAL = ".val"; public static final String VAL = ".val";
private final String name; private final String name;
...@@ -90,23 +108,24 @@ public final class RichGauge { ...@@ -90,23 +108,24 @@ public final class RichGauge {
} }
/** /**
* @return the name of the gauge * Return the name of the gauge.
* @return the name
*/ */
public String getName() { public String getName() {
return this.name; return this.name;
} }
/** /**
* @return the current value * Return the current value of the gauge.
* @return the value
*/ */
public double getValue() { public double getValue() {
return this.value; return this.value;
} }
/** /**
* Either an exponential weighted moving average or a simple mean, respectively, * Return either an exponential weighted moving average or a simple mean,
* depending on whether the weight 'alpha' has been set for this gauge. * respectively, depending on whether the weight 'alpha' has been set for this gauge.
*
* @return The average over all the accumulated values * @return The average over all the accumulated values
*/ */
public double getAverage() { public double getAverage() {
...@@ -114,6 +133,7 @@ public final class RichGauge { ...@@ -114,6 +133,7 @@ public final class RichGauge {
} }
/** /**
* Return the maximum value of the gauge.
* @return the maximum value * @return the maximum value
*/ */
public double getMax() { public double getMax() {
...@@ -121,6 +141,7 @@ public final class RichGauge { ...@@ -121,6 +141,7 @@ public final class RichGauge {
} }
/** /**
* Return the minimum value of the gauge.
* @return the minimum value * @return the minimum value
*/ */
public double getMin() { public double getMin() {
...@@ -128,14 +149,16 @@ public final class RichGauge { ...@@ -128,14 +149,16 @@ public final class RichGauge {
} }
/** /**
* @return Number of times the value has been set. * Return the number of times the value has been set.
* @return the value set count
*/ */
public long getCount() { public long getCount() {
return this.count; return this.count;
} }
/** /**
* @return the smoothing constant value. * Return the smoothing constant value.
* @return the alpha smoothing value
*/ */
public double getAlpha() { public double getAlpha() {
return this.alpha; return this.alpha;
......
...@@ -37,7 +37,8 @@ public interface RichGaugeReader { ...@@ -37,7 +37,8 @@ public interface RichGaugeReader {
Iterable<RichGauge> findAll(); Iterable<RichGauge> findAll();
/** /**
* @return the number of gauge values available * Return the number of gauge values available.
* @return the number of values
*/ */
long count(); long count();
......
...@@ -97,8 +97,19 @@ public class SimpleInMemoryRepository<T> { ...@@ -97,8 +97,19 @@ public class SimpleInMemoryRepository<T> {
return this.values; return this.values;
} }
/**
* Callback used to update a value.
* @param <T> the value type
*/
public interface Callback<T> { public interface Callback<T> {
/**
* Modify an existing value.
* @param current the value to modify
* @return the updated value
*/
T modify(T current); T modify(T current);
} }
} }
...@@ -32,7 +32,7 @@ import com.codahale.metrics.Timer; ...@@ -32,7 +32,7 @@ import com.codahale.metrics.Timer;
/** /**
* A {@link MetricWriter} that send data to a Dropwizard {@link MetricRegistry} based on a * A {@link MetricWriter} that send data to a Dropwizard {@link MetricRegistry} based on a
* naming convention: * naming convention.
* *
* <ul> * <ul>
* <li>Updates to {@link #increment(Delta)} with names in "meter.*" are treated as * <li>Updates to {@link #increment(Delta)} with names in "meter.*" are treated as
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
*/ */
/** /**
* Support for writing metrics * Support for writing metrics.
*/ */
package org.springframework.boot.actuate.metrics.writer; package org.springframework.boot.actuate.metrics.writer;
...@@ -48,7 +48,8 @@ public class InMemoryTraceRepository implements TraceRepository { ...@@ -48,7 +48,8 @@ public class InMemoryTraceRepository implements TraceRepository {
} }
/** /**
* @param capacity the capacity to set * Set the capacity of the in-memory repository.
* @param capacity the capacity
*/ */
public void setCapacity(int capacity) { public void setCapacity(int capacity) {
synchronized (this.traces) { synchronized (this.traces) {
......
...@@ -33,7 +33,7 @@ import org.springframework.util.StringUtils; ...@@ -33,7 +33,7 @@ import org.springframework.util.StringUtils;
/** /**
* Abstract base class for a {@link BeanFactoryPostProcessor} that can be used to * Abstract base class for a {@link BeanFactoryPostProcessor} that can be used to
* dynamically declare that all beans of a specific type should depend on one or more * dynamically declare that all beans of a specific type should depend on one or more
* specific beans * specific beans.
* *
* @author Marcel Overdijk * @author Marcel Overdijk
* @author Dave Syer * @author Dave Syer
......
...@@ -62,7 +62,7 @@ public abstract class AutoConfigurationPackages { ...@@ -62,7 +62,7 @@ public abstract class AutoConfigurationPackages {
} }
/** /**
* Return the auto-configuration base packages for the given bean factory * Return the auto-configuration base packages for the given bean factory.
* @param beanFactory the source bean factory * @param beanFactory the source bean factory
* @return a list of auto-configuration packages * @return a list of auto-configuration packages
* @throws IllegalStateException if auto-configuration is not enabled * @throws IllegalStateException if auto-configuration is not enabled
......
...@@ -30,6 +30,7 @@ public class JobExecutionEvent extends ApplicationEvent { ...@@ -30,6 +30,7 @@ public class JobExecutionEvent extends ApplicationEvent {
private final JobExecution execution; private final JobExecution execution;
/** /**
* Create a new {@link JobExecutionEvent} instance.
* @param execution the job execution * @param execution the job execution
*/ */
public JobExecutionEvent(JobExecution execution) { public JobExecutionEvent(JobExecution execution) {
...@@ -38,6 +39,7 @@ public class JobExecutionEvent extends ApplicationEvent { ...@@ -38,6 +39,7 @@ public class JobExecutionEvent extends ApplicationEvent {
} }
/** /**
* Return the job execution.
* @return the job execution * @return the job execution
*/ */
public JobExecution getJobExecution() { public JobExecution getJobExecution() {
......
...@@ -42,7 +42,7 @@ public enum CacheType { ...@@ -42,7 +42,7 @@ public enum CacheType {
EHCACHE, EHCACHE,
/** /**
* Hazelcast backed caching * Hazelcast backed caching.
*/ */
HAZELCAST, HAZELCAST,
......
...@@ -38,6 +38,8 @@ import org.springframework.util.MultiValueMap; ...@@ -38,6 +38,8 @@ import org.springframework.util.MultiValueMap;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
/** /**
* Abstract base class for nested conditions.
*
* @author Phillip Webb * @author Phillip Webb
*/ */
abstract class AbstractNestedCondition extends SpringBootCondition implements abstract class AbstractNestedCondition extends SpringBootCondition implements
......
...@@ -88,7 +88,7 @@ public final class ConditionEvaluationReport { ...@@ -88,7 +88,7 @@ public final class ConditionEvaluationReport {
} }
/** /**
* Records the name of the classes that have been excluded from condition evaluation * Records the name of the classes that have been excluded from condition evaluation.
* @param exclusions the names of the excluded classes * @param exclusions the names of the excluded classes
*/ */
public void recordExclusions(Collection<String> exclusions) { public void recordExclusions(Collection<String> exclusions) {
...@@ -97,7 +97,7 @@ public final class ConditionEvaluationReport { ...@@ -97,7 +97,7 @@ public final class ConditionEvaluationReport {
} }
/** /**
* Records the names of the classes that are candidates for condition evaluation * Records the names of the classes that are candidates for condition evaluation.
* @param evaluationCandidates the names of the classes whose conditions will be * @param evaluationCandidates the names of the classes whose conditions will be
* evaluated * evaluated
*/ */
......
...@@ -27,7 +27,7 @@ import org.springframework.core.annotation.Order; ...@@ -27,7 +27,7 @@ import org.springframework.core.annotation.Order;
import org.springframework.core.type.AnnotatedTypeMetadata; import org.springframework.core.type.AnnotatedTypeMetadata;
/** /**
* {@link Condition} that checks for a required version of Java * {@link Condition} that checks for a required version of Java.
* *
* @author Oliver Gierke * @author Oliver Gierke
* @author Phillip Webb * @author Phillip Webb
......
...@@ -35,8 +35,8 @@ import org.springframework.util.StringUtils; ...@@ -35,8 +35,8 @@ import org.springframework.util.StringUtils;
* @author Maciej Walkowiak * @author Maciej Walkowiak
* @author Phillip Webb * @author Phillip Webb
* @author Stephane Nicoll * @author Stephane Nicoll
* @see ConditionalOnProperty
* @since 1.1.0 * @since 1.1.0
* @see ConditionalOnProperty
*/ */
class OnPropertyCondition extends SpringBootCondition { class OnPropertyCondition extends SpringBootCondition {
......
...@@ -24,17 +24,17 @@ package org.springframework.boot.autoconfigure.condition; ...@@ -24,17 +24,17 @@ package org.springframework.boot.autoconfigure.condition;
public enum SearchStrategy { public enum SearchStrategy {
/** /**
* Search only the current context * Search only the current context.
*/ */
CURRENT, CURRENT,
/** /**
* Search all parents and ancestors, but not the current context * Search all parents and ancestors, but not the current context.
*/ */
PARENTS, PARENTS,
/** /**
* Search the entire hierarchy * Search the entire hierarchy.
*/ */
ALL ALL
......
...@@ -25,7 +25,7 @@ import org.springframework.dao.annotation.PersistenceExceptionTranslationPostPro ...@@ -25,7 +25,7 @@ import org.springframework.dao.annotation.PersistenceExceptionTranslationPostPro
/** /**
* {@link EnableAutoConfiguration Auto-configuration} for Spring's persistence exception * {@link EnableAutoConfiguration Auto-configuration} for Spring's persistence exception
* translation * translation.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.2.0 * @since 1.2.0
......
...@@ -23,7 +23,7 @@ import org.springframework.boot.autoconfigure.template.AbstractTemplateViewResol ...@@ -23,7 +23,7 @@ import org.springframework.boot.autoconfigure.template.AbstractTemplateViewResol
import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.boot.context.properties.ConfigurationProperties;
/** /**
* {@link ConfigurationProperties} for configuring FreeMarker * {@link ConfigurationProperties} for configuring FreeMarker.
* *
* @author Dave Syer * @author Dave Syer
* @author Andy Wilkinson * @author Andy Wilkinson
......
...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils; ...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils;
/** /**
* {@link TemplateAvailabilityProvider} that provides availability information for * {@link TemplateAvailabilityProvider} that provides availability information for
* FreeMarker view templates * FreeMarker view templates.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.1.0 * @since 1.1.0
......
...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils; ...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils;
/** /**
* {@link TemplateAvailabilityProvider} that provides availability information for Groovy * {@link TemplateAvailabilityProvider} that provides availability information for Groovy
* view templates * view templates.
* *
* @author Dave Syer * @author Dave Syer
* @since 1.1.0 * @since 1.1.0
......
...@@ -37,7 +37,7 @@ import org.springframework.security.config.annotation.web.builders.HttpSecurity; ...@@ -37,7 +37,7 @@ import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter; import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
/** /**
* {@link EnableAutoConfiguration Auto-configuration} for H2's web console * {@link EnableAutoConfiguration Auto-configuration} for H2's web console.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.3.0 * @since 1.3.0
......
...@@ -22,7 +22,7 @@ import javax.validation.constraints.Pattern; ...@@ -22,7 +22,7 @@ import javax.validation.constraints.Pattern;
import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.boot.context.properties.ConfigurationProperties;
/** /**
* Configuration properties for H2's console * Configuration properties for H2's console.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.3.0 * @since 1.3.0
......
...@@ -31,7 +31,7 @@ import com.fasterxml.jackson.databind.MapperFeature; ...@@ -31,7 +31,7 @@ import com.fasterxml.jackson.databind.MapperFeature;
import com.fasterxml.jackson.databind.SerializationFeature; import com.fasterxml.jackson.databind.SerializationFeature;
/** /**
* Configuration properties to configure Jackson * Configuration properties to configure Jackson.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @author Marcel Overdijk * @author Marcel Overdijk
......
...@@ -188,6 +188,8 @@ public class DataSourceAutoConfiguration { ...@@ -188,6 +188,8 @@ public class DataSourceAutoConfiguration {
/** /**
* Returns the class loader for the {@link DataSource} class. Used to ensure that * Returns the class loader for the {@link DataSource} class. Used to ensure that
* the driver class can actually be loaded by the data source. * the driver class can actually be loaded by the data source.
* @param context the condition context
* @return the class loader
*/ */
private ClassLoader getDataSourceClassLoader(ConditionContext context) { private ClassLoader getDataSourceClassLoader(ConditionContext context) {
Class<?> dataSourceClass = new DataSourceBuilder(context.getClassLoader()) Class<?> dataSourceClass = new DataSourceBuilder(context.getClassLoader())
...@@ -222,7 +224,7 @@ public class DataSourceAutoConfiguration { ...@@ -222,7 +224,7 @@ public class DataSourceAutoConfiguration {
/** /**
* {@link Condition} to detect when a {@link DataSource} is available (either because * {@link Condition} to detect when a {@link DataSource} is available (either because
* the user provided one or because one will be auto-configured) * the user provided one or because one will be auto-configured).
*/ */
@Order(Ordered.LOWEST_PRECEDENCE - 10) @Order(Ordered.LOWEST_PRECEDENCE - 10)
static class DataSourceAvailableCondition extends SpringBootCondition { static class DataSourceAvailableCondition extends SpringBootCondition {
......
...@@ -69,22 +69,22 @@ enum DatabaseDriver { ...@@ -69,22 +69,22 @@ enum DatabaseDriver {
GOOGLE("com.google.appengine.api.rdbms.AppEngineDriver"), GOOGLE("com.google.appengine.api.rdbms.AppEngineDriver"),
/** /**
* Oracle * Oracle.
*/ */
ORACLE("oracle.jdbc.OracleDriver", "oracle.jdbc.xa.client.OracleXADataSource"), ORACLE("oracle.jdbc.OracleDriver", "oracle.jdbc.xa.client.OracleXADataSource"),
/** /**
* Postres * Postres.
*/ */
POSTGRESQL("org.postgresql.Driver", "org.postgresql.xa.PGXADataSource"), POSTGRESQL("org.postgresql.Driver", "org.postgresql.xa.PGXADataSource"),
/** /**
* JTDS * JTDS.
*/ */
JTDS("net.sourceforge.jtds.jdbc.Driver"), JTDS("net.sourceforge.jtds.jdbc.Driver"),
/** /**
* SQL Server * SQL Server.
*/ */
SQLSERVER("com.microsoft.sqlserver.jdbc.SQLServerDriver", SQLSERVER("com.microsoft.sqlserver.jdbc.SQLServerDriver",
"com.microsoft.sqlserver.jdbc.SQLServerXADataSource"); "com.microsoft.sqlserver.jdbc.SQLServerXADataSource");
...@@ -103,14 +103,16 @@ enum DatabaseDriver { ...@@ -103,14 +103,16 @@ enum DatabaseDriver {
} }
/** /**
* @return the driverClassName or {@code null} * Return the driver class name.
* @return the class name or {@code null}
*/ */
public String getDriverClassName() { public String getDriverClassName() {
return this.driverClassName; return this.driverClassName;
} }
/** /**
* @return the xaDataSourceClassName or {@code null} * Return the XA driver source class name.
* @return the class name or {@code null}
*/ */
public String getXaDataSourceClassName() { public String getXaDataSourceClassName() {
return this.xaDataSourceClassName; return this.xaDataSourceClassName;
......
...@@ -53,7 +53,7 @@ class DriverClassNameProvider { ...@@ -53,7 +53,7 @@ class DriverClassNameProvider {
} }
/** /**
* Find a JDBC driver class name based on given JDBC URL * Find a JDBC driver class name based on given JDBC URL.
* @param jdbcUrl JDBC URL * @param jdbcUrl JDBC URL
* @return driver class name or null if not found * @return driver class name or null if not found
*/ */
......
...@@ -82,7 +82,7 @@ public class JndiConnectionFactoryAutoConfiguration { ...@@ -82,7 +82,7 @@ public class JndiConnectionFactoryAutoConfiguration {
} }
/** /**
* Condition for JNDI name or a specific property * Condition for JNDI name or a specific property.
*/ */
static class JndiOrPropertyCondition extends AnyNestedCondition { static class JndiOrPropertyCondition extends AnyNestedCondition {
......
...@@ -19,7 +19,7 @@ package org.springframework.boot.autoconfigure.jms.activemq; ...@@ -19,7 +19,7 @@ package org.springframework.boot.autoconfigure.jms.activemq;
import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.boot.context.properties.ConfigurationProperties;
/** /**
* Configuration properties for ActiveMQ * Configuration properties for ActiveMQ.
* *
* @author Greg Turnquist * @author Greg Turnquist
* @author Stephane Nicoll * @author Stephane Nicoll
......
...@@ -92,6 +92,7 @@ class ArtemisConnectionFactoryFactory { ...@@ -92,6 +92,7 @@ class ArtemisConnectionFactoryFactory {
/** /**
* Deduce the {@link ArtemisMode} to use if none has been set. * Deduce the {@link ArtemisMode} to use if none has been set.
* @return the mode
*/ */
private ArtemisMode deduceMode() { private ArtemisMode deduceMode() {
if (this.properties.getEmbedded().isEnabled() if (this.properties.getEmbedded().isEnabled()
......
...@@ -25,7 +25,7 @@ import org.apache.activemq.artemis.core.remoting.impl.invm.TransportConstants; ...@@ -25,7 +25,7 @@ import org.apache.activemq.artemis.core.remoting.impl.invm.TransportConstants;
import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.boot.context.properties.ConfigurationProperties;
/** /**
* Configuration properties for Artemis * Configuration properties for Artemis.
* *
* @author Eddú Meléndez * @author Eddú Meléndez
* @author Stephane Nicoll * @author Stephane Nicoll
......
...@@ -92,6 +92,7 @@ class HornetQConnectionFactoryFactory { ...@@ -92,6 +92,7 @@ class HornetQConnectionFactoryFactory {
/** /**
* Deduce the {@link HornetQMode} to use if none has been set. * Deduce the {@link HornetQMode} to use if none has been set.
* @return the mode
*/ */
private HornetQMode deduceMode() { private HornetQMode deduceMode() {
if (this.properties.getEmbedded().isEnabled() if (this.properties.getEmbedded().isEnabled()
......
...@@ -25,7 +25,7 @@ import org.hornetq.core.remoting.impl.invm.TransportConstants; ...@@ -25,7 +25,7 @@ import org.hornetq.core.remoting.impl.invm.TransportConstants;
import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.boot.context.properties.ConfigurationProperties;
/** /**
* Configuration properties for HornetQ * Configuration properties for HornetQ.
* *
* @author Stephane Nicoll * @author Stephane Nicoll
* @since 1.1.0 * @since 1.1.0
......
...@@ -48,7 +48,8 @@ public class ParentAwareNamingStrategy extends MetadataNamingStrategy implements ...@@ -48,7 +48,8 @@ public class ParentAwareNamingStrategy extends MetadataNamingStrategy implements
} }
/** /**
* @param ensureUniqueRuntimeObjectNames the ensureUniqueRuntimeObjectNames to set * Set if unique runtime object names should be ensured.
* @param ensureUniqueRuntimeObjectNames {@code true} if unique names should ensured.
*/ */
public void setEnsureUniqueRuntimeObjectNames(boolean ensureUniqueRuntimeObjectNames) { public void setEnsureUniqueRuntimeObjectNames(boolean ensureUniqueRuntimeObjectNames) {
this.ensureUniqueRuntimeObjectNames = ensureUniqueRuntimeObjectNames; this.ensureUniqueRuntimeObjectNames = ensureUniqueRuntimeObjectNames;
......
...@@ -183,7 +183,7 @@ public class MongoProperties { ...@@ -183,7 +183,7 @@ public class MongoProperties {
} }
/** /**
* Creates a {@link MongoClient} using the given {@code options} * Creates a {@link MongoClient} using the given {@code options}.
* *
* @param options the options * @param options the options
* @return the Mongo client * @return the Mongo client
......
...@@ -25,7 +25,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties; ...@@ -25,7 +25,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties;
import de.flapdoodle.embed.mongo.distribution.Feature; import de.flapdoodle.embed.mongo.distribution.Feature;
/** /**
* Configuration properties for Embedded Mongo * Configuration properties for Embedded Mongo.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.3.0 * @since 1.3.0
......
...@@ -59,14 +59,16 @@ public class MustacheResourceTemplateLoader implements TemplateLoader, ...@@ -59,14 +59,16 @@ public class MustacheResourceTemplateLoader implements TemplateLoader,
} }
/** /**
* @param charSet the charSet to set * Set the charset.
* @param charSet the charset
*/ */
public void setCharset(String charSet) { public void setCharset(String charSet) {
this.charSet = charSet; this.charSet = charSet;
} }
/** /**
* @param resourceLoader the resourceLoader to set * Set the resource loader.
* @param resourceLoader the resource loader
*/ */
@Override @Override
public void setResourceLoader(ResourceLoader resourceLoader) { public void setResourceLoader(ResourceLoader resourceLoader) {
......
...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils; ...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils;
/** /**
* {@link TemplateAvailabilityProvider} that provides availability information for * {@link TemplateAvailabilityProvider} that provides availability information for
* Mustache view templates * Mustache view templates.
* *
* @author Dave Syer * @author Dave Syer
* @since 1.2.2 * @since 1.2.2
......
...@@ -39,8 +39,8 @@ public class MustacheView extends AbstractTemplateView { ...@@ -39,8 +39,8 @@ public class MustacheView extends AbstractTemplateView {
/** /**
* Create a new {@link MustacheView} instance. * Create a new {@link MustacheView} instance.
* @see #setTemplate(Template)
* @since 1.2.5 * @since 1.2.5
* @see #setTemplate(Template)
*/ */
public MustacheView() { public MustacheView() {
} }
......
...@@ -55,14 +55,16 @@ public class MustacheViewResolver extends UrlBasedViewResolver { ...@@ -55,14 +55,16 @@ public class MustacheViewResolver extends UrlBasedViewResolver {
} }
/** /**
* @param compiler the compiler to set * Set the compiler.
* @param compiler the compiler
*/ */
public void setCompiler(Compiler compiler) { public void setCompiler(Compiler compiler) {
this.compiler = compiler; this.compiler = compiler;
} }
/** /**
* @param charset the charset to set * Set the charset.
* @param charset the charset
*/ */
public void setCharset(String charset) { public void setCharset(String charset) {
this.charset = charset; this.charset = charset;
......
...@@ -141,7 +141,8 @@ public abstract class JpaBaseConfiguration implements BeanFactoryAware { ...@@ -141,7 +141,8 @@ public abstract class JpaBaseConfiguration implements BeanFactoryAware {
} }
/** /**
* @return the jtaTransactionManager or {@code null} * Return the JTA transaction manager.
* @return the transaction manager or {@code null}
*/ */
protected JtaTransactionManager getJtaTransactionManager() { protected JtaTransactionManager getJtaTransactionManager() {
return this.jtaTransactionManager; return this.jtaTransactionManager;
......
...@@ -30,7 +30,7 @@ import org.springframework.context.annotation.Configuration; ...@@ -30,7 +30,7 @@ import org.springframework.context.annotation.Configuration;
import com.sendgrid.SendGrid; import com.sendgrid.SendGrid;
/** /**
* {@link EnableAutoConfiguration Auto-configuration} for SendGrid * {@link EnableAutoConfiguration Auto-configuration} for SendGrid.
* *
* @author Maciej Walkowiak * @author Maciej Walkowiak
* @since 1.3.0 * @since 1.3.0
......
...@@ -31,7 +31,7 @@ import org.springframework.context.annotation.Configuration; ...@@ -31,7 +31,7 @@ import org.springframework.context.annotation.Configuration;
import org.springframework.util.StringUtils; import org.springframework.util.StringUtils;
/** /**
* {@link EnableAutoConfiguration Auto-configuration} for Solr * {@link EnableAutoConfiguration Auto-configuration} for Solr.
* *
* @author Christoph Strobl * @author Christoph Strobl
* @since 1.1.0 * @since 1.1.0
......
...@@ -21,7 +21,7 @@ import org.springframework.core.io.ResourceLoader; ...@@ -21,7 +21,7 @@ import org.springframework.core.io.ResourceLoader;
/** /**
* Indicates the availability of view templates for a particular templating engine such as * Indicates the availability of view templates for a particular templating engine such as
* FreeMarker or Thymeleaf * FreeMarker or Thymeleaf.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.1.0 * @since 1.1.0
......
...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils; ...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils;
/** /**
* {@link TemplateAvailabilityProvider} that provides availability information for * {@link TemplateAvailabilityProvider} that provides availability information for
* Thymeleaf view templates * Thymeleaf view templates.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.1.0 * @since 1.1.0
......
...@@ -24,7 +24,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties; ...@@ -24,7 +24,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.web.servlet.view.velocity.VelocityViewResolver; import org.springframework.web.servlet.view.velocity.VelocityViewResolver;
/** /**
* {@link ConfigurationProperties} for configuring Velocity * {@link ConfigurationProperties} for configuring Velocity.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.1.0 * @since 1.1.0
......
...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils; ...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils;
/** /**
* {@link TemplateAvailabilityProvider} that provides availability information for * {@link TemplateAvailabilityProvider} that provides availability information for
* Velocity view templates * Velocity view templates.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.1.0 * @since 1.1.0
......
...@@ -30,7 +30,7 @@ import org.springframework.http.converter.json.MappingJackson2HttpMessageConvert ...@@ -30,7 +30,7 @@ import org.springframework.http.converter.json.MappingJackson2HttpMessageConvert
import com.google.gson.Gson; import com.google.gson.Gson;
/** /**
* Configuration for HTTP Message converters that use Gson * Configuration for HTTP Message converters that use Gson.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.2.2 * @since 1.2.2
......
...@@ -30,7 +30,7 @@ import com.fasterxml.jackson.databind.ObjectMapper; ...@@ -30,7 +30,7 @@ import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.dataformat.xml.XmlMapper; import com.fasterxml.jackson.dataformat.xml.XmlMapper;
/** /**
* Configuration for HTTP message converters that use Jackson * Configuration for HTTP message converters that use Jackson.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @since 1.2.2 * @since 1.2.2
......
...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils; ...@@ -23,7 +23,7 @@ import org.springframework.util.ClassUtils;
/** /**
* {@link TemplateAvailabilityProvider} that provides availability information for JSP * {@link TemplateAvailabilityProvider} that provides availability information for JSP
* view templates * view templates.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @author Stephane Nicoll * @author Stephane Nicoll
......
...@@ -119,7 +119,7 @@ public class MultipartProperties { ...@@ -119,7 +119,7 @@ public class MultipartProperties {
} }
/** /**
* Create a new {@link MultipartConfigElement} using the * Create a new {@link MultipartConfigElement} using the properties.
* @return a new {@link MultipartConfigElement} configured using there properties * @return a new {@link MultipartConfigElement} configured using there properties
*/ */
public MultipartConfigElement createMultipartConfig() { public MultipartConfigElement createMultipartConfig() {
......
...@@ -206,7 +206,7 @@ public class ServerProperties implements EmbeddedServletContainerCustomizer, Ord ...@@ -206,7 +206,7 @@ public class ServerProperties implements EmbeddedServletContainerCustomizer, Ord
} }
/** /**
* Get the session timeout * Get the session timeout.
* @return the session timeout * @return the session timeout
* @deprecated since 1.3.0 in favor of {@code session.timeout}. * @deprecated since 1.3.0 in favor of {@code session.timeout}.
*/ */
...@@ -217,7 +217,7 @@ public class ServerProperties implements EmbeddedServletContainerCustomizer, Ord ...@@ -217,7 +217,7 @@ public class ServerProperties implements EmbeddedServletContainerCustomizer, Ord
} }
/** /**
* Set the session timeout * Set the session timeout.
* @param sessionTimeout the session timeout * @param sessionTimeout the session timeout
* @deprecated since 1.3.0 in favor of {@code session.timeout}. * @deprecated since 1.3.0 in favor of {@code session.timeout}.
*/ */
...@@ -582,7 +582,7 @@ public class ServerProperties implements EmbeddedServletContainerCustomizer, Ord ...@@ -582,7 +582,7 @@ public class ServerProperties implements EmbeddedServletContainerCustomizer, Ord
} }
/** /**
* Set the format pattern for access logs * Set the format pattern for access logs.
* @param accessLogPattern the pattern for access logs * @param accessLogPattern the pattern for access logs
* @deprecated since 1.3.0 in favor of {@code server.tomcat.accesslog.pattern} * @deprecated since 1.3.0 in favor of {@code server.tomcat.accesslog.pattern}
*/ */
...@@ -903,7 +903,7 @@ public class ServerProperties implements EmbeddedServletContainerCustomizer, Ord ...@@ -903,7 +903,7 @@ public class ServerProperties implements EmbeddedServletContainerCustomizer, Ord
} }
/** /**
* Set the format pattern for access logs * Set the format pattern for access logs.
* @param accessLogPattern the pattern for access logs * @param accessLogPattern the pattern for access logs
* @deprecated since 1.3.0 in favor of {@code server.undertow.accesslog.pattern} * @deprecated since 1.3.0 in favor of {@code server.undertow.accesslog.pattern}
*/ */
......
...@@ -30,8 +30,8 @@ import static org.junit.Assert.assertEquals; ...@@ -30,8 +30,8 @@ import static org.junit.Assert.assertEquals;
/** /**
* Abstract base class for {@link DataSourcePoolMetadata} tests. * Abstract base class for {@link DataSourcePoolMetadata} tests.
* *
* @author Stephane Nicoll
* @param <D> the data source pool metadata type * @param <D> the data source pool metadata type
* @author Stephane Nicoll
*/ */
public abstract class AbstractDataSourcePoolMetadataTests<D extends AbstractDataSourcePoolMetadata<?>> { public abstract class AbstractDataSourcePoolMetadataTests<D extends AbstractDataSourcePoolMetadata<?>> {
......
...@@ -292,7 +292,7 @@ public class OAuth2AutoConfigurationTests { ...@@ -292,7 +292,7 @@ public class OAuth2AutoConfigurationTests {
/** /**
* Connect to the oauth service, get a token, and then attempt some operations using * Connect to the oauth service, get a token, and then attempt some operations using
* it. * it.
* @param config * @param config the client details.
*/ */
private void verifyAuthentication(ClientDetails config) { private void verifyAuthentication(ClientDetails config) {
verifyAuthentication(config, HttpStatus.FORBIDDEN); verifyAuthentication(config, HttpStatus.FORBIDDEN);
......
...@@ -73,8 +73,8 @@ public interface Command { ...@@ -73,8 +73,8 @@ public interface Command {
/** /**
* Run the command. * Run the command.
* @param args command arguments (this will not include the command itself) * @param args command arguments (this will not include the command itself)
* @throws Exception if the command fails
* @return the outcome of the command * @return the outcome of the command
* @throws Exception if the command fails
*/ */
ExitStatus run(String... args) throws Exception; ExitStatus run(String... args) throws Exception;
......
...@@ -32,9 +32,9 @@ import org.springframework.util.StringUtils; ...@@ -32,9 +32,9 @@ import org.springframework.util.StringUtils;
/** /**
* Main class used to run {@link Command}s. * Main class used to run {@link Command}s.
* *
* @author Phillip Webb
* @see #addCommand(Command) * @see #addCommand(Command)
* @see CommandRunner#runAndHandleErrors(String[]) * @see CommandRunner#runAndHandleErrors(String[])
* @author Phillip Webb
*/ */
public class CommandRunner implements Iterable<Command> { public class CommandRunner implements Iterable<Command> {
...@@ -201,8 +201,8 @@ public class CommandRunner implements Iterable<Command> { ...@@ -201,8 +201,8 @@ public class CommandRunner implements Iterable<Command> {
/** /**
* Parse the arguments and run a suitable command. * Parse the arguments and run a suitable command.
* @param args the arguments * @param args the arguments
* @throws Exception if the command fails
* @return the outcome of the command * @return the outcome of the command
* @throws Exception if the command fails
*/ */
protected ExitStatus run(String... args) throws Exception { protected ExitStatus run(String... args) throws Exception {
if (args.length == 0) { if (args.length == 0) {
......
...@@ -29,6 +29,7 @@ public class HelpExample { ...@@ -29,6 +29,7 @@ public class HelpExample {
private final String example; private final String example;
/** /**
* Create a new {@link HelpExample} instance.
* @param description The description (in the form "to ....") * @param description The description (in the form "to ....")
* @param example the example * @param example the example
*/ */
......
...@@ -32,7 +32,7 @@ import org.springframework.boot.cli.compiler.grape.RepositoryConfiguration; ...@@ -32,7 +32,7 @@ import org.springframework.boot.cli.compiler.grape.RepositoryConfiguration;
import joptsimple.OptionSet; import joptsimple.OptionSet;
/** /**
* {@link Command} to grab the dependencies of one or more Groovy scripts * {@link Command} to grab the dependencies of one or more Groovy scripts.
* *
* @author Andy Wilkinson * @author Andy Wilkinson
*/ */
......
...@@ -69,6 +69,9 @@ public class InitCommand extends OptionParsingCommand { ...@@ -69,6 +69,9 @@ public class InitCommand extends OptionParsingCommand {
return examples; return examples;
} }
/**
* {@link OptionHandler} for {@link InitCommand}.
*/
static class InitOptionHandler extends OptionHandler { static class InitOptionHandler extends OptionHandler {
private final ServiceCapabilitiesReportGenerator serviceCapabilitiesReport; private final ServiceCapabilitiesReportGenerator serviceCapabilitiesReport;
......
...@@ -81,7 +81,7 @@ class InitializrService { ...@@ -81,7 +81,7 @@ class InitializrService {
} }
/** /**
* Generate a project based on the specified {@link ProjectGenerationRequest} * Generate a project based on the specified {@link ProjectGenerationRequest}.
* @param request the generation request * @param request the generation request
* @return an entity defining the project * @return an entity defining the project
* @throws IOException if generation fails * @throws IOException if generation fails
...@@ -166,14 +166,18 @@ class InitializrService { ...@@ -166,14 +166,18 @@ class InitializrService {
} }
/** /**
* Request the creation of the project using the specified URL * Request the creation of the project using the specified URL.
* @param url the URL
* @return the response
*/ */
private CloseableHttpResponse executeProjectGenerationRequest(URI url) { private CloseableHttpResponse executeProjectGenerationRequest(URI url) {
return execute(new HttpGet(url), url, "generate project"); return execute(new HttpGet(url), url, "generate project");
} }
/** /**
* Retrieves the meta-data of the service at the specified URL * Retrieves the meta-data of the service at the specified URL.
* @param url the URL
* @return the response
*/ */
private CloseableHttpResponse executeInitializrMetadataRetrieval(String url) { private CloseableHttpResponse executeInitializrMetadataRetrieval(String url) {
HttpGet request = new HttpGet(url); HttpGet request = new HttpGet(url);
......
...@@ -76,8 +76,8 @@ class ProjectGenerationRequest { ...@@ -76,8 +76,8 @@ class ProjectGenerationRequest {
/** /**
* The URL of the service to use. * The URL of the service to use.
* @see #DEFAULT_SERVICE_URL
* @return the service URL * @return the service URL
* @see #DEFAULT_SERVICE_URL
*/ */
public String getServiceUrl() { public String getServiceUrl() {
return this.serviceUrl; return this.serviceUrl;
...@@ -299,7 +299,7 @@ class ProjectGenerationRequest { ...@@ -299,7 +299,7 @@ class ProjectGenerationRequest {
} }
/** /**
* Generates the URI to use to generate a project represented by this request * Generates the URI to use to generate a project represented by this request.
* @param metadata the metadata that describes the service * @param metadata the metadata that describes the service
* @return the project generation URI * @return the project generation URI
*/ */
......
...@@ -19,7 +19,7 @@ package org.springframework.boot.cli.command.init; ...@@ -19,7 +19,7 @@ package org.springframework.boot.cli.command.init;
import org.apache.http.entity.ContentType; import org.apache.http.entity.ContentType;
/** /**
* Represent the response of a {@link ProjectGenerationRequest} * Represent the response of a {@link ProjectGenerationRequest}.
* *
* @author Stephane Nicoll * @author Stephane Nicoll
* @since 1.2.0 * @since 1.2.0
...@@ -37,7 +37,7 @@ class ProjectGenerationResponse { ...@@ -37,7 +37,7 @@ class ProjectGenerationResponse {
} }
/** /**
* Return the {@link ContentType} of this instance * Return the {@link ContentType} of this instance.
* @return the content type * @return the content type
*/ */
public ContentType getContentType() { public ContentType getContentType() {
......
...@@ -70,6 +70,9 @@ class ProjectGenerator { ...@@ -70,6 +70,9 @@ class ProjectGenerator {
/** /**
* Detect if the project should be extracted. * Detect if the project should be extracted.
* @param request the generation request
* @param response the generation response
* @return if the project should be extracted
*/ */
private boolean shouldExtract(ProjectGenerationRequest request, private boolean shouldExtract(ProjectGenerationRequest request,
ProjectGenerationResponse response) { ProjectGenerationResponse response) {
......
...@@ -31,7 +31,7 @@ import org.springframework.boot.cli.compiler.GroovyCompiler; ...@@ -31,7 +31,7 @@ import org.springframework.boot.cli.compiler.GroovyCompiler;
import org.springframework.boot.cli.compiler.GroovyCompilerConfiguration; import org.springframework.boot.cli.compiler.GroovyCompilerConfiguration;
/** /**
* A {@code DependencyResolver} implemented using Groovy's {@code @Grab} * A {@code DependencyResolver} implemented using Groovy's {@code @Grab}.
* *
* @author Dave Syer * @author Dave Syer
* @author Andy Wilkinson * @author Andy Wilkinson
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment