Monday, 27 April 2009

Composite Pattern and JPA's recursive relationships

Share
Today I will show you how to implement Composite Design Pattern using JPA's recursive many to many relationships.

Composite Design Pattern

Composite is a structural pattern which composes objects into tree-like structures to represent part-whole hierarchies.

Two standard examples are:
  • Employee and Boss - Boss is an Employee, Boss can have many Employees (some of them can be Bosses as well)
  • Resource, Folder and File - File and Folder are Resources, Folder contains many Resources (some of can be Files, some Folders)
More about composite pattern can be found here:

http://en.wikipedia.org/wiki/Composite_pattern

End of theory, let's get back to work!

Wednesday, 22 April 2009

OpenSSO and JOSSO Single Sign-On Projects

Share
At the beginning of this week I tested two open-source Sign Sign-On projects:
  • OpenSSO - Sun-backed, very powerful, Google-ready, enterprise-grade solution
  • JOSSO - simple, very easy to configure, Spring-based with support for many platforms including non J2EE/Java EE compliant ones like: PHP 4.x, PHP 5.x, MS ASP, and MS .NET
My goal was to establish an SSO domain between a Spring-based application deployed on Apache Tomcat 6.0 and a legacy application deployed on Apache Tomcat 5.5.

Thursday, 16 April 2009

Java apps on Google App Engine

Share
This week one of my colleagues at work said that Google released App Engine for Java.

While we were talking about App Engine and its features I felt a sudden rush to test it :)

I visited http://code.google.com/appengine/ and saw that, for now, there are only 10,000 accounts!

I opened my Eclipse and started right-away!

Wednesday, 15 April 2009

Tips and tricks on jQuery and RichFaces

Share
There are some common problems with jQuery and RichFaces working together.

Today I will show you some tips and tricks on jQuery and RichFaces.

Friday, 10 April 2009

Java EE, BPEL, SOA Posts Category: Web Services

Share
The following post belongs to Web Services Posts Category. The list is ordered from the basic ones to more advanced:
  1. Old school Apache Axis2 Web Services with Maven2

  2. Generating Web Service Client in Eclipse

  3. JAX-WS Web Services and Axis2

  4. Generating JAX-WS clients using wsimport tool

  5. JAX-WS Web Services in a Java EE 5 Web Application

  6. JAX-WS Web Services in a Java EE 5 EJB 3.0 Module

  7. JAX-WS Web Services in Standalone Applications

  8. Developing JAX-WS Web Services using Apache CXF and Maven2

  9. Apache CXF and Spring 2.5

  10. Developing RESTful Web Services using Apache CXF and Maven2

  11. Securing Web Services with HTTP Basic authentication method

  12. Securing Web Services using GlassFish V2 Message Security

  13. Securing Web Services the right way using WSIT

  14. Web Services, WSIT and Reliable Messaging
Enjoy!
Łukasz

Thursday, 9 April 2009

Java EE, BPEL, SOA Posts Category

Share
Some time ago I found labels mechanism slightly unwieldy when browsing my (long) posts.

Labels mechanism simply displays all articles with given label, and it takes some time to find the information you need.

So, here I introduce Java EE, BPEL, SOA Posts Category mechanism.

Posts Categories will be published as posts, but will simply contain only links to all posts belonging to specific category.

Also, I will add Posts Categories box in the right-hand column.

As new articles will be posted, relevant category will be updated.

Links will be ordered from the basic ones to more advanced.

First Posts Category will be dedicated to Web Services.

Cheers,
Łukasz

Tuesday, 7 April 2009

JAX-WS Web Services in Standalone Applications

Share
Java SE 6 Platform comes with full JAX-WS support. That means you don't have to use any external Web Services engine in order to expose some of your application's functionality as Web Services.

And today I will show you how to create a simple Java SE application which will expose some of its functionality as JAX-WS Web Service.

Thursday, 2 April 2009

Developing RESTful Web Services using Apache CXF and Maven2

Share
JAX-RS (or JSR 311) is a Java API for RESTful Web Services.

Although I like the idea of RESTful Services very much, I don't like calling it RESTful Web Services.

Anyway, today I will show you how to create RESTful Web Services using Apache CXF and Maven2.