Commit 840225534398859f390b89aff4f1cf726c4d2bff

Authored by Herik dos Santos Lorenção
1 parent b39c03f4
Exists in master

Corrigindo profiles do Spring

codigos/backend/src/main/java/edu/ifes/ci/si/les/srh/services/DBService.java
... ... @@ -4,10 +4,12 @@ import edu.ifes.ci.si.les.srh.builder.TagBuilder;
4 4 import edu.ifes.ci.si.les.srh.model.Tag;
5 5 import edu.ifes.ci.si.les.srh.repository.TagRepository;
6 6 import org.springframework.beans.factory.annotation.Autowired;
  7 +import org.springframework.stereotype.Service;
7 8  
8 9 import java.text.ParseException;
9 10 import java.util.Arrays;
10 11  
  12 +@Service
11 13 public class DBService {
12 14 @Autowired
13 15 private TagRepository tagRepository;
... ...
codigos/backend/src/main/resources/application-dev.properties 0 → 100644
... ... @@ -0,0 +1,8 @@
  1 +# jpa
  2 +spring.datasource.url=jdbc:postgresql://localhost:5432/srh_les
  3 +spring.jpa.database-platform=org.hibernate.dialect.PostgreSQLDialect
  4 +spring.datasource.username=postgres
  5 +spring.datasource.password=postgres
  6 +spring.jpa.hibernate.ddl-auto=create
  7 +spring.jpa.properties.hibernate.show_sql=true
  8 +spring.jpa.properties.hibernate.format_sql=true
0 9 \ No newline at end of file
... ...
codigos/backend/src/main/resources/application.properties
1   -# jpa
2   -spring.datasource.url=jdbc:postgresql://localhost:5432/srh_les
3   -spring.jpa.database-platform=org.hibernate.dialect.PostgreSQLDialect
4   -spring.datasource.username=postgres
5   -spring.datasource.password=postgres
6   -spring.jpa.hibernate.ddl-auto=create
7   -spring.jpa.properties.hibernate.show_sql=true
8   -spring.jpa.properties.hibernate.format_sql=true
9   -spring.profiles.active=dev
10 1 \ No newline at end of file
  2 +spring.profiles.active=test
11 3 \ No newline at end of file
... ...