Merge branch '1.5.x' into 2.0.x

This commit is contained in:
Phillip Webb
2019-06-28 23:27:59 -07:00
342 changed files with 332 additions and 139 deletions

View File

@@ -37,6 +37,7 @@ import org.springframework.boot.cli.command.run.RunCommand;
* Default implementation of {@link CommandFactory}.
*
* @author Dave Syer
* @since 1.0.0
*/
public class DefaultCommandFactory implements CommandFactory {

View File

@@ -39,6 +39,7 @@ import org.springframework.util.SystemPropertyUtils;
* application.
*
* @author Phillip Webb
* @since 1.0.0
* @see #main(String...)
* @see CommandRunner
*/

View File

@@ -29,6 +29,7 @@ import org.springframework.boot.cli.app.SpringApplicationLauncher;
*
* @author Andy Wilkinson
* @author Phillip Webb
* @since 1.0.0
*/
public final class PackagedSpringApplicationLauncher {

View File

@@ -26,6 +26,7 @@ import org.springframework.boot.cli.command.options.OptionHelp;
*
* @author Phillip Webb
* @author Dave Syer
* @since 1.0.0
*/
public abstract class AbstractCommand implements Command {

View File

@@ -27,6 +27,7 @@ import org.springframework.boot.cli.command.status.ExitStatus;
* @author Phillip Webb
* @author Dave Syer
* @author Stephane Nicoll
* @since 1.0.0
* @see #run(String...)
*/
public interface Command {

View File

@@ -26,6 +26,7 @@ import java.util.Set;
* by the {@link CommandRunner}.
*
* @author Phillip Webb
* @since 1.0.0
*/
public class CommandException extends RuntimeException {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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,6 +24,7 @@ import java.util.ServiceLoader;
* {@link ServiceLoader}.
*
* @author Dave Syer
* @since 1.0.0
*/
@FunctionalInterface
public interface CommandFactory {

View File

@@ -33,6 +33,7 @@ import org.springframework.util.StringUtils;
* Main class used to run {@link Command}s.
*
* @author Phillip Webb
* @since 1.0.0
* @see #addCommand(Command)
* @see CommandRunner#runAndHandleErrors(String[])
*/

View File

@@ -20,6 +20,7 @@ package org.springframework.boot.cli.command;
* Exception used to when the help command is called without arguments.
*
* @author Phillip Webb
* @since 1.0.0
*/
public class NoHelpCommandArgumentsException extends CommandException {

View File

@@ -20,6 +20,7 @@ package org.springframework.boot.cli.command;
* Exception used when a command is not found.
*
* @author Phillip Webb
* @since 1.0.0
*/
public class NoSuchCommandException extends CommandException {

View File

@@ -27,6 +27,7 @@ import org.springframework.boot.cli.command.status.ExitStatus;
*
* @author Phillip Webb
* @author Dave Syer
* @since 1.0.0
* @see OptionHandler
*/
public abstract class OptionParsingCommand extends AbstractCommand {

View File

@@ -27,6 +27,7 @@ import org.springframework.boot.loader.tools.LibraryScope;
*
* @author Andy Wilkinson
* @author Phillip Webb
* @since 1.3.0
*/
public class JarCommand extends ArchiveCommand {

View File

@@ -36,6 +36,7 @@ import org.springframework.boot.cli.util.Log;
* Internal {@link Command} used for 'help' requests.
*
* @author Phillip Webb
* @since 1.0.0
*/
public class HelpCommand extends AbstractCommand {

View File

@@ -32,6 +32,7 @@ import org.springframework.boot.cli.util.Log;
* called with the current index followed by a list of arguments already typed.
*
* @author Phillip Webb
* @since 1.0.0
*/
public class HintCommand extends AbstractCommand {

View File

@@ -25,6 +25,7 @@ import org.springframework.boot.cli.util.Log;
* {@link Command} to display the 'version' number.
*
* @author Phillip Webb
* @since 1.0.0
*/
public class VersionCommand extends AbstractCommand {

View File

@@ -35,6 +35,7 @@ import org.springframework.boot.cli.compiler.grape.RepositoryConfiguration;
* {@link Command} to grab the dependencies of one or more Groovy scripts.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
public class GrabCommand extends OptionParsingCommand {

View File

@@ -20,7 +20,6 @@ package org.springframework.boot.cli.command.init;
* Provide some basic information about a dependency.
*
* @author Stephane Nicoll
* @since 1.2.0
*/
final class Dependency {

View File

@@ -42,7 +42,6 @@ import org.springframework.util.StringUtils;
* Invokes the initializr service over HTTP.
*
* @author Stephane Nicoll
* @since 1.2.0
*/
class InitializrService {

View File

@@ -30,7 +30,6 @@ import org.json.JSONObject;
* Define the metadata available for a particular service instance.
*
* @author Stephane Nicoll
* @since 1.2.0
*/
class InitializrServiceMetadata {

View File

@@ -32,7 +32,6 @@ import org.springframework.util.StringUtils;
*
* @author Stephane Nicoll
* @author Eddú Meléndez
* @since 1.2.0
*/
class ProjectGenerationRequest {

View File

@@ -22,7 +22,6 @@ import org.apache.http.entity.ContentType;
* Represent the response of a {@link ProjectGenerationRequest}.
*
* @author Stephane Nicoll
* @since 1.2.0
*/
class ProjectGenerationResponse {

View File

@@ -24,7 +24,6 @@ import java.util.Map;
* Represent a project type that is supported by a service.
*
* @author Stephane Nicoll
* @since 1.2.0
*/
class ProjectType {

View File

@@ -32,7 +32,6 @@ import java.util.TreeSet;
*
* @author Stephane Nicoll
* @author Andy Wilkinson
* @since 1.2.0
*/
class ServiceCapabilitiesReportGenerator {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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,7 +24,6 @@ import java.util.List;
* to {@link File}s.
*
* @author Andy Wilkinson
* @since 1.2.0
*/
@FunctionalInterface
interface DependencyResolver {

View File

@@ -26,6 +26,7 @@ import joptsimple.OptionSpec;
*
* @author Andy Wilkinson
* @author Dave Syer
* @since 1.0.0
*/
public class CompilerOptionHandler extends OptionHandler {

View File

@@ -43,6 +43,7 @@ import org.springframework.boot.cli.command.status.ExitStatus;
* Delegate used by {@link OptionParsingCommand} to parse options and run the command.
*
* @author Dave Syer
* @since 1.0.0
* @see OptionParsingCommand
* @see #run(OptionSet)
*/

View File

@@ -22,6 +22,7 @@ import java.util.Set;
* Help for a specific option.
*
* @author Phillip Webb
* @since 1.0.0
*/
public interface OptionHelp {

View File

@@ -31,6 +31,7 @@ import org.springframework.boot.cli.compiler.grape.RepositoryConfiguration;
* {@link GroovyCompilerConfiguration}.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
public class OptionSetGroovyCompilerConfiguration implements GroovyCompilerConfiguration {

View File

@@ -34,6 +34,7 @@ import org.springframework.util.StringUtils;
* @author Dave Syer
* @author Greg Turnquist
* @author Andy Wilkinson
* @since 1.0.0
*/
public class SourceOptions {

View File

@@ -40,6 +40,7 @@ import org.springframework.boot.cli.compiler.grape.RepositoryConfiguration;
* @author Phillip Webb
* @author Dave Syer
* @author Andy Wilkinson
* @since 1.0.0
* @see SpringApplicationRunner
*/
public class RunCommand extends OptionParsingCommand {

View File

@@ -38,6 +38,7 @@ import org.springframework.boot.cli.util.ResourceUtils;
*
* @author Phillip Webb
* @author Dave Syer
* @since 1.0.0
*/
public class SpringApplicationRunner {

View File

@@ -24,6 +24,7 @@ import org.springframework.boot.cli.compiler.GroovyCompilerConfiguration;
* Configuration for the {@link SpringApplicationRunner}.
*
* @author Phillip Webb
* @since 1.0.0
*/
public interface SpringApplicationRunnerConfiguration extends GroovyCompilerConfiguration {

View File

@@ -39,6 +39,7 @@ import org.springframework.boot.cli.util.Log;
*
* @author Jon Brisbin
* @author Phillip Webb
* @since 1.0.0
*/
public class CommandCompleter extends StringsCompleter {

View File

@@ -24,6 +24,7 @@ import org.springframework.boot.cli.command.status.ExitStatus;
* {@link Command} to change the {@link Shell} prompt.
*
* @author Dave Syer
* @since 1.0.0
*/
public class PromptCommand extends AbstractCommand {

View File

@@ -45,6 +45,7 @@ import org.springframework.util.StringUtils;
* @author Jon Brisbin
* @author Dave Syer
* @author Phillip Webb
* @since 1.0.0
*/
public class Shell {

View File

@@ -24,6 +24,7 @@ import org.springframework.boot.cli.command.status.ExitStatus;
* {@link Command} to start a nested REPL shell.
*
* @author Phillip Webb
* @since 1.0.0
* @see Shell
*/
public class ShellCommand extends AbstractCommand {

View File

@@ -22,6 +22,7 @@ import org.springframework.boot.cli.command.CommandException;
* Exception used to stop the {@link Shell}.
*
* @author Phillip Webb
* @since 1.0.0
*/
public class ShellExitException extends CommandException {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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.
@@ -23,6 +23,7 @@ import java.util.Deque;
* Abstraction to manage a stack of prompts.
*
* @author Phillip Webb
* @since 1.0.0
*/
public class ShellPrompts {

View File

@@ -20,9 +20,9 @@ package org.springframework.boot.cli.command.status;
* Encapsulation of the outcome of a command.
*
* @author Dave Syer
* @since 1.0.0
* @see ExitStatus#OK
* @see ExitStatus#ERROR
*
*/
public final class ExitStatus {

View File

@@ -44,6 +44,7 @@ import org.springframework.util.PatternMatchUtils;
* @author Phillip Webb
* @author Dave Syer
* @author Greg Turnquist
* @since 1.0.0
*/
public abstract class AstUtils {

View File

@@ -29,6 +29,7 @@ import org.codehaus.groovy.control.customizers.ImportCustomizer;
* {@link CompilePhase#CONVERSION} Groovy compile phase.
*
* @author Phillip Webb
* @since 1.0.0
*/
public abstract class CompilerAutoConfiguration {

View File

@@ -34,6 +34,7 @@ import org.springframework.core.annotation.Order;
* @author Phillip Webb
* @author Dave Syer
* @author Andy Wilkinson
* @since 1.0.0
*/
@Order(DependencyAutoConfigurationTransformation.ORDER)
public class DependencyAutoConfigurationTransformation implements ASTTransformation {

View File

@@ -36,6 +36,7 @@ import org.springframework.boot.cli.compiler.grape.DependencyResolutionContext;
*
* @author Phillip Webb
* @author Andy Wilkinson
* @since 1.0.0
*/
public class DependencyCustomizer {

View File

@@ -46,6 +46,7 @@ import org.springframework.util.StringUtils;
*
* @author Phillip Webb
* @author Dave Syer
* @since 1.0.0
*/
public class ExtendedGroovyClassLoader extends GroovyClassLoader {

View File

@@ -39,6 +39,7 @@ import org.springframework.core.annotation.Order;
* interface.
*
* @author Dave Syer
* @since 1.0.0
*/
@Order(GroovyBeansTransformation.ORDER)
public class GroovyBeansTransformation implements ASTTransformation {

View File

@@ -71,6 +71,7 @@ import org.springframework.util.ClassUtils;
* @author Phillip Webb
* @author Dave Syer
* @author Andy Wilkinson
* @since 1.0.0
*/
public class GroovyCompiler {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2017 the original author or authors.
* Copyright 2012-2019 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,6 +25,7 @@ import org.springframework.boot.cli.compiler.grape.RepositoryConfiguration;
*
* @author Phillip Webb
* @author Andy Wilkinson
* @since 1.0.0
*/
public interface GroovyCompilerConfiguration {

View File

@@ -20,6 +20,7 @@ package org.springframework.boot.cli.compiler;
* The scope in which a groovy compiler operates.
*
* @author Phillip Webb
* @since 1.0.0
*/
public enum GroovyCompilerScope {

View File

@@ -38,6 +38,7 @@ import org.springframework.util.StringUtils;
*
* @author Andy Wilkinson
* @author Dave Syer
* @since 1.0.0
*/
public final class RepositoryConfigurationFactory {

View File

@@ -36,6 +36,7 @@ import org.springframework.core.annotation.Order;
*
* @author Andy Wilkinson
* @author Phillip Webb
* @since 1.0.0
*/
@Order(ResolveDependencyCoordinatesTransformation.ORDER)
public class ResolveDependencyCoordinatesTransformation extends AnnotatedNodeASTTransformation {

View File

@@ -25,7 +25,6 @@ import org.codehaus.groovy.control.customizers.ImportCustomizer;
* class with the same name is not already explicitly imported.
*
* @author Dave Syer
* @since 1.1
*/
class SmartImportCustomizer extends ImportCustomizer {

View File

@@ -23,6 +23,7 @@ import org.codehaus.groovy.transform.ASTTransformation;
* {@code META-INF/services}.
*
* @author Dave Syer
* @since 1.0.0
*/
@FunctionalInterface
public interface SpringBootAstTransformation extends ASTTransformation {

View File

@@ -27,6 +27,7 @@ import org.springframework.boot.cli.compiler.DependencyCustomizer;
* {@link CompilerAutoConfiguration} for Spring JDBC.
*
* @author Dave Syer
* @since 1.0.0
*/
public class JdbcCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -29,6 +29,7 @@ import org.springframework.boot.cli.compiler.DependencyCustomizer;
*
* @author Greg Turnquist
* @author Stephane Nicoll
* @since 1.0.0
*/
public class JmsCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -29,6 +29,7 @@ import org.springframework.boot.cli.compiler.DependencyCustomizer;
*
* @author Greg Turnquist
* @author Stephane Nicoll
* @since 1.0.0
*/
public class RabbitCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -28,6 +28,7 @@ import org.springframework.boot.cli.compiler.DependencyCustomizer;
*
* @author Dave Syer
* @author Phillip Webb
* @since 1.0.0
*/
public class SpringBatchCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -34,6 +34,7 @@ import org.springframework.boot.cli.compiler.GroovyCompilerConfiguration;
*
* @author Dave Syer
* @author Phillip Webb
* @since 1.0.0
*/
public class SpringBootCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -28,6 +28,7 @@ import org.springframework.boot.cli.compiler.DependencyCustomizer;
*
* @author Dave Syer
* @author Artem Bilan
* @since 1.0.0
*/
public class SpringIntegrationCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -29,6 +29,7 @@ import org.springframework.boot.groovy.GroovyTemplate;
*
* @author Dave Syer
* @author Phillip Webb
* @since 1.0.0
*/
public class SpringMvcCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -27,6 +27,7 @@ import org.springframework.boot.cli.compiler.DependencyCustomizer;
* {@link CompilerAutoConfiguration} for Spring Security.
*
* @author Dave Syer
* @since 1.0.0
*/
public class SpringSecurityCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -27,6 +27,7 @@ import org.springframework.boot.cli.compiler.DependencyCustomizer;
* {@link CompilerAutoConfiguration} for Spring Websocket.
*
* @author Dave Syer
* @since 1.0.0
*/
public class SpringWebsocketCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -28,6 +28,7 @@ import org.springframework.boot.cli.compiler.DependencyCustomizer;
*
* @author Dave Syer
* @author Phillip Webb
* @since 1.0.0
*/
public class TransactionManagementCompilerAutoConfiguration extends CompilerAutoConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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,6 +25,7 @@ package org.springframework.boot.cli.compiler.dependencies;
* metadata to resolve the groupId and version.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
public interface ArtifactCoordinatesResolver {

View File

@@ -24,6 +24,7 @@ import org.springframework.util.StringUtils;
*
* @author Phillip Webb
* @author Andy Wilkinson
* @since 1.0.0
*/
public class DependencyManagementArtifactCoordinatesResolver implements ArtifactCoordinatesResolver {

View File

@@ -49,6 +49,7 @@ import org.eclipse.aether.util.filter.DependencyFilterUtils;
*
* @author Andy Wilkinson
* @author Phillip Webb
* @since 1.0.0
*/
@SuppressWarnings("rawtypes")
public class AetherGrapeEngine implements GrapeEngine {

View File

@@ -39,6 +39,7 @@ import org.eclipse.aether.transport.http.HttpTransporterFactory;
* Utility class to create a pre-configured {@link AetherGrapeEngine}.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
public abstract class AetherGrapeEngineFactory {

View File

@@ -33,6 +33,7 @@ import org.springframework.util.StringUtils;
* configuration, applies sensible defaults.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
public class DefaultRepositorySystemSessionAutoConfiguration implements RepositorySystemSessionAutoConfiguration {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2018 the original author or authors.
* Copyright 2012-2019 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,6 +20,7 @@ package org.springframework.boot.cli.compiler.grape;
* Thrown to indicate a failure during dependency resolution.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
@SuppressWarnings("serial")
public class DependencyResolutionFailedException extends RuntimeException {

View File

@@ -25,6 +25,7 @@ import groovy.grape.GrapeEngine;
* Utility to install a specific {@link Grape} engine with Groovy.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
public abstract class GrapeEngineInstaller {

View File

@@ -24,6 +24,7 @@ import org.springframework.util.ObjectUtils;
* The configuration of a repository.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
public final class RepositoryConfiguration {

View File

@@ -24,6 +24,7 @@ import org.eclipse.aether.RepositorySystem;
* an {@link AetherGrapeEngine}.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
@FunctionalInterface
public interface RepositorySystemSessionAutoConfiguration {

View File

@@ -28,6 +28,7 @@ import org.springframework.boot.cli.compiler.maven.MavenSettingsReader;
* determine the configuration settings.
*
* @author Andy Wilkinson
* @since 1.0.0
*/
public class SettingsXmlRepositorySystemSessionAutoConfiguration implements RepositorySystemSessionAutoConfiguration {

View File

@@ -20,6 +20,7 @@ package org.springframework.boot.cli.util;
* Simple logger used by the CLI.
*
* @author Phillip Webb
* @since 1.0.0
*/
public abstract class Log {

View File

@@ -39,6 +39,7 @@ import org.springframework.util.StringUtils;
*
* @author Dave Syer
* @author Phillip Webb
* @since 1.0.0
*/
public abstract class ResourceUtils {

View File

@@ -33,6 +33,7 @@ import org.codehaus.groovy.control.CompilationFailedException;
* Helpful utilities for working with Groovy {@link Template}s.
*
* @author Dave Syer
* @since 1.0.0
*/
public abstract class GroovyTemplate {