[jboss-user] [JBoss Seam] - Invoking seam component from Non-seam environment

ramkavipriya do-not-reply at jboss.com
Tue Dec 11 18:51:31 EST 2007


Hi,

In my application,I am having a bean which implements @Asynchronous method,gets invoked by the caller (a seam component).

In the bean which implements @Asynchronous method,I  need to send email notifications.

For this I am using seam mail support (<m:message>).

I am using some heler bean with setter and getter values and basically these values are used in .xhtml page.

During running,the Asynchronous method gets called and in the helper bean the values are set.

But I am getting the exception something like 
javax.faces.FacesException: Missing final '@domain' ().

When I debugged it,this is happening because the bean values are null as the FacesContext is new.

How to resolve this issue?

My email code looks like below.

public void sendMailBySeamAPI(String key,String value,MailBean mb){
		Renderer renderer = (Renderer)Component.getInstance("renderer");
		    mb.setEmail(key);
	        setEmail(key);
	        setName(value);
			mb.setName(value);
			String pageName = "/secure/responseEmail.xhtml";
			 try {
				 log.debug("In send mail page.."+pageName);			    					 
				 renderer.render(pageName);	    	
		      } catch (Exception e) {
		         log.debug("Error send mail", e);	      
		      }
		
	}

Using Seam 1.2.1 and my application runs in tomcat ejb micro container.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4112117#4112117

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4112117



More information about the jboss-user mailing list