Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Working Directory for mvnw compile quarkus:dev #4229

Closed
brentcrammond opened this issue Sep 26, 2019 · 1 comment · Fixed by #4417
Closed

Working Directory for mvnw compile quarkus:dev #4229

brentcrammond opened this issue Sep 26, 2019 · 1 comment · Fixed by #4417
Labels
kind/enhancement New feature or request
Milestone

Comments

@brentcrammond
Copy link

Description
The current system changes the working directory when run using "mvnw compile quarkus:dev" to the target/classes directory. This basically comes down to an unexpected behaviour.

A basic tenant I normally work to is "when I run something from a directory I expect it to be running in that directory rather than changing to another directory."

As mentioned in the bug report that I believe this will be confusing for anyone new to the Quarkus framework as it is an unexpected behaviour.

Screen Shot 2019-09-27 at 08 30 12

QuarkusExample.zip

The above code has been modified (from that provided in the bug report) slightly to better explain the issue.

See related Issue #4205.

I believe this will save people new to the framework a significant time, effort. I am concerned that it will put people off this fantastic framework. I is very important make sure that the framework behaviour is what you would expect.

Implementation ideas
This is the example of what I mean.

The internal application.properties has the quarkus.http.port set to 9090 and the external my_application.properties file has the quarkus.http.port set to 9292.

When I start up the application either through
mvnw compile quarkus:dev

or
java -jar target/quarkus-example-runner.jar

I am expecting it to listening on 9292.

Actual behavior
When started with the mvnw compile quarkus:dev it listens on 9090 (and can't find the my_application.properties) and java -jar target/quarkus-example-runner.jar listens on 9292.

As pointed out in the bug to me, I could get it to work by putting an absolute path to the external my_application.properties and it would work. But that fact that it has changed directory is confusing.

@brentcrammond brentcrammond added the kind/enhancement New feature or request label Sep 26, 2019
@paulolieuthier
Copy link
Contributor

paulolieuthier commented Oct 7, 2019

Looks like this could be configurable in build.gradle.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants