odomitchi anikpo

Greenhorn
+ Follow
since Jan 15, 2009
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by odomitchi anikpo

Hello,



I am using Richfaces 3.3.0, Facelelts 1.1.14 and Seam 2.1.1.


I have an issue my rich:dataTable component and sorting. I noticed the very first click on the table on a column header has no effect then all subsequent clicks on any header actually perform the previously requested sort order. I would really appreciate some help.


The section of my .xhtml file that contains the table looks like this:



...



<a4j:status id="ajaxstatus" onstart="Richfaces.showModalPanel('statusPanel');" onstop="Richfaces.hideModalPanel('statusPanel');" />



...



<a4j:form id="myForm">



<rich:contextMenu attached="false" id="menu" submitMode="ajax">

<rich:menuItem ajaxSingle="true" action="#{myAction.openItem}" value="Open Report" >

<a4j:actionparam name="uri" assignTo="#{myAction.selectedItem.uri}" value="{uri}"/>

</rich:menuItem>

<rich:menuItem submitMode="server" action="#{myAction.openItem}" value="Open in new window" target="{uri}" onclick="window.open('', 'jsWinId', 'windth=200, height=200, resizable=0')">

<a4j:actionparam name="uri" assignTo="#{myAction.selectedItem.uri}" value="{uri}"/>

</rich:menuItem>

</rich:contextMenu>



<rich:dataTable id="myTable" var="_myItem" value="#{myAction.allItems}" selectionMode="single" sortMode="single" width="100%" rows="25" reRender="myForm:myTable,ds" rowClasses="cur"

onRowMouseOver="this.style.backgroundColor='#F1F1F1'" onRowMouseOut="this.style.backgroundColor='#{a4jSkin.tableBackgroundColor}'" rendered="#{not empty myAction.allItems}" >

<rich:column id="col1" sortBy="#{_myItem.id}" sortOrder="#{myAction.sortOrder['col1']}" label="Transaction ID" width="15%">

<f:facet name="header">

<h:outputText value="ID"/>

</f:facet>

#{_myItem.id}

</rich:column>

<rich:column id="col2" sortBy="#{_myItem.category}" sortOrder="#{myAction.sortOrder['col2']}" label="Category" width="17%">

<f:facet name="header">

<h:outputText value="Category"/>

</f:facet>

#{_myItem.category}

</rich:column>

<rich:column id="col3" sortBy="#{_myItem.name}" sortOrder="#{myAction.sortOrder['col3']}" label="Name" width="17%">

<f:facet name="header">

<h:outputText value="Name"/>

</f:facet>

#{_myItem.name}

</rich:column>

<rich:column id="col4" sortBy="#{_myItem.location}" sortOrder="#{myAction.sortOrder['col4']}" label="Location" width="21%">

<f:facet name="header">

<h:outputText value="Location"/>

</f:facet>

#{_myItem.location}

</rich:column>

<rich:column id="col5" sortBy="#{_myItem.status}" sortOrder="#{myAction.sortOrder['col5']}" label="Status" width="15%">

<f:facet name="header">

<h:outputText value="Status"/>

</f:facet>

#{myAction.statusDescription(_myItem.status)}

</rich:column>

<rich:column id="col6" sortBy="#{_myItem.timestamp}" sortOrder="#{myAction.sortOrder['col6']}" label="Timestamp" width="15%">

<f:facet name="header">

<h:outputText value="Timestamp"/>

</f:facet>

<h:outputText value="#{_myItem.timestamp}"><s:convertDateTime type="both" pattern="yyyy-MM-dd HH:mm:ss.ss"/></h:outputText>

</rich:column>





<f:facet name="footer">

<rich:datascroller for="myTable" id="ds" renderIfSinglePage="false" ajaxSingle="false"></rich:datascroller>

</f:facet>





<rich:componentControl event="onRowClick" for="menu" operation="show">

<f:param name="uri" value="#{_myItem.uri}"/>

</rich:componentControl>


</rich:dataTable>

</a4j:form>


Thanks in advance!


Odomitchi A.
--------------
SCDJWS JEE5, SCWCD JEE5, SCJP 5.0, SCJP 1.4,
IBM Certified Application Developer
14 years ago
JSF
I got passed that error. thanks
Hello, I hope this is the right place to post. I've been trying to integrate a few frameworks for a new web application which unfortunately I'm not very familiar with, so it has not been such a smooth ride. I've been able to integrate Hibernate, Spring, MyFaces and Facelets, but I want to add Seam and richfaces and I've been stuck for a long time trying to integrate Seam and Spring. See below my configuration files and the error get when I attempt to run it. Your guidance will be very much appreciated. Thanks

WEB.XML (in WEB-INF)


FACES-CONFIG.XML (in WEB-INF)


SPRING-HIBERNATE.XML (in WEB-INF)
... I intend to make my spring beans hybrid spring-seam componenets but for now it's just a simple spring beans like this
[code]
<bean id="allocationService" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
<property name="transactionManager">
<ref local="transactionManager"/>
</property>
<property name="target">
<ref local="allocationServiceTarget"/>
</property>
<property name="transactionAttributes">
<props>
<prop key="find*">PROPAGATION_REQUIRED,readOnly
</prop>
<prop key="save*">PROPAGATION_REQUIRED
</prop>
<!--<prop key="update*">PROPAGATION_REQUIRED</prop>-->
<prop key="delete*">PROPAGATION_REQUIRED
</prop>
</props>
</property>
</bean>code]
...
COMPONENTS.XML (in WEB-INF)
<?xml version="1.0" encoding="UTF-8"?>
<components xmlns="http://jboss.com/products/seam/components"
xmlns:core="http://jboss.com/products/seam/core"
xmlns:framework="http://jboss.com/products/seam/framework"
xmlns:persistence="http://jboss.com/products/seam/persistence"
xmlns:security="http://jboss.com/products/seam/security"
xmlns:spring="http://jboss.com/products/seam/spring"
xmlns:transaction="http://jboss.com/products/seam/transaction"
xmlns:web="http://jboss.com/products/seam/web"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="
http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.1.xsd
http://jboss.com/products/seam/framework http://jboss.com/products/seam/framework-2.1.xsd
http://jboss.com/products/seam/persistence http://jboss.com/products/seam/persistence-2.1.xsd
http://jboss.com/products/seam/security http://jboss.com/products/seam/security-2.1.xsd
http://jboss.com/products/seam/spring http://jboss.com/products/seam/spring-2.1.xsd
http://jboss.com/products/seam/transaction http://jboss.com/products/seam/transaction-2.1.xsd
http://jboss.com/products/seam/web http://jboss.com/products/seam/web-2.1.xsd
http://jboss.com/products/seam/components http://jboss.com/products/seam/components-2.1.xsd">

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

<web:redirect-filter disabled="true"/>

<spring:context-loader config-locations="/WEB-INF/spring-hibernate.xml"/>

</components>


EXCEPTION:
WARN [http-8080-1] (HtmlLabelRenderer.java:78) - Attribute 'for' of label component with id loginForm:j_id15 is not defined
WARN [http-8080-1] (HtmlLabelRenderer.java:78) - Attribute 'for' of label component with id loginForm:j_id17 is not defined
WARN [http-8080-1] (SeamPhaseListener.java:199) - uncaught exception, passing to exception handler
java.lang.IllegalStateException: Could not commit transaction
at org.jboss.seam.jsf.SeamPhaseListener.commitOrRollback(SeamPhaseListener.java:626)
at org.jboss.seam.jsf.SeamPhaseListener.commitOrRollback(SeamPhaseListener.java:605)
at org.jboss.seam.jsf.SeamPhaseListener.handleTransactionsAfterPhase(SeamPhaseListener.java:343)
at org.jboss.seam.jsf.SeamPhaseListener.afterServletPhase(SeamPhaseListener.java:243)
at org.jboss.seam.jsf.SeamPhaseListener.afterPhase(SeamPhaseListener.java:194)
at org.apache.myfaces.lifecycle.PhaseListenerManager.informPhaseListenersAfter(PhaseListenerManager.java:92)
at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:142)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:155)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
at org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:58)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.IdentityFilter.doFilter(IdentityFilter.java:40)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:90)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.RuntimeException: exception invoking: getTransaction
at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:154)
at org.jboss.seam.Component.callComponentMethod(Component.java:2211)
at org.jboss.seam.Component.unwrap(Component.java:2237)
at org.jboss.seam.Component.getInstance(Component.java:2004)
at org.jboss.seam.Component.getInstance(Component.java:1967)
at org.jboss.seam.Component.getInstance(Component.java:1961)
at org.jboss.seam.Component.getInstance(Component.java:1934)
at org.jboss.seam.Component.getInstance(Component.java:1929)
at org.jboss.seam.transaction.Transaction.instance(Transaction.java:36)
at org.jboss.seam.jsf.SeamPhaseListener.commitOrRollback(SeamPhaseListener.java:611)
... 32 more
Caused by: javax.naming.NamingException: Cannot create resource instance
at org.apache.naming.factory.TransactionFactory.getObjectInstance(TransactionFactory.java:113)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304)
at org.apache.naming.NamingContext.lookup(NamingContext.java:793)
at org.apache.naming.NamingContext.lookup(NamingContext.java:140)
at org.apache.naming.NamingContext.lookup(NamingContext.java:781)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at org.apache.naming.SelectorContext.lookup(SelectorContext.java:137)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at org.jboss.seam.transaction.Transaction.getUserTransaction(Transaction.java:79)
at org.jboss.seam.transaction.Transaction.createUTTransaction(Transaction.java:71)
at org.jboss.seam.transaction.Transaction.getTransaction(Transaction.java:44)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.seam.util.Reflections.invoke(Reflections.java:22)
at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:144)
... 41 more
ERROR [http-8080-1] (SeamPhaseListener.java:213) - swallowing exception
java.lang.IllegalStateException: Could not commit transaction
at org.jboss.seam.jsf.SeamPhaseListener.commitOrRollback(SeamPhaseListener.java:626)
at org.jboss.seam.jsf.SeamPhaseListener.commitOrRollback(SeamPhaseListener.java:605)
at org.jboss.seam.jsf.SeamPhaseListener.handleTransactionsAfterPhase(SeamPhaseListener.java:343)
at org.jboss.seam.jsf.SeamPhaseListener.afterServletPhase(SeamPhaseListener.java:243)
at org.jboss.seam.jsf.SeamPhaseListener.afterPhase(SeamPhaseListener.java:194)
at org.apache.myfaces.lifecycle.PhaseListenerManager.informPhaseListenersAfter(PhaseListenerManager.java:92)
at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:142)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:155)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
at org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:58)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.IdentityFilter.doFilter(IdentityFilter.java:40)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:90)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.RuntimeException: exception invoking: getTransaction
at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:154)
at org.jboss.seam.Component.callComponentMethod(Component.java:2211)
at org.jboss.seam.Component.unwrap(Component.java:2237)
at org.jboss.seam.Component.getInstance(Component.java:2004)
at org.jboss.seam.Component.getInstance(Component.java:1967)
at org.jboss.seam.Component.getInstance(Component.java:1961)
at org.jboss.seam.Component.getInstance(Component.java:1934)
at org.jboss.seam.Component.getInstance(Component.java:1929)
at org.jboss.seam.transaction.Transaction.instance(Transaction.java:36)
at org.jboss.seam.jsf.SeamPhaseListener.commitOrRollback(SeamPhaseListener.java:611)
... 32 more
Caused by: javax.naming.NamingException: Cannot create resource instance
at org.apache.naming.factory.TransactionFactory.getObjectInstance(TransactionFactory.java:113)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304)
at org.apache.naming.NamingContext.lookup(NamingContext.java:793)
at org.apache.naming.NamingContext.lookup(NamingContext.java:140)
at org.apache.naming.NamingContext.lookup(NamingContext.java:781)
at org.apache.naming.NamingContext.lookup(NamingContext.java:153)
at org.apache.naming.SelectorContext.lookup(SelectorContext.java:137)
at javax.naming.InitialContext.lookup(InitialContext.java:392)
at org.jboss.seam.transaction.Transaction.getUserTransaction(Transaction.java:79)
at org.jboss.seam.transaction.Transaction.createUTTransaction(Transaction.java:71)
at org.jboss.seam.transaction.Transaction.getTransaction(Transaction.java:44)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.seam.util.Reflections.invoke(Reflections.java:22)
at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:144)
... 41 more


The aplication still starts up, but further actions bugs. So I think I need to address the start up errors. Please suggest. I'm new at this so please even post what may be the most obvious to you. thanks again!
never mind I needed to only keep el-api in tomcat but it was still bugging after I removed the el-api from my war because I in fact needed to clean and undeploy my war, shutdwon tomcat, nuke my temp directory etc so that ther wouldn't be any trace of el api in my war that conflicts with the one in tomcat.
Please I need help
I have issues integrating seam and facelets to myfaces, spring and hibernate app. Config details and error below.
The combination Hibernate 3.4 + Spring 2.5.5 + Myfaces 1.2.5 was already working. And I included the jars:
Facelets 1.1.14: jsf-facelets.jar, el-api-1.0.jar, el-impl-1.0.jar
Seam 2.1.1: jboss-seam.jar, jboss-seam-ui.jar, persistence-api.jar, javaassist.jar


FACES-CONFIG.XML





WEB.XML

COMPONENETS.XML


ERROR:
Jan 15, 2009 11:35:31 AM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Exception sending context initialized event to listener instance of class org.apache.myfaces.webapp.StartupServletContextListener
java.lang.LinkageError: loader constraint violation: when resolving interface method "javax.servlet.jsp.JspApplicationContext.addELResolver(Ljavax/el/ELResolver;)V" the class loader (instance of org/apache/catalina/loader/WebappClassLoader) of the current class, org/apache/myfaces/webapp/Jsp21FacesInitializer, and the class loader (instance of org/apache/catalina/loader/StandardClassLoader) for resolved class, javax/servlet/jsp/JspApplicationContext, have different Class objects for the type javax/el/ELResolver used in the signature

Since tomcat 6 has el-api.jar I tried removing el-api and el-impl jars from facelets. and I still get that error. I tried replcing them with jboss-el still same error; also replaced with el-api jar shipped with seam and still got that error. If I remove el-api from tomcat lib I get a classNotFound exception.

I have spent a long time trying to figure it out. I would really appreciate your help.
Thanks
mitchi