I am starting a portal project using websphere portal server 6.1. This involves lot of portlets and i am inclined to use JSR286 specs rather than JSR168
Also, i wanted to use Spring Portlet MVC but 3.0 release is still in M2 and does not have proper documentation for the new features added.
Should i start using Spring v2.5.6 and later migrate? Would it involve much rework later?
Is there a better alternative?
Also, is there a prepackaged framework available like AppFuse?
Thanks,
Gaurav
I think you should look at the roadmap for Spring Portlet MVC, maybe you can start using the M2 release and later upgrade. If you are planning to use AJAX, the 286 spec has AJAX support (resource urls) for portlets, whith the 168 spec you have to hack your way with servlets. Another difference is the event architecture, where portlets can communicate using the jsr 286 api, with 168 you can't do that out of the box.
I know that struts guys are also planning to do a 286 plugin. Take your time and weight the pros and cons.
As a final note, I recommend you to use a lightweight portal to develop, and later deploy on websphere (your portlets will have to be fully compliant though), since webspehere is reputadely slow.
Related
I'm looking for some tutorials about portlet in internet, but i can't find a good one. I need to migrate a portlet deployed in websphere 6 to jboss 7, i have some questions about it and i hope you can help me
is it possible migrate a portlet from websphere to jboss 7? I understand that you need a portlet container and i can't find that reference in jboss 7
I found in jboss page a project called GateIn, that looks like be a portlet container, is this correct?
A portlet developed in websphere can migrate to other application server without modification in your code?
None of my co-workers know about portlet, and because the few examples in internet, i think this is a almost deprecated solution, is this correct?
thanks!
1) Yes. Portlets are defined in a JSR specification (v1 is JR-168 and v2 ios JSR-286). Which means as long you have a portlet that complies with spec, you should be able to move it to any portlet container that complies with the spec.
2) Yes, GateIn is a portlet container.
3) As long as the portlet isn't calling any WebSphere specific API calls, you should be able to move it to another portlet container.
4) Portlets are far from deprecated. There are multiple portlet containers (WebSphere Portal, Liferay, GateIn and still a few more). Many of these containers still receive frequent updates and are being deployed for new websites.
There should be a sufficient amount of tutorials / discussion around the web if that's what you mean by "examples". Even looking on SO, you can find new portlet questions.
1- Yes this is possible, the only requirement you have is that your portlet should be a JSR168/286 compliant ().
2- Yes gatein is the eXo&Jboss Portal including a Portlet Container.
3- Yes, if it is a JSR 168/286 compliant portlet and does not depend on a Websphere API
4- No, there are many products using Portlet technologies like Gatein, eXo Platform or Liferay
Here are some portlet samples that could help you https://github.com/gatein/gatein-portal/tree/3.5.x/examples/portlets
I have never worked with portals before. So I am confused now. We have an application which is working with Spring and tomcat 5.5. So now they are telling me to use JBoss portal on top of that. My question is that is it possible to link my application which is already done with jsp, spring, etc to the JBoss portal. When I want to install JBoss portal as options it has JBoss7 and tomcat 6 options. This wouldn't interfere with my own app which has to run on tomcat 5.5. Am I right?
Thanks.
The closest you can get is with JSR 329 which allows to bridge JSF1.2 applications with JSR 286 based portal environment. The JBoss implementation of JSR 329 called JBoss Portlet Bridge gives you the flexibility to run SEAM as well in portal environment without knowing the details of the portal technology. In addition to this, you can also explore Spring's Portlet MVC Framework but the limitation with this framework is your portlet implementation would be in JSR 168 style which is earlier/base version of portlet specification. Another option for you is to develop a separate portal application with portlets calling your business layer services directly to get the work done. I am not aware about any other frameworks/technology you can use to run spring applications in portal environment. And so go ahead with detailed requirement analysis session with your team and identify how they really want the portal to function.
As we all know that we rarely get a chance to learn whats out there in the enterprise world when it comes to college. In my experience I have always seen people learning Core Java and may be some other languages and when they graduate they have no Idea about this enterprise jargon. I am in that boat now. I am a recent graduate with a programming job and I often get confused about all the jargon which appear in the news an discussions. I believe all the frameworks mentioned have a purpose at the time of creation which is intended to fill a void.
I am sure that many of you would have gone through this in the early stage of your career. Is there anything out there a blog post, book , video or forum discussion which helped you to understand how all these frameworks weave together to form a application.
A detailed article would be most appreciated. I tried to look for one but I could them in bits and pieces but not a comprehensive article.
You could google/wikipedia them 1 by 1.
From wikipedia
Java EE
"Java Platform, Enterprise Edition or Java EE is a widely used platform for server programming in the Java programming language. The Java platform (Enterprise Edition) differs from the Java Standard Edition Platform (Java SE) in that it adds libraries which provide functionality to deploy fault-tolerant, distributed, multi-tier Java software, based largely on modular components running on an application server."
The Spring framework is sort of an alternative to Java EE.
Spring
Struts
"Apache Struts is an open-source web application framework for developing Java EE web applications. It uses and extends the Java Servlet API to encourage developers to adopt a model-view-controller (MVC) architecture. It was originally created by Craig McClanahan and donated to the Apache Foundation in May, 2000. Formerly located under the Apache Jakarta Project and known as Jakarta Struts, it became a top level Apache project in 2005."
and so on. Research at your liesure...
You don't need all of these frameworks for completing your application. Even though many frameworks provide integration and support for each other, you don't have to use them all. I suggest you go layer by layer. Spring has uses in almost all layers, Struts is mostly an MVC framework. Spring MVC (one part of Spring) and Struts fill the same void. Tiles is a view layer framework. I think FreeMarker, Velocity and Tapestry are also view layer frameworks. JBOSS is an application server.
Spring and EJB 2.x were competitors. Again, EJB is meant for some of the more complicated applications, find more on this from the creator of Spring who wrote an entire book on why EJBs are not suitable for all web applications, which laid the basis for what was to become Spring later on. Though now, the latest EJB version 3.x seems to be getting good reviews. You haven't even mentioned Hibernate and iBatis for the ORM needs of your web-app.
I suggest you get used to the plethora of frameworks in the enterprise java world. If anything, it shows that the java world is alive and active.
Since Spring 3 was released in December last year, I have been trying out the new REST features in the MVC framework for a small commercial project involving implementing a few RESTful Web Services which consume XML and return XML views using JiBX. I plan to use either Hibernate or JDBC Templates for the data persistence.
As a Spring 2.0 developer, I have found Spring 3's (and 2.5's) new annotations way of doing things quite a paradigm shift and have personally found some of the new MVC annotation features difficult to get up to speed with for non-trivial applications - as such, I am often having to dig for information in forums and blogs that is not apparent from going through the reference guide or from the various Spring 3 REST examples on the web.
For deadline-driven production quality and mission critical applications implementing a RESTful architecture, should I be holding off from Spring 3 and rather be using mature JSR 311 (JAX-RS) compliant frameworks like RESTlet or Jersey for the REST layer of my code (together with Spring 2 / 2.5 to tie things together)? I had no problems using RESTlet 1.x in a previous project and it was quite easy to get up to speed with (no magic tricks behind the scenes), but when starting my current project it initially looked like the new REST stuff in Spring 3's MVC Framework would make life easier.
Do any of you out there have any advice to give on this?
Does anyone know of any commercial / production-quality projects using, or having successfully delivered with, the new REST stuff in Spring 3's MVC Framework.
Many thanks
Glen
We use Spring 3's REST support in a production environment and are very happy with the results. We have about 1600 users and experience no performance issues.
We transitioned from Spring 2.5 (all XML configuration) to Spring 3.0 using Annotations to map our controllers and have been very pleased. Our initial tests show equal to better performance then our previous version and we've seen no bugs in the Spring code.
we have used the rest based implementation with Apache Wink and the results from the wink layer are very good.Our application was scalable with 2 clusters to 3000 requests per second.We did not face any performance issue with the wink layer.I felt that as spring does not provide a JAX-RS AKA JSR 311 we need to settle for another rest based implementation like Jersey or Restlet. If you are already using Spring3.0 please feel free to use JAX-WS support provided by spring's RestTemplate.
I am thinking about a platform for study application (it is team work). I mean standard Java EE 5 (or maybe try raw Java EE 6) and Spring. What is your choose? (I don't mean Spring MVC but Spring Beans and EJB 3.0)
Also I would like to know what app server you use? (now I use GlassFish v2)
I would recommend Spring without EJBs.
My favorite choice of Java EE app server is WebLogic, but I don't know if Oracle is as generous as BEA was about making it available to developers.
I'd recommend using Tomcat as your app server. If you need JMS, add ActiveMQ.
As duffymo says, look at Spring without EJBs. Spring is very powerful, regardless of how much/little you use. I don't know of anyone using EJBs now. Having said that, EJBs have changed dramatically over the years, and now resemble ORMs such as Hibernate (which is worth checking out in itself).
For app servers, check out JBoss. It's free/open-source, and you can choose the web component between Tomcat and Jetty. It's JMX backbone allows you to easily monitor its state and to integrate your own JMX beans into that backbone (if you're using Spring, you can JMX-enable any bean with a simple configuration).
If you want Java EE 6 then the choice appears to be either Glassfish 3 or the beta of JBoss 6. As some of the others have said, I also prefer Spring to Java EE's EJBs.
I don't see much point in looking at Java EE 5, unless you think you will be working with it in the future (possible as some companies are conservative in using newer versions of technology).