Red Hat

In Relation To Norman Richards

In Relation To Norman Richards

CDI Interview at DZone

Posted by    |       |    Tagged as CDI

DZone did a short interview with me to go along with the recently released CDI Refcard. It's a bit on the short side, but it's a good concise overview of CDI for developers who might not get what it's all about yet. Enjoy!

Selenium trojan false positive

Posted by    |       |    Tagged as Seam

It seams that some users of Selenium, a framework Seam uses for testing, have reported anti-virus software detecting a possible trojan in the Selenium JARs. This specific issue is with the hudsuckr.exe windows executable, and has been confirmed to be a false positive.

If your AV software has started complaining about this file in the selenium JARs used with Seam, please contact the AV software provider for updated definition files. If you need more information about the issue, please see the selenium forums.

Seam and Flex

Posted by    |       |    Tagged as Seam

If the forums are any indication, there's quite a bit of interest in the Seam community for adding Flex interfaces to Seam applications. Members of the seam community have stepped forward and put together some interesting examples of Seam and Flex working together, and that's been good enough for our more ambitious users. But now it's time to make that integration a bit more formal. So with that, we've added the first round of Flex support to Seam.

We're starting with a simple solution for Flex remoting to Seam applications using BlazeDS. Getting going with Seam involves adding jboss-seam-flex.jar to your application, along with the BlazeDS libraries. The BlazeDS MessageBroker, which responds to requests from the Flex client, is instantiated and managed my the Seam Flex filter:

<flex:flex-filter url-pattern="/messagebroker/*" />

With that, your Flex application can talk to your Seam application. Obviously it wouldn't be wise to expose all your Seam components for remote access automatically. Individual components can be enabled for Flex remoting with a single annotation:

public class Foo
   public void ping() {

This annotation causes Seam to add a named remoting destination on the default channel, which can immediately be accessed as a \<mx:RemoteObject> in a Flex application. The minimal mxml on the client side would be:

<mx:RemoteObject id="remoteFoo" destination="foo" />

This declares a remote objection. The destination name should match the destination name on the @FlexRemote annotation.

<mx:Button id="button" label="Click Me!" click="" />

This creates a button, that when pressed calls the remote method. Dealing with results and errors requires a little more code than this, but it works the same as any other Flex remote object.

One of the nice things about Flex remoting is how simple it is to pass complex data structures around. For example, suppose you are writing a Flex client to work with the hotel data in the Seam booking application. If your Seam components had the following:

public List<Hotel> queryAllHotels() {
   return entityManager.createQuery("select h from Hotel h").getResultList();

Then the entire data set could be loaded into the table quite easily.

<mx:RemoteObject id="remoteFoo" destination="foo" fault="fault(event)">
    <mx:method name="queryHotels"
               result="hotelTable.dataProvider=ResultEvent(event).result" />

<mx:DataGrid id="hotelTable" />
<mx:Button label="Query Hotels" click="remoteFoo.queryHotels()" />

Note here that the remoting is smart enough to figure out the column names and values to display based on the Java objects returned, with no extra coding. It may not be production ready, but it makes for a great demo.

So, if you want to use Flex and Seam together, how can you give this a try? The Flex module is under development in the Seam22 branch. At this point we only support the basic remoting shown here and don't support conversation or business process scoped components, since the correct mapping of conversations to a rich client is not entirely obvious. If you can live with that, or if you'd like to help contribute to the future development of the Flex module, please jump in on the forums and provide some feedback.

Seam 2.2.0.GA is out

Posted by    |       |    Tagged as Seam

The waiting is over. Seam 2.2 is now officially ready!

Seam 2.2.0.GA is largely a API bump, giving us a chance to upgrade Seam to the latest versions of a few libraries that are core to Seam. The largest is a bump to the entire Hibernate family of APIs - core 3.3.1, tools 3.2.4, entitymanager 3.4.0, annotations 3.4.0 and search 3.1.1. We've also moved our Drools support from Drools 4 to Drools 5. If the great new features of Drools 5 weren't enough, we've added a few new features to the drools integration: decision table support, Seam components as consequence exception handlers and Seam components as Drools event listeners.

If you are a JBoss AS user of Seam, we recommend you use JBoss AS 5.1 to make use of the new libraries. Running a Seam 2.2 on JBoss 4.2 may require adding these newer JARs to your application.

We are seeing some problems with hot-redeployment of Seam on JBoss AS 5.1. Take a look at this FAQ for more. We will update the FAQ and this blog once we have the issues fixed.

We've also put in some serious work towards making Seam work better for applications that deploy over multiple WAR files. If that's something you've been having issues with, we definitely recommend that you give Seam 2.2 a try.

As always, please ask questions in the forums and open issues in JIRA for confirmed bugs.

[Download] [Documentation] [Release Notes]

Seam 2.1.2

Posted by    |       |    Tagged as Seam

Thanks to the hard work of the entire Seam community, Seam 2.1.2 is now out and ready to go. Although 2.1.2 is largely about bug fixing, we do have a few new features for you guys. .

[Download] [Reference Documentation] [JIRA] [Release Notes] [Migration Guide]

Seam 2.1.2.CR2

Posted by    |       |    Tagged as Seam

Good news! We've just gone live with Seam 2.1.2.CR2. This release puts us right on the brink of a final release, with only documentation issues and a little more testing remaining on the work list. If you haven't already done so, now is the time to test the release with your Seam projects and report back issues, as the next scheduled stop on the Seam roadmap will be Seam 2.2.

When we put CR1 out, I mentioned the focus we put on bug fixing, but I completely failed to mention that we do have a few new features in this release. One of the biggest is the new s:token tag, aimed at fighting cross site request forgery attacks against Seam applications. On the charting side, we added the ability to customize generated charts and charting data sets in Seam components, for those cases when the strictly declarative charting tags are insufficient. We now have some basic Guice support. And finally, we've been marching seam-gen forward with a number of new features like identity management support and Glassfish-ready project generation.

[Download] [Reference Documentation] [JIRA] [Release Notes] [Migration Guide]

Seam 2.1.2.CR1

Posted by    |       |    Tagged as JBoss Tools Seam

It's been a few months, and we're finally close enough on Seam 2.1.2 to push CR1 out for you guys. We don't have a ton of new features this time around. Instead, we've focussed primarily on bug fixes, stability and minor enhancments, with 165 JIRA items cleared. I'd really like to thank the Seam community as a whole for the participation levels we've seen in this release. We've seen an increase in the quality of the JIRA requests and an even bigger increase in the number of issues with patches and test cases. Seeing open source work is a beautiful thing.

[Download] [Reference Documentation] [JIRA] [Release Notes] [Migration Guide]

Seam 2.1.1.GA is out

Posted by    |       |    Tagged as Seam

It looks like we can add to the Christmas cheer by announcing that Seam 2.1.1 is now out. Seam 2.1.1 is largely a bug-fix release, with a number of notable performance improvements, especially around hot deploy. We've added support for PDF forms to the iText integration as well as OpenID support. Seam-gen now generates IntelliJ IDEA projects. And, I should also point out that we've changed a few of the URLs on examples to match up better with the example names. If you are developing on Seam 2.1, you should consider upgrading quickly to get the latest fixes.

[Download] [Reference Documentation] [JIRA] [Release Notes] [Migration Guide]

Seam 2.1.1.CR2

Posted by    |       |    Tagged as Seam

Seam 2.1.1.CR2 is ready. We're really close to a final release, so please give it a test. Assuming we don't find any more issues, and right now things are looking good, you can probably look for a GA in the next week.

[Download] [Reference Documentation] [JIRA] [Release Notes]

OpenID and Seam

Posted by    |       |    Tagged as Seam

Seam 2.1.1 adds OpenID support as the first of, we hope, many external authentication options in Seam. Since this is fairly new, I've put together a mini-FAQ on our OpenID support.

What is OpenID?

OpenID is a community standard for external web-based authentication. The basic idea is that when a user comes to your application, instead of registering and maintaining a username and password for your application, the user can register and login with his OpenID. Think of it as a user-controlled single sign-on. Instead of trying to explain OpenID here, I recommend watching OpenID According to Dave for a quick overview or Simon Willison's Google Tech Tech for a more technical introduction.

Does OpenID replace my current authentication mechanism?

OpenID can be used in a lot of different ways, and we've tried to keep our support as flexible as possible to support a wide variety of uses. To do that, we've made OpenID a supplemental authentication mechanism. The OpenID component doesn't replace your existing identity component; it sits along side it. After validating an OpenID, the OpenID component can immediately log the user in with no additional work on behalf of your application. Or, you handle the validated OpenID in an application-specific manner.

Do I still need to maintain an entity for the user?

You don't have to use any form of local identity. No local identity might make sense for some uses, like blog comments or voting in a poll, but for most applications you'll probably want to maintain a local user object to attach user-specific data to.

Does OpenID mean you give up control over the login proces?

No. OpenID is about authentication and not authorization. The OpenID provider can tell you that the user trying to access your application is who he claims, but that doesn't necessarily mean the user should be allowed to access your application. Blindly accepting OpenID credentials could open your application to spammers and other internet cretins, so you'll almost certainly want to impose the same registration and login requirements as you would for a non-OpenID login.

Do we support attribute exchange?

Not yet, but that's very high on the list of things we'd like to add.

How do I use OpenID in Seam?

Look in examples/openid for a simple Seam application that uses OpenID. This application demonstrates the simplest form of OpenID usage with no local user. For a more thorough look at how to configure OpenID, have a look at the docs. If you have any questions, problems or suggestions regarding the OpenID support, post a message to the forums.

back to top