diff --git a/pom.xml b/pom.xml index 3688725..c978d1a 100644 --- a/pom.xml +++ b/pom.xml @@ -13,7 +13,14 @@ io.dropwizard dropwizard-bom - ${project.version} + 2.1.12 + pom + import + + + io.dropwizard + dropwizard-dependencies + 2.1.12 pom import @@ -71,6 +78,18 @@ mockito-core test + + junit + junit + 4.13.2 + test + + + org.junit.vintage + junit-vintage-engine + 5.10.1 + test + org.glassfish.jersey.test-framework.providers jersey-test-framework-provider-inmemory @@ -119,7 +138,7 @@ org.apache.maven.plugins maven-surefire-plugin - 2.19.1 + 3.2.5 org.apache.maven.plugins @@ -134,7 +153,7 @@ org.apache.maven.plugins maven-compiler-plugin - 3.6.0 + 3.13.0 org.apache.maven.plugins @@ -149,7 +168,7 @@ org.apache.maven.plugins maven-shade-plugin - 2.4.3 + 3.6.0 org.apache.maven.plugins @@ -216,6 +235,7 @@ META-INF/*.SF META-INF/*.DSA META-INF/*.RSA + module-info.class @@ -239,8 +259,7 @@ org.apache.maven.plugins maven-compiler-plugin - 1.6 - 1.6 + 11 diff --git a/src/main/java/com/dropwizard/employee/EmployeeConfiguration.java b/src/main/java/com/dropwizard/employee/EmployeeConfiguration.java index 9a8e28f..f16b57d 100644 --- a/src/main/java/com/dropwizard/employee/EmployeeConfiguration.java +++ b/src/main/java/com/dropwizard/employee/EmployeeConfiguration.java @@ -3,7 +3,7 @@ import com.fasterxml.jackson.annotation.JsonProperty; import io.dropwizard.Configuration; import io.dropwizard.db.DataSourceFactory; -import org.hibernate.validator.constraints.NotEmpty; +import javax.validation.constraints.NotEmpty; import com.dropwizard.employee.core.Template; import javax.validation.Valid; diff --git a/src/main/java/com/dropwizard/employee/db/EmployeeDAO.java b/src/main/java/com/dropwizard/employee/db/EmployeeDAO.java index 203bdc2..8695ca5 100644 --- a/src/main/java/com/dropwizard/employee/db/EmployeeDAO.java +++ b/src/main/java/com/dropwizard/employee/db/EmployeeDAO.java @@ -21,7 +21,8 @@ public Employee create(Employee person) { return persist(person); } + @SuppressWarnings("unchecked") public List findAll() { - return list(namedQuery("com.dropwizard.employee.core.Employee.findAll")); + return list((org.hibernate.query.Query) namedQuery("com.dropwizard.employee.core.Employee.findAll")); } }