[EJB 3.0] - Inheritance of a pojo problem
by emailmsgbox
Hi,
I have the following pojos and SLSB
|
| public class UserBase implements Serializable{
|
| private String id;
| private String name;
|
| }
| public class User extends UserBase implements Serializable{
|
| private String password;
|
| }
|
| public class UserSLSB implements IUserSLFS {
|
| public UserBase getUser(String id){...}
| public void updateUser(UserBase userBase ){...}
| public void createUser(User user ){...}
|
| }
|
|
The User table hold 3 fields ID,NAME,PASS
How can use UserBase and User as ejb3 entitys without adding an extra field used by at @DiscriminatorColumn
I have tried different annotation setting and can get it to work
I don't really need the UserBase as an entity just as a data oblect
Ideas ?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4067352#4067352
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4067352
18Â years, 9Â months
[JBoss jBPM] - JBPM 3.2 doesn't work with JBOSS 4.2.1 + JBOSS PORTAL 2.6
by selia68
Hi,
I'm trying to run the JBPM 3.2.1 under the JBOSS 4.2.1 plus JBOSS Portal 2.6.
As you know, I need to deploy the ear jbpm-enterprise.ear and by following the wiki "http://wiki.jboss.org/wiki/Wiki.jsp?page=DeployJbpm3.2WebAppUnderJBoss4.2.x" I deleted some jars because are already inside the jboss distribution.
After it, I haven't any deployment error but I retrieve the following runtime error when I invoke the jbpm-console web application:
12:16:58,101 ERROR [[Faces Servlet]] Servlet.service() for servlet Faces Servlet threw exception
java.lang.ClassCastException: org.apache.catalina.core.ApplicationContextFacade
at com.sun.faces.portlet.FacesContextFactoryImpl.getFacesContext(FacesContextFactoryImpl.java:64)
at org.jboss.portal.faces.portlet.JSFMetaBridgeFacesContextFactoryImpl.getFacesContext(JSFMetaBridgeFacesContextFactoryImpl.java:47)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:239)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:687)
at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:469)
at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:403)
at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
at org.apache.catalina.authenticator.FormAuthenticator.forwardToLoginPage(FormAuthenticator.java:316)
at org.apache.catalina.authenticator.FormAuthenticator.authenticate(FormAuthenticator.java:244)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:491)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:595)
Could someone help me? Did anyone have a similar problem?
Thank you
Sebastiano
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4067346#4067346
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4067346
18Â years, 9Â months
[JBoss Seam] - Progress bar for fileUpload
by zaya
This is the use case:
The website has users to upload very large files (probably videos), I'm trying to trace the course of the uploading by representing in browser a progress bar. But I don't know if I can do that by using s:fileUpload and how.
By my understanding, s:fileUpload tag uses a filter to store the input file, and map that file to an InputStream. My concern is, because UpdateModel jsf phase is very late in the lifecycle, at the time I have accessibility to the mapped InputStream, the file has already fully uploaded to some temporary place, and I can only use this InputStream to store the file elsewhere, and I lose the control in the course of the uploading.
Anyone has a suggestion?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4067345#4067345
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4067345
18Â years, 9Â months
[JBoss Seam] - ClassNotFoundException: org.apache.myfaces.webapp.StartupSer
by chawax
Hi,
I built an EAR using AndroMDA with EJB3 and Seam cartridge.
But when I try to deploy it on a JBoss 4.2 server, it tells me it can't found org.apache.myfaces.webapp.StartupServletContextListener class. I tried to add manually Apache myfaces-impl-1.1.5.jar, then the server starts but JBoss responds to no request (even a simple http://localhost:8080)
Do you have any idea where it could come from ?
Here is the web.xml file generated by AndroMDA :
<?xml version="1.0" encoding="UTF-8"?>
|
| <web-app version="2.5"
| xmlns="http://java.sun.com/xml/ns/javaee"
| xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
| xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
|
| <!-- ************************ Seam Listener **************************** -->
| <listener>
| <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
| </listener>
|
| <!-- ************************ Ajax4jsf Filter **************************** -->
| <filter>
| <display-name>Ajax4jsf Filter</display-name>
| <filter-name>ajax4jsf</filter-name>
| <filter-class>org.ajax4jsf.FastFilter</filter-class>
| <init-param>
| <param-name>enable-cache</param-name>
| <param-value>true</param-value>
| </init-param>
| <init-param>
| <param-name>forceparser</param-name>
| <param-value>true</param-value>
| </init-param>
| </filter>
|
| <filter-mapping>
| <filter-name>ajax4jsf</filter-name>
| <servlet-name>Faces Servlet</servlet-name>
| <dispatcher>REQUEST</dispatcher>
| <dispatcher>FORWARD</dispatcher>
| <dispatcher>INCLUDE</dispatcher>
| </filter-mapping>
|
| <!-- ************************ Trinidad Filter **************************** -->
| <filter>
| <display-name>Trinidad Filter</display-name>
| <filter-name>trinidad</filter-name>
| <filter-class>org.apache.myfaces.trinidad.webapp.TrinidadFilter</filter-class>
| </filter>
|
| <filter-mapping>
| <filter-name>trinidad</filter-name>
| <servlet-name>Faces Servlet</servlet-name>
| <dispatcher>REQUEST</dispatcher>
| <dispatcher>FORWARD</dispatcher>
| <dispatcher>INCLUDE</dispatcher>
| </filter-mapping>
|
| <!-- ************************ Seam Filter **************************** -->
| <filter>
| <filter-name>Seam Filter</filter-name>
| <filter-class>org.jboss.seam.web.SeamFilter</filter-class>
| </filter>
|
| <filter-mapping>
| <filter-name>Seam Filter</filter-name>
| <servlet-name>Faces Servlet</servlet-name>
| </filter-mapping>
|
| <!-- ************************ Manual Filters **************************** -->
|
|
|
| <!-- ************************ SEAM Config **************************** -->
| <!-- 300 second conversation timeout -->
| <context-param>
| <param-name>org.jboss.seam.core.manager.conversationTimeout</param-name>
| <param-value>300000</param-value>
| </context-param>
| <context-param>
| <param-name>org.jboss.seam.core.init.debug</param-name>
| <param-value>true</param-value>
| </context-param>
|
| <!-- ********************* Facelets Config ************************** -->
| <context-param>
| <param-name>facelets.VIEW_MAPPINGS</param-name>
| <param-value>*.xhtml</param-value>
| </context-param>
| <context-param>
| <description>Prevents HTML-Comments from beeing rendered</description>
| <param-name>facelets.SKIP_COMMENTS</param-name>
| <param-value>true</param-value>
| </context-param>
|
| <!-- ************************ JSF Config **************************** -->
| <context-param>
| <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
| <param-value>.xhtml</param-value>
| </context-param>
| <context-param>
| <description>
| State saving method: "client" or "server" (= default)
| See JSF Specification 2.5.2. In ADF Faces, it is an
| optimized, token-based mechanism that is almost always a
| better choice than the standard JSF server-side state saving.
| </description>
| <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
| <param-value>client</param-value>
| </context-param>
|
| <!-- ************************ MyFaces Config **************************** -->
| <context-param>
| <description>
| This parameter tells MyFaces if javascript code should be allowed in the
| rendered HTML output.
| If javascript is allowed, command_link anchors will have javascript code
| that submits the corresponding form.
| If javascript is not allowed, the state saving info and nested parameters
| will be added as url parameters.
| Default: "true"
| </description>
| <param-name>org.apache.myfaces.ALLOW_JAVASCRIPT</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <description>
| If true, rendered HTML code will be formatted, so that it is "human readable".
| i.e. additional line separators and whitespace will be written, that do not
| influence the HTML code.
| Default: "true"
| </description>
| <param-name>org.apache.myfaces.PRETTY_HTML</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <param-name>org.apache.myfaces.DETECT_JAVASCRIPT</param-name>
| <param-value>false</param-value>
| </context-param>
| <context-param>
| <description>
| If true, a javascript function will be rendered that is able to restore the
| former vertical scroll on every request. Convenient feature if you have pages
| with long lists and you do not want the browser page to always jump to the top
| if you trigger a link or button action that stays on the same page.
| Default: "false"
| </description>
| <param-name>org.apache.myfaces.AUTO_SCROLL</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <param-name>com.sun.faces.validateXml</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <param-name>com.sun.faces.verifyObjects</param-name>
| <param-value>true</param-value>
| </context-param>
|
| <!-- ************************ Trinidad Config **************************** -->
| <context-param>
| <param-name>org.apache.myfaces.trinidad.DEBUG_JAVASCRIPT</param-name>
| <param-value>false</param-value>
| </context-param>
| <context-param>
| <!--
| If this parameter is enabled, Trinidad will automatically
| check the modification date of your JSPs, and discard saved
| state when they change; this makes development easier,
| but adds overhead that should be avoided when your application
| is deployed
| -->
| <param-name>org.apache.myfaces.trinidad.CHECK_FILE_MODIFICATION</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <param-name>org.apache.myfaces.trinidad.resource.DEBUG</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <param-name>org.apache.myfaces.trinidad.ALTERNATE_VIEW_HANDLER</param-name>
| <param-value>org.jboss.seam.ui.facelet.SeamFaceletViewHandler</param-value>
| <!--param-value>com.sun.facelets.FaceletViewHandler</param-value-->
| </context-param>
| <context-param>
| <param-name>org.apache.myfaces.trinidad.CACHE_VIEW_ROOT</param-name>
| <param-value>false</param-value>
| </context-param>
| <context-param>
| <param-name>org.apache.myfaces.trinidadinternal.DISABLE_CONTENT_COMPRESSION</param-name>
| <param-value>true</param-value>
| </context-param>
|
| <!-- ************************ Ajax4JSF Config **************************** -->
| <context-param>
| <param-name>org.ajax4jsf.SKIN</param-name>
| <param-value>DEFAULT</param-value>
| </context-param>
|
| <!-- ************************ Manual Merged Config **************************** -->
| <!-- uncomment if you want to add your own project specific facelet tags
| (and of course make sure "/WEB-INF/custom.taglib.xml" is the actual path
| to your facelet tag descriptor)
| <context-param>
| <param-name>facelets.LIBRARIES</param-name>
| <param-value>
| /WEB-INF/custom.taglib.xml;
| </param-value>
| </context-param>
| -->
|
| <!-- ************************ MyFaces Listener **************************** -->
| <listener>
| <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
| </listener>
|
| <!-- ************************ Seam Servlet Mapping ************************ -->
| <servlet>
| <servlet-name>Seam Resource Servlet</servlet-name>
| <servlet-class>org.jboss.seam.servlet.ResourceServlet</servlet-class>
| </servlet>
|
| <servlet-mapping>
| <servlet-name>Seam Resource Servlet</servlet-name>
| <url-pattern>/seam/resource/*</url-pattern>
| </servlet-mapping>
|
| <!-- ************************ Faces Servlet Mapping **************************** -->
| <servlet>
| <servlet-name>Faces Servlet</servlet-name>
| <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
| <load-on-startup>1</load-on-startup>
| </servlet>
|
| <servlet-mapping>
| <servlet-name>Faces Servlet</servlet-name>
| <url-pattern>*.seam</url-pattern>
| </servlet-mapping>
|
| <!-- ************************ Trinidad Resources Servlet **************************** -->
| <servlet>
| <servlet-name>Trinidad Resources</servlet-name>
| <servlet-class>org.apache.myfaces.trinidad.webapp.ResourceServlet</servlet-class>
| </servlet>
|
| <servlet-mapping>
| <servlet-name>Trinidad Resources</servlet-name>
| <url-pattern>/adf/*</url-pattern>
| </servlet-mapping>
|
| <!-- precompilation merge-point -->
|
|
| <session-config>
| <session-timeout>45</session-timeout>
| <!-- session-config merge-point -->
| </session-config>
|
|
| <!-- Welcome files -->
| <welcome-file-list>
|
| <welcome-file>index.jsp</welcome-file>
| <welcome-file>index.html</welcome-file>
| </welcome-file-list>
|
| <error-page>
| <error-code>408</error-code>
| <location>/index.jsp</location>
| </error-page>
| <error-page>
| <error-code>403</error-code>
| <location>/403.jsp</location>
| </error-page>
|
| <!-- taglib merge-point -->
| <!-- resource-ref merge-point -->
|
|
| <security-constraint>
| <web-resource-collection>
| <web-resource-name>Raw-JSF-Pages</web-resource-name>
| <description>
| Prevent access to raw pages that are for JSF pages.
| (No roles, so no direct access)
| </description>
| </web-resource-collection>
| <auth-constraint>
| </auth-constraint>
| <user-data-constraint>
| <transport-guarantee>NONE</transport-guarantee>
| </user-data-constraint>
| </security-constraint>
| </web-app>
Thanks in advance ;)
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4067341#4067341
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4067341
18Â years, 9Â months