pull/1055/merge
Phillip Webb 11 years ago
parent 80b7e60c01
commit b5d267ca89

@ -105,7 +105,6 @@ public class EndpointWebMvcChildContextConfiguration {
@Bean
public HandlerAdapter handlerAdapter(HttpMessageConverters converters) {
// TODO: maybe this needs more configuration for non-basic response use cases
RequestMappingHandlerAdapter adapter = new RequestMappingHandlerAdapter();
adapter.setMessageConverters(converters.getConverters());
return adapter;

@ -34,6 +34,7 @@ import org.springframework.util.StringUtils;
*
* @author Dave Syer
* @author Christian Dupuis
* @since 1.1.0
*/
public class DataSourceHealthIndicator extends AbstractHealthIndicator {

@ -1,5 +1,5 @@
/*
* Copyright 2012-2013 the original author or authors.
* Copyright 2012-2014 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -24,12 +24,14 @@ import java.util.Map;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.springframework.web.servlet.View;
import org.springframework.web.servlet.support.RequestContext;
import org.springframework.web.servlet.view.AbstractUrlBasedView;
/**
* @author Dave Syer
* Spring MVC {@link View} that can render Groovy templates.
*
* @author Dave Syer
* @since 1.1.0
*/
public class GroovyTemplateView extends AbstractUrlBasedView {

@ -1,5 +1,5 @@
/*
* Copyright 2012-2013 the original author or authors.
* Copyright 2012-2014 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -25,11 +25,15 @@ import java.util.Locale;
import org.springframework.beans.propertyeditors.LocaleEditor;
import org.springframework.core.io.Resource;
import org.springframework.web.servlet.View;
import org.springframework.web.servlet.ViewResolver;
import org.springframework.web.servlet.view.UrlBasedViewResolver;
/**
* Spring MVC {@link ViewResolver} for {@link GroovyTemplateView}s.
*
* @author Dave Syer
* @since 1.1.0
* @see GroovyTemplateView
*/
public class GroovyTemplateViewResolver extends UrlBasedViewResolver {

@ -46,6 +46,7 @@ import com.mongodb.Mongo;
* @author Dave Syer
* @author Oliver Gierke
* @author Josh Long
* @since 1.1.0
*/
@Configuration
@ConditionalOnClass({ Mongo.class, MongoTemplate.class })

@ -27,8 +27,8 @@ import org.springframework.social.connect.ConnectionFactory;
/**
* Base class for auto-configured {@link SocialConfigurerAdapter}s.
*
* @author Phillip Webb
* @author Craig Walls
* @author Phillip Webb
* @since 1.1.0
*/
@ConditionalOnClass(SocialConfigurerAdapter.class)

@ -27,6 +27,7 @@ import org.springframework.util.StringUtils;
* Provides access to the java binary executable, regardless of OS.
*
* @author Phillip Webb
* @since 1.1.0
*/
public class JavaExecutable {
@ -47,7 +48,11 @@ public class JavaExecutable {
return command;
}
// TODO: is this used?
/**
* Create a new {@link ProcessBuilder} that will run with the Java executable.
* @param arguments the command arguments
* @return a {@link ProcessBuilder}
*/
public ProcessBuilder processBuilder(String... arguments) {
ProcessBuilder processBuilder = new ProcessBuilder(toString());
processBuilder.command().addAll(Arrays.asList(arguments));

@ -1,5 +1,5 @@
/*
* Copyright 2012-2013 the original author or authors.
* Copyright 2012-2014 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -24,9 +24,12 @@ import org.springframework.util.ClassUtils;
import ch.qos.logback.classic.Level;
/**
* Utility to initialize logback (when present) to use INFO level logging.
*
* @author Dave Syer
* @since 1.1.0
*/
public class LogbackInitializer {
public abstract class LogbackInitializer {
public static void initialize() {
if (ClassUtils.isPresent("org.slf4j.impl.StaticLoggerBinder", null)

@ -26,10 +26,11 @@ import java.util.Collection;
import org.springframework.util.ReflectionUtils;
/**
* Special utility used to run a process.
* Utility used to run a process.
*
* @author Phillip Webb
* @author Dave Syer
* @since 1.1.0
*/
public class RunProcess {

@ -1,5 +1,5 @@
/*
* Copyright 2012-2013 the original author or authors.
* Copyright 2012-2014 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -20,13 +20,20 @@ import sun.misc.Signal;
import sun.misc.SignalHandler;
/**
* Utilities for working with signal handling.
*
* @author Dave Syer
* @since 1.1.0
*/
@SuppressWarnings("restriction")
public class SignalUtils {
private static final Signal SIG_INT = new Signal("INT");
/**
* Handle {@literal INT} signals by calling the specified {@link Runnable}
* @param runnable the runnable to call on SIGINT.
*/
public static void attachSignalHandler(final Runnable runnable) {
Signal.handle(SIG_INT, new SignalHandler() {
@Override

@ -22,7 +22,7 @@ import java.net.URL;
* A strategy for detecting Java agents
*
* @author Andy Wilkinson
* @since 1.1
* @since 1.1.0
*/
public interface JavaAgentDetector {

Loading…
Cancel
Save