JAVA-117 Standardize spring-boot-modules/spring-boot

This commit is contained in:
mikr
2020-04-04 20:24:48 +02:00
parent 1699e86ef9
commit 487d6b38fc
49 changed files with 93 additions and 91 deletions
@@ -1,4 +1,4 @@
package org.baeldung.boot;
package com.baeldung.boot;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@@ -1,4 +1,4 @@
package org.baeldung.boot.config;
package com.baeldung.boot.config;
import java.util.Properties;
@@ -18,7 +18,7 @@ import org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter;
import org.springframework.transaction.annotation.EnableTransactionManagement;
@Configuration
@EnableJpaRepositories(basePackages = { "org.baeldung.boot.repository", "org.baeldung.boot.boottest", "org.baeldung.repository" })
@EnableJpaRepositories(basePackages = { "com.baeldung.boot.repository", "com.baeldung.boot.boottest", "com.baeldung.repository" })
@PropertySource("classpath:persistence-generic-entity.properties")
@EnableTransactionManagement
public class H2JpaConfig {
@@ -41,7 +41,7 @@ public class H2JpaConfig {
public LocalContainerEntityManagerFactoryBean entityManagerFactory() {
final LocalContainerEntityManagerFactoryBean em = new LocalContainerEntityManagerFactoryBean();
em.setDataSource(dataSource());
em.setPackagesToScan(new String[] { "org.baeldung.boot.domain", "org.baeldung.boot.model", "org.baeldung.boot.boottest", "org.baeldung.model" });
em.setPackagesToScan(new String[] { "com.baeldung.boot.domain", "com.baeldung.boot.model", "com.baeldung.boot.boottest", "com.baeldung.model" });
em.setJpaVendorAdapter(new HibernateJpaVendorAdapter());
em.setJpaProperties(additionalProperties());
return em;
@@ -1,8 +1,8 @@
package org.baeldung.boot.config;
package com.baeldung.boot.config;
import org.baeldung.boot.converter.StringToEmployeeConverter;
import org.baeldung.boot.converter.StringToEnumConverterFactory;
import org.baeldung.boot.converter.GenericBigDecimalConverter;
import com.baeldung.boot.converter.StringToEmployeeConverter;
import com.baeldung.boot.converter.StringToEnumConverterFactory;
import com.baeldung.boot.converter.GenericBigDecimalConverter;
import org.springframework.context.annotation.Configuration;
import org.springframework.format.FormatterRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
@@ -1,4 +1,4 @@
package org.baeldung.boot.controller.servlet;
package com.baeldung.boot.controller.servlet;
import java.io.IOException;
import java.io.PrintWriter;
@@ -1,4 +1,4 @@
package org.baeldung.boot.controller.servlet;
package com.baeldung.boot.controller.servlet;
import java.io.IOException;
import java.io.PrintWriter;
@@ -1,4 +1,4 @@
package org.baeldung.boot.converter;
package com.baeldung.boot.converter;
import com.google.common.collect.ImmutableSet;
import org.springframework.core.convert.TypeDescriptor;
@@ -1,4 +1,4 @@
package org.baeldung.boot.converter;
package com.baeldung.boot.converter;
import org.springframework.core.convert.converter.Converter;
@@ -1,4 +1,4 @@
package org.baeldung.boot.converter;
package com.baeldung.boot.converter;
import org.springframework.core.convert.converter.Converter;
import org.springframework.core.convert.converter.ConverterFactory;
@@ -1,4 +1,4 @@
package org.baeldung.boot.converter.controller;
package com.baeldung.boot.converter.controller;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
@@ -1,4 +1,4 @@
package org.baeldung.boot.domain;
package com.baeldung.boot.domain;
public enum Modes {
@@ -1,4 +1,4 @@
package org.baeldung.common.error;
package com.baeldung.common.error;
import org.springframework.boot.web.servlet.error.ErrorController;
import org.springframework.web.bind.annotation.GetMapping;
@@ -1,4 +1,4 @@
package org.baeldung.common.error;
package com.baeldung.common.error;
import org.springframework.boot.web.servlet.ServletRegistrationBean;
@@ -1,4 +1,4 @@
package org.baeldung.common.error.controller;
package com.baeldung.common.error.controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
@@ -1,4 +1,4 @@
package org.baeldung.common.properties;
package com.baeldung.common.properties;
import org.springframework.boot.web.server.ErrorPage;
import org.springframework.boot.web.server.WebServerFactoryCustomizer;
@@ -1,4 +1,4 @@
package org.baeldung.common.resources;
package com.baeldung.common.resources;
import org.springframework.boot.ExitCodeGenerator;
@@ -1,4 +1,4 @@
package org.baeldung.demo;
package com.baeldung.demo;
import com.baeldung.graphql.GraphqlConfiguration;
import org.springframework.boot.SpringApplication;
@@ -1,4 +1,4 @@
package org.baeldung.demo.boottest;
package com.baeldung.demo.boottest;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
@@ -1,4 +1,4 @@
package org.baeldung.demo.boottest;
package com.baeldung.demo.boottest;
import java.util.List;
@@ -1,4 +1,4 @@
package org.baeldung.demo.boottest;
package com.baeldung.demo.boottest;
import java.util.List;
@@ -1,4 +1,4 @@
package org.baeldung.demo.boottest;
package com.baeldung.demo.boottest;
import java.util.List;
@@ -1,4 +1,4 @@
package org.baeldung.demo.boottest;
package com.baeldung.demo.boottest;
import java.util.List;
@@ -1,7 +1,7 @@
package org.baeldung.demo.components;
package com.baeldung.demo.components;
import org.baeldung.demo.model.Foo;
import org.baeldung.demo.repository.FooRepository;
import com.baeldung.demo.model.Foo;
import com.baeldung.demo.repository.FooRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@@ -1,4 +1,4 @@
package org.baeldung.demo.exceptions;
package com.baeldung.demo.exceptions;
public class CommonException extends RuntimeException {
@@ -1,4 +1,4 @@
package org.baeldung.demo.exceptions;
package com.baeldung.demo.exceptions;
public class FooNotFoundException extends RuntimeException {
@@ -1,4 +1,4 @@
package org.baeldung.demo.model;
package com.baeldung.demo.model;
import java.io.Serializable;
@@ -1,6 +1,6 @@
package org.baeldung.demo.repository;
package com.baeldung.demo.repository;
import org.baeldung.demo.model.Foo;
import com.baeldung.demo.model.Foo;
import org.springframework.data.jpa.repository.JpaRepository;
public interface FooRepository extends JpaRepository<Foo, Integer> {
@@ -1,7 +1,7 @@
package org.baeldung.demo.service;
package com.baeldung.demo.service;
import org.baeldung.demo.components.FooService;
import org.baeldung.demo.model.Foo;
import com.baeldung.demo.model.Foo;
import com.baeldung.demo.components.FooService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
@@ -1,9 +1,9 @@
package org.baeldung.endpoints.info;
package com.baeldung.endpoints.info;
import java.util.HashMap;
import java.util.Map;
import org.baeldung.repository.UserRepository;
import com.baeldung.repository.UserRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.actuate.info.Info;
import org.springframework.boot.actuate.info.InfoContributor;
@@ -1,9 +1,9 @@
package org.baeldung.main;
package com.baeldung.main;
import org.baeldung.boot.controller.servlet.HelloWorldServlet;
import org.baeldung.boot.controller.servlet.SpringHelloWorldServlet;
import org.baeldung.common.error.SpringHelloServletRegistrationBean;
import org.baeldung.common.resources.ExecutorServiceExitCodeGenerator;
import com.baeldung.boot.controller.servlet.HelloWorldServlet;
import com.baeldung.boot.controller.servlet.SpringHelloWorldServlet;
import com.baeldung.common.error.SpringHelloServletRegistrationBean;
import com.baeldung.common.resources.ExecutorServiceExitCodeGenerator;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
@@ -18,7 +18,7 @@ import java.util.concurrent.Executors;
@RestController
@EnableAutoConfiguration
@ComponentScan({ "org.baeldung.common.error", "org.baeldung.common.error.controller", "org.baeldung.common.properties", "org.baeldung.common.resources", "org.baeldung.endpoints", "org.baeldung.service", "org.baeldung.monitor.jmx", "org.baeldung.boot.config" })
@ComponentScan({ "org.baeldung.common.error", "com.baeldung.common.error.controller", "com.baeldung.common.properties", "com.baeldung.common.resources", "com.baeldung.endpoints", "com.baeldung.service", "com.baeldung.monitor.jmx", "com.baeldung.boot.config" })
public class SpringBootApplication {
private static ApplicationContext applicationContext;
@@ -1,4 +1,4 @@
package org.baeldung.model;
package com.baeldung.model;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;

Some files were not shown because too many files have changed in this diff Show More