oasp / oasp4j

The Open Application Standard Platform for Java
Apache License 2.0
60 stars 303 forks source link

Datasource issue with project archetype 2.4.0 #608

Closed geoffroya closed 6 years ago

geoffroya commented 6 years ago

When creating a new project with archetype 2.4.0, and start it, if you look in logs, it's not the H2MEM spring.datasource properties that are picked!

Seems that archetype of OASP2.4.0 fall into the following spring-boot issue: https://stackoverflow.com/questions/34964066/spring-boot-doesnt-use-datasource-properties

Just add

    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-jdbc</artifactId>
    </dependency>

into core/pom.xml seems to do the trick (where is this located in source code, so I can propose a PR?)

=> Seems to me that's quite blocking for new comers, don't you think?

hohwille commented 6 years ago

@geoffroya Thanks for your investigation and feedback. So you tested the change locally and that does the trick? Awesome if you managed to solve this one. I also once experienced that the spring profile was not picked up early enough to load the correct application-«profile».properties and therefore am more than happy if you found the solution to that nasty problem... 👍 BTW: I am currently in India so I myself will not be able to work on this before next week...

geoffroya commented 6 years ago

Yes the problem seems to be solved. It occured on a new project trying to go with OASP4j.

hohwille commented 6 years ago

629 has been merged so this issue is resolved.