Help

Controls

PermLinkWikiLink

Built with Seam

You can find the full source code for this website in the Seam package in the directory /examples/wiki. It is licensed under the LGPL.

If you didn't see, the announcement, we've release Seam 2.2.0.GA. Please use this thread for questions about the release.

18 Replies:
07. Aug 2009, 12:27 America/New_York | Link

I am using the Seam 2.2.0.GA. But it does not get loaded in eclipse. It cribs about verion incompatibility. Any clue on how to solve the same.

Thanks. B

07. Aug 2009, 17:33 America/New_York | Link

As of right now (8/7/09) there is an issue with JBAS 5.1.0GA that prevents Seam from reliably deploying/hot-deploying

See:

Issues with Seam 2.2.0 and JBAS 5.1.0GA

Seam deployments and hot deployments in AS 5.1.0

and

FAQ: What happens when you deploy Seam app in JBoss5?

10. Aug 2009, 07:29 America/New_York | Link
is the jboss tooling working for the seam 2.2GA release?

i am unable to set the seam runtime in the jboss tools 3.01 or 3.1.0 without getting the error 'Incompatible version of Seam...'

any help are appreciated.

-lp
16. Aug 2009, 20:19 America/New_York | Link

I am having problems with

<page conversation-required="true" no-conversation-view-id="home.xhtml">

The conversation is being propagated normaly, and this piece of code worked well in 2.1, but this tag is not correctily identifing the conversation and redirecting the page to the home in the wrong way.

Is this a Bug or something? Please help.

Also published this as a topic when tring to reply this tread... but I was no able to delete that... http://seamframework.org/Community/Conversationrequiredtrue#comment91260

26. Aug 2009, 13:10 America/New_York | Link
instead of upgrading just seam or other components, i'd rather download a giant bundle of jboss+eclipse+jboss tools+seam+etc. i am literally spending days to get a combination working if they are released piece by piece.. this is a really big problem with open source movement i think.. pieces work by themselves in unit tests but there is no authority to test the combination.. my hd is full of trashed devxx directories each with its own jboss, eclipse, tools combination.. without jboss tools support, seam 2.2 is not a venture i'd dive into..
26. Aug 2009, 16:19 America/New_York | Link

What is missing is a compatibly matrix that can be updated to show what version on seam works with

- RichFaces

- Hibernate

- JBoss AS

That way we could let everyone know that maybe RichFaces 3.3.1 works with Seam 2.0...or that it doesn't.

Also so that people know Seam doesn't work on JBAS 5.1 currently.

Is this something we could setup in the wiki?

26. Aug 2009, 16:51 America/New_York | Link

That´s a really good idea. The matrix could cover Eclipse and Netbeans (other IDEs..) compatibility too.

 

Please, rate when you find a useful answer!

26. Aug 2009, 17:24 America/New_York | Link

Any experts with the wiki that want to take a first crack at this?

27. Aug 2009, 21:16 America/New_York | Link

I need to upgrade a couple of projects I built with seam-gen in Seam version 2.1.2. Is there a set of instructions on how to do that? What files need replacement/merging?

Thanks.

--Peter

22. Oct 2009, 22:40 America/New_York | Link
Hello. We have a simple Seam application using Wicket which attempts to start a Quartz timer task (using @Asynchronous annotation) in the init() method of the main application (a subclass of SeamWebApplication). We first built this application using Seam 2.1.1.GA and we had no problem and the timer got activated properly. We recently upgraded to Seam 2.2.0.GA and this functionality stopped working. Instead, when we try to activate the timer task (inital call), we get a NPE thrown in the AsynchronousInterceptor when it attempts to access the EventContext, which is null (see log exerpt, below). When I put calls to Lifecycle.beginCall() and Lifecycle.endCall() around this code, the timer is activated with no apparent errors. My question is this: Is this something broken in 2.2.0.GA? If not, is my workaround an appropriate solution? I will be happy to provide my code if you want to look at it.

Thanks!

Walt Barrow

Here is the log snippet:

ERROR [com.afscn.itapps.wicketapp.UIDApplication] Cannot start verification timer task
ERROR [STDERR] java.lang.NullPointerException
ERROR [STDERR] at org.jboss.seam.async.AsynchronousInterceptor.isExecutingAsynchronousCall(AsynchronousInterceptor.java:63)
ERROR [STDERR] at org.jboss.seam.async.AsynchronousInterceptor.aroundInvoke(AsynchronousInterceptor.java:31)
ERROR [STDERR] at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
ERROR [STDERR] at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:107)
ERROR [STDERR] at org.jboss.seam.intercept.JavaBeanInterceptor.interceptInvocation(JavaBeanInterceptor.java:185)
ERROR [STDERR] at org.jboss.seam.intercept.JavaBeanInterceptor.invoke(JavaBeanInterceptor.java:103)
ERROR [STDERR] at com.afscn.itapps.uid.timer.VerificationTimerTask_$$_javassist_seam_2.scheduleTask(VerificationTimerTask_$$_javassist_seam_2.java)
ERROR [STDERR] at com.afscn.itapps.uid.timer.VerificationTimerManager.start(VerificationTimerManager.java:63)
ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
ERROR [STDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
ERROR [STDERR] at java.lang.reflect.Method.invoke(Method.java:597)
ERROR [STDERR] at org.jboss.seam.util.Reflections.invoke(Reflections.java:22)
ERROR [STDERR] at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:32)
ERROR [STDERR] at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:56)
ERROR [STDERR] at org.jboss.seam.transaction.RollbackInterceptor.aroundInvoke(RollbackInterceptor.java:28)
ERROR [STDERR] at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
ERROR [STDERR] at org.jboss.seam.core.BijectionInterceptor.aroundInvoke(BijectionInterceptor.java:77)
ERROR [STDERR] at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
ERROR [STDERR] at org.jboss.seam.core.MethodContextInterceptor.aroundInvoke(MethodContextInterceptor.java:44)
ERROR [STDERR] at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:68)
ERROR [STDERR] at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:107)
ERROR [STDERR] at org.jboss.seam.intercept.JavaBeanInterceptor.interceptInvocation(JavaBeanInterceptor.java:185)
ERROR [STDERR] at org.jboss.seam.intercept.JavaBeanInterceptor.invoke(JavaBeanInterceptor.java:103)
ERROR [STDERR] at com.afscn.itapps.uid.timer.VerificationTimerManager_$$_javassist_seam_1.start(VerificationTimerManager_$$_javassist_seam_1.java)
ERROR [STDERR] at com.afscn.itapps.wicketapp.UIDApplication.init100(UIDApplication.java:77)
ERROR [STDERR] at com.afscn.itapps.wicketapp.UIDApplication.init(UIDApplication.java)
ERROR [STDERR] at org.apache.wicket.protocol.http.WicketFilter.init(WicketFilter.java:570)
ERROR [STDERR] at org.jboss.seam.wicket.web.WicketFilterInstantiator$1.init(WicketFilterInstantiator.java:111)
ERROR [STDERR] at org.jboss.seam.web.WicketFilter.doFilter(WicketFilter.java:124)
ERROR [STDERR] at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
ERROR [STDERR] at org.jboss.seam.web.HotDeployFilter.doFilter(HotDeployFilter.java:53)
ERROR [STDERR] at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
ERROR [STDERR] at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
ERROR [STDERR] at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
ERROR [STDERR] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
ERROR [STDERR] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
ERROR [STDERR] at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
ERROR [STDERR] at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
ERROR [STDERR] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
ERROR [STDERR] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
ERROR [STDERR] at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
ERROR [STDERR] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
ERROR [STDERR] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
ERROR [STDERR] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
ERROR [STDERR] at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
ERROR [STDERR] at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
ERROR [STDERR] at java.lang.Thread.run(Thread.java:619)
 

Thanks!

Walt Barrow

23. Oct 2009, 00:00 America/New_York | Link
Walter Barrow wrote on Oct 22, 2009 22:40:
Hello. We have a simple Seam application using Wicket which attempts to start a Quartz timer task (using @Asynchronous annotation) in the init() method of the main application (a subclass of SeamWebApplication). We first built this application using Seam 2.1.1.GA and we had no problem and the timer got activated properly. We recently upgraded to Seam 2.2.0.GA and this functionality stopped working. Instead, when we try to activate the timer task (inital call), we get a NPE thrown in the AsynchronousInterceptor when it attempts to access the EventContext, which is null (see log exerpt, below). When I put calls to Lifecycle.beginCall() and Lifecycle.endCall() around this code, the timer is activated with no apparent errors. My question is this: Is this something broken in 2.2.0.GA? If not, is my workaround an appropriate solution? I will be happy to provide my code if you want to look at it.

I changed the way that wicket/seam initialized itself for the 2.2.x branch. You don't get a full set of seam contexts at wicket init() time. The seam-recommended approach to starting things at app-startup time, independent of view framework choice, is:

@Observer("org.jboss.seam.postInitialization") public void setupTasks() { /*do things here*/ }

-Clint

 
Clint Popetz
http://42lines.net
Scalable Web Application Development
26. Oct 2009, 23:26 America/New_York | Link

Thanks! I'll give that a try.

 

Thanks!

Walt Barrow

31. Oct 2009, 18:31 America/New_York | Link

Hello,

I have a simple Wicket application built to run with Seam that I use to demonstrate conversations to my co-workers. This application worked fine with Seam 2.1.1.GA, but no longer works with 2.2.0.GA. It seems that my @Begin and @End tags placed on callback methods are being ignored. I tried injecting the Conversation component and manually starting/stopping conversations, but that failed, too. Are there known problems with 2.2.0.GA, Wicket, and conversations? If so, are there any workarounds?

Thanks!

Walt Barrow

 

Thanks!

Walt Barrow

31. Oct 2009, 18:41 America/New_York | Link

I feel like we're hijacking this thread...can you post anew, with a code sample of what you're doing, and also a description of how you are approaching instrumentation of the seam components (i.e. WEB-INF/wicket vs. @SeamWicketComponent, runtime vs. compile-time instrumentation.)

Thanks,

-Clint

 
Clint Popetz
http://42lines.net
Scalable Web Application Development
01. Nov 2009, 20:05 America/New_York | Link

Clint, I started a new thread Seam 2.2.0.GA, Wicket -cannot start longrunning conversation

 

Thanks!

Walt Barrow

17. Nov 2009, 20:50 America/New_York | Link

Hello !!

I do not know if is a BUG in this release (and previews).

When you define in pages.xml the exception handler :

 <exception class="org.jboss.seam.security.NotLoggedInException">
    <redirect view-id="/pages/login.jspx">
       <message severity="warn">Please log in first</message>
     </redirect>
 </exception>

And in your template.xhtml use this to show all messages :

<h:messages id="messages" globalOnly="true" styleClass="message"
  errorClass="errormsg" infoClass="infomsg" warnClass="warnmsg"
  rendered="#{showGlobalMessages != 'false'}" />

And in your Pojo Class, you define a restrict access :

@Name("CommentService")
@Restrict("#{s:hasRole('USER')}")
public class CommentService {
  ...
}

The seam is adding two warn messages on page : Please log in first, one come from Identity and the other one come from NotLoggedInException treatment (pages.xml), see bellow the Identity class bellow.

Is it a bug ? Is there some trick for it ? I am not sure, but I saw something about you are removing all hard-coded set messages by Events.instance().raiseEvent(XXXX);

org.jboss.seam.security.Identity

public void checkPermission(Object target, String action)
   
 public void checkPermission(Object target, String action)
   {
      if (systemOp != null && Boolean.TRUE.equals(systemOp.get())) return;
      
      tryLogin();
      
      if ( !hasPermission(target, action) )
      {   
         if ( !isLoggedIn() )
         {
            if (Events.exists()) Events.instance().raiseEvent(EVENT_NOT_LOGGED_IN);
            throw new NotLoggedInException();            
         }
         else
         {
            if (Events.exists()) 
  1 ->        Events.instance().raiseEvent(EVENT_NOT_AUTHORIZED);
  2 ->        throw new AuthorizationException(String.format("Authorization check failed for permission[%s,%s]", target, action));
         }
      }
   }  
     

Thanks for help me !

17. Nov 2009, 21:15 America/New_York | Link

Hi friends,

I marked the wrong lines :)

public void checkPermission(Object target, String action)
   
 public void checkPermission(Object target, String action)
   {
      if (systemOp != null && Boolean.TRUE.equals(systemOp.get())) return;
      
      tryLogin();
      
      if ( !hasPermission(target, action) )
      {   
         if ( !isLoggedIn() )
         {
            if (Events.exists())
1 ->          Events.instance().raiseEvent(EVENT_NOT_LOGGED_IN);
2 ->          throw new NotLoggedInException();            
         }
         else
         {
            if (Events.exists()) 
              Events.instance().raiseEvent(EVENT_NOT_AUTHORIZED);
              throw new AuthorizationException(String.format("Authorization check failed for permission[%s,%s]", target, action));
         }
      }
   }  
31. Dec 2009, 08:06 America/New_York | Link
I'm a newbie in Seam. I'm doing a POC on Seam-Spring Hybrid components. For that i'm trying to let seam load the context for Spring instead of using the listeners approach. For this i'm referencing the latest Seam Reference.

The issue is when i register the component namespace http://jboss.com/products/seam/spring, prefixed as spring, in the component descriptor and define the <spring:context-loader/> component, the Eclipse shows two errors:

1) cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element 'spring:context-loader'.
2) Referenced file contains errors (http://jboss.com/products/seam/spring-2.2.xsd). For more information, right click on the message in the Problems View and select "Show Details..."

Below is the snippet of my component.xml file:

<components xmlns="http://jboss.com/products/seam/components"
        xmlns:core="http://jboss.com/products/seam/core"
        xmlns:spring="http://jboss.com/products/seam/spring"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.2.xsd
     http://jboss.com/products/seam/spring http://jboss.com/products/seam/spring-2.2.xsd
     http://jboss.com/products/seam/components http://jboss.com/products/seam/components-2.2.xsd">

        <spring:context-loader/>
        <core:init debug="true" jndi-pattern="@jndiPattern@" />

        <core:manager concurrent-request-timeout="500"
                conversation-timeout="120000" conversation-id-parameter="cid"
                parent-conversation-id-parameter="pid" />
</components>

If instead of http://jboss.com/products/seam/spring-2.2.xsd i use http://jboss.com/products/seam/spring-2.0.xsd then there are no such errors but following warning is displayed.

1) XML schema version "2.0" does not match Seam runtime version "2.2".

I have jboss-seam-ioc.jar in my /WEB-INF/lib folder. Please suggest the solution for this as it's kind of showstopper for me.

Thanks,
Gaurav Saini