I didn't write this HTMLEasy framework.
As I've already stated, I'm strongly against any new MVC framework in
JAX-RS, or in Java EE. We have enough popular ones already:
* JSF
* Struts
* Tapestry
* Spring MVC
* Play
* Seam
JAX-RS was designed for stateless REST APIs. Once you start getting
into MVC you have to worry about HTTP session state and propagating this
information.
Plus as I said before, apps are moving to Pure Javascript/HTML5 with
frameworks like Angular JS and GWT that are making simple REST calls to
the backend. This is the approach we took for our management console in
the latest project I've been working on and it was marvelous.
IMO, the only thing JAX-RS should do would be to add features to help
support external MVC frameworks, i.e.:
* propagating properties from jaxrs resource mehtods to interceptors/filters
* propagating atributes from jax-rs methods to and from
HttpServletRequest and ServletContext
* Forwarding requests.
Anything beyond that would be a big mistake. These types of things tend
to grow and bloat over time. Once an MVC framework is introduced to
JAX-RS, I predict it will eventually evolve to compete against JSF.
This is bad for Java EE. Also, MVC is a very personal preference. New
ones pop up all the time, are popular for awhile then fade away. I just
don't want to have yet another API that nobody uses and that I have to
implement and support for years to come.
You have to remember I've been doing this Java EE thing for a long long
time. 12 years now. Maybe I'm a miserable old fart/dinosaur or maybe
I've gained a little wisdom. :)
On 8/6/2014 11:38 AM, Marek Potociar wrote:
> Hi Bill,
>
> Since you seem to have a very strong opinion on the subject, perhaps you want to provide the RedHat point of view here? :)
>
> Thanks,
> Marek
>
> On 22 Jul 2014, at 19:14, Frans Thamura <frans_at_meruvian.org> wrote:
>
>> several time ago there are discussion regarding JAXRS like MVC
>>
>> and there is htmleasy for resteasy
>>
>> https://code.google.com/p/htmleasy/
>>
>> will this feature part of JAXRS future?
>>
>> F
>
--
Bill Burke
JBoss, a division of Red Hat
http://bill.burkecentral.com