Friday, August 19, 2016

Jersey in spring boot – Hello world example

Simply speaking: JAX-RS, namely Java API for RESTful Service,  is from JSR 311 (obsolete) and JSR 339 (download here). Jersey is an reference implementation of JAX-RS. Spring boot sure can implement REST service without Jersey by using the controller way (@RestConroller). Also, jersey can be chosen...

Thursday, April 7, 2016

How to dump all dependencies of a maven project

Although it's not common but it really happens in real life.  Usually maven  already automatically downloads all dependencies to local repository, and for some reason you want to get some or all  dependency jar files of this project.  For example you final package is a executable...

Wednesday, April 6, 2016

Understand <optional>true</optional> in maven dependency

In pom's dependency , sometimes there's  <optional> true</option>. What does this mean? Why and when do you need to set this? 1. Meaning of <optional> In short, if project D depend on project C, Project C optionally depend on project A, then project D do NOT depend on project...

Tuesday, April 5, 2016

liquibase - helloworld example

Liquibase is a dabasebase chane management tool. Rather than writing SQL directly against the database to create, update or drop database objects, developers define their desired database changes in XML files. Any change to database are grouped into "ChangeSet", the best practice is one changeset per...

Thursday, March 31, 2016

How does spring's DispatcherServlet work

In Spring webmvc, there is a specifial servlet which is the portal between Servlet container and Spring webmvc framework. It's the DispatcherServlet. A spring web application usually maps all requst to this DispatcherServlet. A servlet's job is take in a HttpServletRequest, do all the business process...

What are default handlers/resolvers in Spring DispatcherServlet

Spring webmvc's DispatcherServlet rely on several important notions. HandlerMapping  - find which controller's which method to process current http request. HandlerAdapter - use HandlerMapping's result, actually make performe the request handling, return a ModelAndView object ViewResolver - find...

Tuesday, March 29, 2016

How to use distributed JMeter to test netty server performance

JMeter is good at performance testing. Usually, we often need more than one hosts to send traffic to one server to see how the sever behaves. This Many-To-One test scenario is called distributed testing.  In JMeter's world, the hosts, which generate traffic,  are called 'jmeter server'. You...

Thursday, March 24, 2016

Netty tutorial - hello world example

Netty is a NIO client server framework which enables quick and easy development of network applications. In this tutorial the basic concepts of Netty are introduced, as well as  a hello world level example. This hello world example, based on Netty 4, has a server and a client, including heart beat...
Powered by Blogger.

About The Author

My Photo
Has been a senior software developer, project manager for 10+ years. Dedicate himself to Alcatel-Lucent and China Telecom for delivering software solutions.