In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/02 Report--
This article mainly introduces "how to package files with tx web and maven". In daily operation, I believe many people have doubts about how to package files with tx web and maven. Xiaobian consulted all kinds of materials and sorted out simple and easy to use operation methods. I hope to answer your doubts about "how to package files with tx web and maven"! Next, please follow the small series to learn together!
pom.xml
4.0.0 net.loyin.study vertx 1.0-SNAPSHOT 3.8.1 io.vertx vertx-stack-depchain ${vertx.version} pom import io.vertx vertx-stack-depchain ${vertx.version} pom import io.vertx vertx-core ${vertx.version} io.vertx vertx-web ${vertx.version} io.vertx vertx-web maven-shade-plugin 3.1.0 package shade io.vertx.core.Starter net.loyin.study.vertx.Application maven-compiler-plugin 3.2 1.8 1.8 UTF-8 jdk18 true 1.8 1.8 1.8 1.8
Startup class:
package net.loyin.study.vertx;import io.vertx.core.AbstractVerticle;import io.vertx.core.Vertx;import io.vertx.ext.web.Router;public class Application extends AbstractVerticle { public static void main(String[] args){ Vertx vertx=Vertx.vertx(); vertx.deployVerticle(new Application()); } @Override public void start(){ Router router=Router.router(vertx); router.route().handler(routingContext->{ routingContext.response().putHeader("content-type", "text/html").end("Hello World! "); }); vertx.createHttpServer().requestHandler(router).listen(8800); }}
Dockerfile
FROM java:8VOLUME /tmpADD ./ target/vertx-1.0-SNAPSHOT.jar app.jarRUN bash -c 'touch /app.jar'EXPOSE 8800ENTRYPOINT ["java","-Djava.security.egd=file:/dev/./ urandom","-jar","app.jar"] At this point, the study of" how to package files with vertx web and maven "is over, hoping to solve everyone's doubts. Theory and practice can better match to help everyone learn, go and try it! If you want to continue learning more relevant knowledge, please continue to pay attention to the website, Xiaobian will continue to strive to bring more practical articles for everyone!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.