Reputation: 1194
use quarkus framework online build tools to quickly set up a restful project.
then start the project, I found issue:
Unrecognized configuration key "quarkus.servlet.context-path" was provided.
don't know what reason for that.
$ ./mvnw clean compile quarkus:dev
[INFO] Scanning for projects...
[INFO]
[INFO] --------------------< com.xuanwugate:code-testing >---------------------
[INFO] Building code-testing 1.0.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ code-testing ---
[INFO] Deleting /Users/xiaods/Desktop/code-testing/target
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ code-testing ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) @ code-testing ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 1 source file to /Users/xiaods/Desktop/code-testing/target/classes
[INFO]
[INFO] --- quarkus-maven-plugin:1.3.1.Final:dev (default-cli) @ code-testing ---
Listening for transport dt_socket at address: 5005
__ ____ __ _____ ___ __ ____ ______
--/ __ \/ / / / _ | / _ \/ //_/ / / / __/
-/ /_/ / /_/ / __ |/ , _/ ,< / /_/ /\ \
--\___\_\____/_/ |_/_/|_/_/|_|\____/___/
2020-03-29 23:38:52,287 WARN [io.qua.config] (main) Unrecognized configuration key "quarkus.servlet.context-path" was provided; it will be ignored
2020-03-29 23:38:52,502 INFO [io.quarkus] (main) code-testing 1.0.0-SNAPSHOT (powered by Quarkus 1.3.1.Final) started in 0.830s. Listening on: http://0.0.0.0:8080
2020-03-29 23:38:52,503 INFO [io.quarkus] (main) Profile dev activated. Live Coding activated.
2020-03-29 23:38:52,503 INFO [io.quarkus] (main) Installed features: [cdi, resteasy]
Upvotes: 1
Views: 2618
Reputation: 6607
Do you have a dependency on io.quarkus:quarkus-undertow
? If you only have io.quarkus:quarkus-resteasy
, then JAX-RS is running directly on top of Vert.x, servlet is not present and the configuration key won't work. If you need servlet, add Undertow, but if you only need to configure the "root path", you can use the quarkus.http.root-path
configuration property.
Upvotes: 6