quarkus和vertx_quarkus和Java开发人员的经验

本文探讨了Quarkus框架如何改善Java开发人员的体验,并与Vert.x进行对比,揭示它们在现代Java开发中的角色。
摘要由CSDN通过智能技术生成

quarkus和vertx

This post covers

这篇文章涵盖

  • What is Quarkus?

    什么是Quarkus?
  • Getting started with Quarkus

    Quarkus入门
  • What is native executable?

    什么是本机可执行文件?
  • Building native executable from Java using Quarkus

    使用Quarkus从Java构建本机可执行文件

  • Startup time difference for Jar and native executables

    Jar和本机可执行文件的启动时间差
  • Hot code replacement for Java (For me this is one of the biggest USP of the framework)

    Java的热代码替换(对我来说,这是框架中最大的USP之一)

什么是Quarkus? (What is Quarkus?)

Quarkus is a full-stack, Kubernetes-native Java framework made for Java virtual machines (JVMs) and native compilation, optimizing Java specifically for containers and enabling it to become an effective platform for serverless, cloud, and Kubernetes environments.

Quarkus是针对Java虚拟机(JVM)和本机编译的全栈Kubernetes本地Java框架,专门针对容器优化Java,并使之成为无服务器Kubernetes环境的有效平台。

Quarkus入门 (Getting started with Quarkus)

You would need to have Java 8 or Java 11 installed along with Maven to get started with Quarkus.

您需要与Maven一起安装Java 8或Java 11才能开始使用Quarkus。

创建样板REST项目 (Create a Boilerplate REST project)

Let’s use the Maven plugin to create a boilerplate

让我们使用Maven插件创建样板

mvn io.quarkus:quarkus-maven-plugin:1.8.1.Final:create

Now it would ask for the groupId, artifcatId, version to be entered. It would also ask if we want a REST resource (say yes) followed by the classname and the path of the rest resource. This is how it would look like

现在,它将要求输入groupId,artifcatId,版本。 它还会询问我们是否要使用REST资源(例如“是”),后跟类名和其余资源的路径。 这就是它的样子

Image for post

Now we have a Quarkus boilerplate project ready to be build and run.

现在我们有一个Quarkus样板项目准备好构建和运行。

建立项目 (Build the project)

To create a Jar run the following command.

要创建一个Jar,请运行以下命令。

mvn package

mvn package

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值