views:

2699

answers:

7

We are plannnig to upgrade the UI framework for our 6-8 year old application written using Struts/JSP/EJB to ExtJS. Just curious as to what is the most popular Java technology on the server people have been using. We were looking into several alternatives like

  1. DWR
  2. RestEasy
  3. Restlet
  4. Struts-Json

We are diving more towards using DWR but just wanted to know if the programming community has some food for thought on this.

For backward compatiblity reasons the migration will happen incrementally and during that period we will try to make ExtJS coexist with the old Web1.0 style pages. We are not changing anything on the business tier but just the web tier will change from JSP to ExtJs pages.

+3  A: 

If you're going to use ExtJS anyway, have you considered using ExtGWT instead? That'll give you much better Java integration.

cletus
+1  A: 

ExtGWT if you are willing to go with GWT, or I would recommend Metro(or any Java RESTful implementation - JSR 311) + ExtJS, it works great.

adrian.tarau
+1  A: 

We've been using Restlet with good success, and it can be used on applications that aren't 100% RESTful (we've got areas where we're a bit cavalier). It's not a full solution, but it comes with decent integrations to other technologies. For instance we generate our XHTML/CSS pages using Restlet's support for the Apache FreeMarker template generator.

Our generated pages happen use jQuery, and ExtJS ought to work equally well. Restlet has a GWT module too.

Jim Ferrans
A: 

Also have a look at Jersey. It's a very useful implementation of JAX-RS (JSR 311) that is easy to integrate into an existing project like yours.

If I were you I'd create a separate package (or even EAR/WAR) with classes that just talked to your existing EJBs and were exposed as REST services that ExtJS can communicate with.

Damo
+1  A: 

I've been using for similiar project jabsorb, which is very similiar to DWR, but conforms to JSON-RPC.

samson
A: 

You might want to check out Myna (http://mynajs.org). This is a Server-Side JavaScript application platform that is deployed as a J2EE war file. Being server-side JavaScript it integrates well with Ext. In fact, all the internal management UI is written in Ext. Myna has several features you may find useful:

  • Web-based adminstrator application. No need to edit XML files
  • Web-based Database adminstrator. Can run queries, create/edit/drop tables, and generate Myna and SQL code from GUI
  • Centralized Datasource management and pooling DB connections
  • A Web Service class that supports SOAP, XML-RPC, JSON-RPC, and MYNA-JSON with Ext.Direct coming soon!
  • Support for handling PUT,POST,GET, and DELETE HTTP requests
  • Support for loading POJO's in your JavaScript code (Via Rhino)
  • Runtime Object Relatinal Mapping. No need to edit XML files or recompile classes when the database tables change
  • Javascript preprocessor supports multi-line SQL queries with implicit prepared statements and typed parameters
  • Queries support paging and returning total rows, which works well with Ext's grids and PagingToolbar

    Full Disclosure: I'm the primary developer for Myna

Mark Porter
+3  A: 

My team also was using using Struts in the past. We have moved forward and are using DWR, and we love it. Our experience with DWR and Ext has been great. So much boiler plate code, both with DWR on the Java end, and Ext on the JavaScript end, has been reduced. There is also a ExtJsWithDwr project to help with integrating the two: http://github.com/BigLep/ExtJsWithDwr.

big lep