13

Bootique Jetty 0.25 Update Tips

 3 years ago
source link: https://nixmash.com/java/bootique-jetty-0-25-update-tips/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

NixMash.com is built with the Bootique Java Framework. Modules include Bootique Shiro, Jersey, RabbitMQ Client, MVC, Logback and Jetty. Bootique 0.25 was just released so I didn't waste any time upgrading. Here is Andrus Adamchik's Bootique 0.25 Release Announcement.

I noticed a few changes in configuring Bootique Jetty that I wanted to pass along here, minor things which might save someone else some time figuring out.

Updating to Bootique 0.25

Before looking at our Jetty issues, upgrading to Bootique 0.25 is as easy as changing a digit in your application root POM.XML file. Bam!

bq0323a.png

Jetty YAML Configuration Properties

In your bootique.yml Jetty Configuration, "connector" is now "connectors," and the assignment syntax of connector properties is now more strictly enforced. So what you see on the left becomes what you see on the right.

bq0323b.png

JettyTestFactory Deprecated

JettyTestFactory has been deprecated, standardizing now on BQTestFactory.

bq0323c.png

Acquiring Runtime

There are a couple changes in the following graphic I want to mention. In 0.24 when you wanted to grab the Bootique Runtime to instantiate an Class or something you would do so as shown at left. With 0.25, on the right-hand side, we can create a runtime instance, but we have to perform a run() command for Jetty to launch.

One more minor point is that for testing the "-s" or "server" argument was not required in 0.24, which must now be included for Jetty.

bq0323d.png

As I said, minor issues, so there's no excuse not to upgrade to Bootique 0.25.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK