Update entity beans from int to Integer, long to Long, for the reason to
use find by example.

updated the method of register using JPA.

The GlobalDAO need to be more useful in the future.

Also change the web.xml, adding the Context Listener to make
@Scope("request") available.

Signed-off-by: Winguse <github@winguse.com>