diff --git a/.idea/libraries/Maven__antlr_antlr_2_7_7.xml b/.idea/libraries/Maven__antlr_antlr_2_7_7.xml
new file mode 100644
index 0000000..b8d93d8
--- /dev/null
+++ b/.idea/libraries/Maven__antlr_antlr_2_7_7.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__dom4j_dom4j_1_6_1.xml b/.idea/libraries/Maven__dom4j_dom4j_1_6_1.xml
new file mode 100644
index 0000000..14681ee
--- /dev/null
+++ b/.idea/libraries/Maven__dom4j_dom4j_1_6_1.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__javax_transaction_javax_transaction_api_1_2.xml b/.idea/libraries/Maven__javax_transaction_javax_transaction_api_1_2.xml
new file mode 100644
index 0000000..5f032d2
--- /dev/null
+++ b/.idea/libraries/Maven__javax_transaction_javax_transaction_api_1_2.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__log4j_log4j_1_2_17.xml b/.idea/libraries/Maven__log4j_log4j_1_2_17.xml
deleted file mode 100644
index e383c1b..0000000
--- a/.idea/libraries/Maven__log4j_log4j_1_2_17.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_apache_tomcat_tomcat_jdbc_8_5_23.xml b/.idea/libraries/Maven__org_apache_tomcat_tomcat_jdbc_8_5_23.xml
new file mode 100644
index 0000000..38b86a3
--- /dev/null
+++ b/.idea/libraries/Maven__org_apache_tomcat_tomcat_jdbc_8_5_23.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_apache_tomcat_tomcat_juli_8_5_23.xml b/.idea/libraries/Maven__org_apache_tomcat_tomcat_juli_8_5_23.xml
new file mode 100644
index 0000000..a9350c3
--- /dev/null
+++ b/.idea/libraries/Maven__org_apache_tomcat_tomcat_juli_8_5_23.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_aspectj_aspectjweaver_1_8_13.xml b/.idea/libraries/Maven__org_aspectj_aspectjweaver_1_8_13.xml
new file mode 100644
index 0000000..d46e30a
--- /dev/null
+++ b/.idea/libraries/Maven__org_aspectj_aspectjweaver_1_8_13.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_atteo_evo_inflector_1_2_2.xml b/.idea/libraries/Maven__org_atteo_evo_inflector_1_2_2.xml
new file mode 100644
index 0000000..2dde355
--- /dev/null
+++ b/.idea/libraries/Maven__org_atteo_evo_inflector_1_2_2.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_hibernate_common_hibernate_commons_annotations_5_0_1_Final.xml b/.idea/libraries/Maven__org_hibernate_common_hibernate_commons_annotations_5_0_1_Final.xml
new file mode 100644
index 0000000..ce34f42
--- /dev/null
+++ b/.idea/libraries/Maven__org_hibernate_common_hibernate_commons_annotations_5_0_1_Final.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_hibernate_hibernate_core_5_0_12_Final.xml b/.idea/libraries/Maven__org_hibernate_hibernate_core_5_0_12_Final.xml
new file mode 100644
index 0000000..34893a4
--- /dev/null
+++ b/.idea/libraries/Maven__org_hibernate_hibernate_core_5_0_12_Final.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_hibernate_hibernate_entitymanager_5_0_12_Final.xml b/.idea/libraries/Maven__org_hibernate_hibernate_entitymanager_5_0_12_Final.xml
new file mode 100644
index 0000000..27dda1e
--- /dev/null
+++ b/.idea/libraries/Maven__org_hibernate_hibernate_entitymanager_5_0_12_Final.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_hibernate_javax_persistence_hibernate_jpa_2_1_api_1_0_0_Final.xml b/.idea/libraries/Maven__org_hibernate_javax_persistence_hibernate_jpa_2_1_api_1_0_0_Final.xml
new file mode 100644
index 0000000..6492b2b
--- /dev/null
+++ b/.idea/libraries/Maven__org_hibernate_javax_persistence_hibernate_jpa_2_1_api_1_0_0_Final.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_javassist_javassist_3_21_0_GA.xml b/.idea/libraries/Maven__org_javassist_javassist_3_21_0_GA.xml
new file mode 100644
index 0000000..09c4cf0
--- /dev/null
+++ b/.idea/libraries/Maven__org_javassist_javassist_3_21_0_GA.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_jboss_jandex_2_0_0_Final.xml b/.idea/libraries/Maven__org_jboss_jandex_2_0_0_Final.xml
new file mode 100644
index 0000000..a74dcfd
--- /dev/null
+++ b/.idea/libraries/Maven__org_jboss_jandex_2_0_0_Final.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_aop_1_5_9_RELEASE.xml b/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_aop_1_5_9_RELEASE.xml
new file mode 100644
index 0000000..2932fb5
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_aop_1_5_9_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_data_jpa_1_5_9_RELEASE.xml b/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_data_jpa_1_5_9_RELEASE.xml
new file mode 100644
index 0000000..adc9680
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_data_jpa_1_5_9_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_jdbc_1_5_9_RELEASE.xml b/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_jdbc_1_5_9_RELEASE.xml
new file mode 100644
index 0000000..338299a
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_jdbc_1_5_9_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_data_spring_data_commons_2_0_2_RELEASE.xml b/.idea/libraries/Maven__org_springframework_data_spring_data_commons_2_0_2_RELEASE.xml
new file mode 100644
index 0000000..3f1bdbc
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_data_spring_data_commons_2_0_2_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_data_spring_data_jpa_1_11_9_RELEASE.xml b/.idea/libraries/Maven__org_springframework_data_spring_data_jpa_1_11_9_RELEASE.xml
new file mode 100644
index 0000000..3f35534
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_data_spring_data_jpa_1_11_9_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_data_spring_data_rest_core_2_6_9_RELEASE.xml b/.idea/libraries/Maven__org_springframework_data_spring_data_rest_core_2_6_9_RELEASE.xml
new file mode 100644
index 0000000..3816e08
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_data_spring_data_rest_core_2_6_9_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_hateoas_spring_hateoas_0_23_0_RELEASE.xml b/.idea/libraries/Maven__org_springframework_hateoas_spring_hateoas_0_23_0_RELEASE.xml
new file mode 100644
index 0000000..92e7f9f
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_hateoas_spring_hateoas_0_23_0_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_plugin_spring_plugin_core_1_2_0_RELEASE.xml b/.idea/libraries/Maven__org_springframework_plugin_spring_plugin_core_1_2_0_RELEASE.xml
new file mode 100644
index 0000000..fbc0452
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_plugin_spring_plugin_core_1_2_0_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_spring_aspects_4_3_13_RELEASE.xml b/.idea/libraries/Maven__org_springframework_spring_aspects_4_3_13_RELEASE.xml
new file mode 100644
index 0000000..2d53c11
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_spring_aspects_4_3_13_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_spring_jdbc_4_3_13_RELEASE.xml b/.idea/libraries/Maven__org_springframework_spring_jdbc_4_3_13_RELEASE.xml
new file mode 100644
index 0000000..49da486
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_spring_jdbc_4_3_13_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_spring_orm_4_3_13_RELEASE.xml b/.idea/libraries/Maven__org_springframework_spring_orm_4_3_13_RELEASE.xml
new file mode 100644
index 0000000..354d247
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_spring_orm_4_3_13_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/Maven__org_springframework_spring_tx_4_3_13_RELEASE.xml b/.idea/libraries/Maven__org_springframework_spring_tx_4_3_13_RELEASE.xml
new file mode 100644
index 0000000..d56e28f
--- /dev/null
+++ b/.idea/libraries/Maven__org_springframework_spring_tx_4_3_13_RELEASE.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 62e5898..eab6c50 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -2,7 +2,42 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -75,13 +110,16 @@
+
+
+
-
-
+
+
@@ -90,22 +128,12 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
@@ -114,43 +142,53 @@
-
-
+
+
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -162,6 +200,7 @@
@@ -178,13 +217,13 @@
+
-
-
+
@@ -217,6 +256,34 @@
+
+
+
+
+
+
+
+
+ Encapsulation issuesJava
+
+
+ Inheritance issuesJava
+
+
+ Java
+
+
+ Security issuesJava
+
+
+
+
+ Ant inspections
+
+
+
+
+
@@ -273,12 +340,16 @@
+
+
+
+
-
+
@@ -286,8 +357,10 @@
-
+
+
+
@@ -301,7 +374,7 @@
-
+
@@ -323,6 +396,20 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -343,12 +430,6 @@
-
-
-
-
-
-
@@ -383,24 +464,19 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
@@ -452,20 +528,21 @@
-
+
-
+
-
-
-
+
+
+
+
-
+
-
+
@@ -532,6 +609,160 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -546,6 +777,8 @@
+
+
@@ -555,7 +788,10 @@
-
+
+
+
+
@@ -574,6 +810,8 @@
+
+
@@ -583,96 +821,132 @@
-
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/pom.xml b/pom.xml
index 7a9c601..2f344f8 100644
--- a/pom.xml
+++ b/pom.xml
@@ -79,16 +79,34 @@
spring-boot-starter-test
test
+
+ org.springframework.boot
+ spring-boot-starter-data-jpa
+
+
+ org.springframework.data
+ spring-data-commons
+ 2.0.2.RELEASE
+
com.jayway.jsonpath
json-path
test
- log4j
- log4j
- 1.2.17
+ org.springframework.boot
+ spring-boot
+ 1.5.9.RELEASE
+
+
+ org.springframework.data
+ spring-data-rest-core
+ 2.6.9.RELEASE
+
+
+ org.springframework.data
+ spring-data-rest-core
+ 2.6.9.RELEASE
-
\ No newline at end of file
diff --git a/restServer.iml b/restServer.iml
index 33e8243..04d65e2 100644
--- a/restServer.iml
+++ b/restServer.iml
@@ -13,12 +13,10 @@
-
-
@@ -32,12 +30,9 @@
-
-
-
@@ -53,11 +48,40 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/restServer.rest b/restServer.rest
new file mode 100644
index 0000000..e69de29
diff --git a/src/main/java/ru/cft/task/restServer/BookStatus.java b/src/main/java/ru/cft/task/restServer/BookStatus.java
deleted file mode 100644
index 57200a3..0000000
--- a/src/main/java/ru/cft/task/restServer/BookStatus.java
+++ /dev/null
@@ -1,31 +0,0 @@
-package ru.cft.task.restServer;
-
-public class BookStatus {
- private boolean status;
- private String message;
-
- public String getMessage() {
- return message;
- }
-
- public BookStatus setMessage(String message) {
- this.message = message;
- this.status = true;
- return this;
- }
-
- public BookStatus setError(String message) {
- this.message = message;
- this.status = false;
- return this;
- }
-
- public boolean isValid() {
- return status;
- }
-
- public void setStatus(boolean status) {
- this.status = status;
- }
-
-}
diff --git a/src/main/java/ru/cft/task/restServer/EmailBook.java b/src/main/java/ru/cft/task/restServer/EmailBook.java
index bee92fd..7d28f9b 100644
--- a/src/main/java/ru/cft/task/restServer/EmailBook.java
+++ b/src/main/java/ru/cft/task/restServer/EmailBook.java
@@ -1,35 +1,8 @@
package ru.cft.task.restServer;
-import java.util.HashMap;
+import org.springframework.data.repository.CrudRepository;
+import org.springframework.data.rest.core.annotation.RepositoryRestResource;
-public class EmailBook {
- private HashMap book;
- private BookStatus status;
-
- public EmailBook() {
- this.book = new HashMap();
- this.status.setStatus(true);
- }
-
- public BookStatus addRecord(EmailRecord rec) {
- if (!this.book.containsKey(rec.getId())) {
- this.book.put(rec.getId(), rec);
- return this.status.setMessage("Запись успешно добавлена");
- }else{
- return this.status.setError("Запись с таким id уже существует");
- }
- }
-
- public BookStatus removeRecord(Long id) {
- if (!this.book.containsKey(id)) {
- this.book.remove(id);
- return this.status.setMessage("Запись успешно удалена");
- }else{
- return this.status.setError("Записи с таким id не существует");
- }
- }
-
- public int count() {
- return this.book.size();
- }
+@RepositoryRestResource
+public interface EmailBook extends CrudRepository{
}
diff --git a/src/main/java/ru/cft/task/restServer/EmailBookController.java b/src/main/java/ru/cft/task/restServer/EmailBookController.java
index a53db99..82f6020 100644
--- a/src/main/java/ru/cft/task/restServer/EmailBookController.java
+++ b/src/main/java/ru/cft/task/restServer/EmailBookController.java
@@ -1,25 +1,34 @@
package ru.cft.task.restServer;
-import org.apache.log4j.Logger;
+import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
+
import java.util.concurrent.atomic.AtomicLong;
@RestController
public class EmailBookController {
- final static Logger log = Logger.getLogger(EmailBookController.class);
private final AtomicLong new_id = new AtomicLong();
- private EmailBook book = new EmailBook();
- @RequestMapping(value = "/email", method = RequestMethod.POST)
- public BookStatus emailRec(@RequestParam(value = "name", defaultValue = "John Unknown") String name,
- @RequestParam(value = "email", defaultValue = "john@unknown.ru") String email) {
+ @Autowired
+ private EmailBook emailBook;
+
+ @RequestMapping(method = RequestMethod.POST)
+ public EmailRecord addEmailRec(@RequestParam(value = "name", defaultValue = "John Unknown") String name,
+ @RequestParam(value = "email", defaultValue = "john@unknown.ru") String email) {
EmailRecord rec = new EmailRecord(new_id.incrementAndGet(), name, email);
- return this.book.addRecord(rec);
+ return rec;
}
- //@RequestMapping(value = "/email", method = RequestMethod.DELETE)
- //public em
+ @RequestMapping(method = RequestMethod.DELETE)
+ public boolean removeEmailRec(@RequestParam(value = "id", required = true) Long id) {
+ return true;
+ }
+
+ @RequestMapping(method = RequestMethod.GET)
+ public int sizeBook() {
+ return 1;
+ }
}
diff --git a/src/main/java/ru/cft/task/restServer/EmailRecord.java b/src/main/java/ru/cft/task/restServer/EmailRecord.java
index 0347a59..1bcedb9 100644
--- a/src/main/java/ru/cft/task/restServer/EmailRecord.java
+++ b/src/main/java/ru/cft/task/restServer/EmailRecord.java
@@ -1,14 +1,32 @@
package ru.cft.task.restServer;
+import javax.persistence.Column;
+import javax.persistence.Entity;
+import javax.persistence.GeneratedValue;
+import javax.persistence.Id;
+
+@Entity
public class EmailRecord {
+ @Id
+ @GeneratedValue
+ @Column(name = "id")
private long id;
+
+ @Column(name = "name")
private String name;
+
+ @Column(name = "email")
private String email;
+ public EmailRecord() {
+ super();
+ }
+
public EmailRecord(long id, String name, String email) {
- setId(id);
- setName(name);
- setEmail(email);
+ super();
+ this.id = id;
+ this.name = name;
+ this.email = email;
}
public long getId() {
@@ -35,7 +53,8 @@ public class EmailRecord {
this.email = email;
}
+ @Override
public String toString() {
- return String.valueOf(getId()).concat(": ").concat(getName()).concat(" - ").concat(getEmail());
+ return "Rec[" + id + "]: " + name + "<" + email + ">";
}
}
diff --git a/src/main/java/ru/cft/task/restServer/Main.java b/src/main/java/ru/cft/task/restServer/Main.java
index 47832e2..18b390a 100644
--- a/src/main/java/ru/cft/task/restServer/Main.java
+++ b/src/main/java/ru/cft/task/restServer/Main.java
@@ -1,15 +1,12 @@
package ru.cft.task.restServer;
-import org.apache.log4j.Logger;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class Main {
- final static Logger log = Logger.getLogger(Main.class);
public static void main(String[] args) {
- log.debug("Run restServer");
SpringApplication.run(Main.class, args);
}
}
diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties
index d82c06c..2d7584c 100644
--- a/src/main/resources/application.properties
+++ b/src/main/resources/application.properties
@@ -1,2 +1,3 @@
server.port = 8090
-spring.profiles.active=local
\ No newline at end of file
+spring.profiles.active=local
+logging.level.root=DEBUG
\ No newline at end of file
diff --git a/src/main/resources/log4j.properties b/src/main/resources/log4j.properties
deleted file mode 100644
index ed45a74..0000000
--- a/src/main/resources/log4j.properties
+++ /dev/null
@@ -1,8 +0,0 @@
-log4j.rootLogger=DEBUG, file
-
-log4j.appender.file=org.apache.log4j.RollingFileAppender
-log4j.appender.file.File=restServer.log
-log4j.appender.file.MaxFileSize=5MB
-log4j.appender.file.MaxBackupIndex=10
-log4j.appender.file.layout=org.apache.log4j.PatternLayout
-log4j.appender.file.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n
\ No newline at end of file