Reputation: 5563
I am currently using Primefaces v4
and JSF v2.1
in my application. While JSF being the server side technology, it sends all the html code and processing at the server and keeps the network too busy. Also, scalability is concerning. It keeps too difficult to scale up the application. i.e. for session replication and load balancing view objects are also required to be stored.
I would like to upgrade the versions of JSF
and Primefaces
but the above lag tends me to move my view to AngularJS
which holds its view at the client side and keeps the application server light.
Would it be good to migrate to AngularJS
or does JSF
have any way to overcome this issue? What could be pros and cons of this migration?
Upvotes: 2
Views: 12634
Reputation: 562
Maybe it's too late answer but I'll answer it anyway. JSF + Primefaces is a very mature solution since it's been around for a while. There is a very slight chance that you will face a JSf challenge that nobody else has faced before. So, you can get every kind of support of it online. Angular JS is just a GUI/frontend/clientside technology. Plus, you need to implement the backend yourself. e.g. to render a datagrid coming from the server. Yes, in JSF, you need to implement the backend too but with very less effort. It will automatically bind a list with a datatable. Also, Angular is good for single page apps but for enterprise, multipaged and complex logics(take a CRM as an example), you need a mature technology.
UPDATE: Primefaces has introduced a library for Angular. https://www.primefaces.org/primeng/#/
Upvotes: 5
Reputation: 1209
AngularJS is more modern framework than JSF and as you pointed out, it is client side. JSF is server side. Main advantage of the AngularJS is faster responsiveness and easier development and maintenance. Basically, you don't need to learn so many technologies and frameworks to use AngularJS, which saves time and money. In JSF, there is much more technologies involved, e.g. you need to handle the navigation somehow (single-page AngularJS app is much more simpler). I think the main advantage of AngularJS is that it is server side independent. Basically, you can exchange the whole server implementation without touching the GUI code. On the other side, you cannot do this with JSF. You have to stay with Java.
Upvotes: 1