1 2 Previous Next 20 Replies Latest reply on Jan 6, 2006 5:12 PM by js8523

    Newb needs help...

    bkyrlach

      I'm new to Seam (and web application programming in general) and I'm having troubles deploying one of the Seam example applications from within Eclipse. I've set up the project to (as closely as I can tell) mirror the structure of the example project, and I can indeed navigate to register.jsf (obviously, I'm trying to use the registration example).

      The problem, however, is that whenever I try to submit the form, I get a bulleted list of conversion errors. I'm fairly certain that I'm just missing something silly and obvious, but I just can't quite put my finger on it. If anyone has some suggestions on where to look, I'd be greatly appreciative.

        • 1. Re: Newb needs help...

          Could you add the error trace that occurs. This will help everyone see what is going wrong.

          As far as the example programs go, they all use ant for their deployment rather than eclipse wtp/jboss ide/myeclispe, so therefore :

          1) Place the jboss-seam project in your workspace (download or cvs).

          2) Edit build.properties to correctly point to your jboss application server (containing the EJB3 install version).

          3) In the examples directory deploy booking by going into the booking directory and running build.xml (as an ant task by Shift-Alt-X then Q).

          This will deploy the sample app to your running server, you should see a load of output showing the example app loading.

          Once you have proved that the example app works (by deploying it) then copy one of the example apps structure into a new project that you can then customise for your own project.

          I only suggest to do it this way because I had exactly the same problem as you (trying to create an eclipse deployable project for seam), and I kept on stumbling (my idiocy) and the most pragramtic method was to copy and work from a known working example.

          You however will need to link the new project to the jboss-seam project, and export relevant libraries from the jboss-seam project. Also you will have to edit the build.xml file in your new project to correctly link to the build.xml file in the jboss-seam project.

          I apologise for the ramble.

          James

          • 2. Re: Newb needs help...

            As an aside:

            1) We should create a sample app hot deployable using the jboss-ide (rather than ant) that can be used a generic starting point for web apps.

            2) We should do the same as 1 but for ear type developments.

            When I get a spare moment I will look at this. But in the mean time if anyone has done this already could they inform /educate the masses.

            Thanks,

            James

            • 3. Re: Newb needs help...
              bkyrlach

              I have gotten the sample applications to run from deploying in ant. I havn't tried checking out a project into eclipse as you've suggested above however. I can post the startup log from JBoss, but there arn't any noticeable errors there. If the log would be helpful, I'll post it ASAP. I did realize one mistake I was making was that MyEclipse was liking to deploy the EJB jar with the .jar extension instead of the .ejb3 extension. I fixed this problem, and it says that it's deploying the EJB's, but I have a feeling that the problem lies somewhere in there.

              Lemme poke around and see if I can't get that log.

              • 4. Re: Newb needs help...
                gavin.king

                AFAIK, JBoss IDE requires that things be deployed as an EAR, probably using Ant. This doesn't stop you doing interactive debugging in Eclipse.

                You simply start JBoss from the JBoss IDE Server Navigation view, deploy your app using Ant, and you can debug it.

                • 5. Re: Newb needs help...
                  bkyrlach

                  Does that mean that the actual deployment and development of Seam applications isn't really done from Eclipse (I have MyEclipse and all it's J2EE goodness)? I guess I should go get JBoss IDE.

                  • 6. Re: Newb needs help...
                    gavin.king

                    No, it does not mean that at all.

                    JBoss IDE is just a set of plugins for eclipse.

                    • 7. Re: Newb needs help...
                      bkyrlach

                      I see I'm being more brilliant than ever today. :)

                      I'll download the plugin anyways and see how it helps. Oh, and here's the log that I promised. Somehow, I'm pretty sure I'm still missing something stupid and obvious. *sigh*

                      09:56:55,031 INFO [Server] Starting JBoss (MX MicroKernel)...
                      09:56:55,031 INFO [Server] Release ID: JBoss [Zion] 4.0.3SP1 (build: CVSTag=JBoss_4_0_3_SP1 date=200510231054)
                      09:56:55,031 INFO [Server] Home Dir: C:\seam-stuff\jboss-4.0.3SP1
                      09:56:55,031 INFO [Server] Home URL: file:/C:/seam-stuff/jboss-4.0.3SP1/
                      09:56:55,046 INFO [Server] Patch URL: null
                      09:56:55,046 INFO [Server] Server Name: all
                      09:56:55,046 INFO [Server] Server Home Dir: C:\seam-stuff\jboss-4.0.3SP1\server\all
                      09:56:55,046 INFO [Server] Server Home URL: file:/C:/seam-stuff/jboss-4.0.3SP1/server/all/
                      09:56:55,046 INFO [Server] Server Temp Dir: C:\seam-stuff\jboss-4.0.3SP1\server\all\tmp
                      09:56:55,046 INFO [Server] Root Deployment Filename: jboss-service.xml
                      09:56:55,562 INFO [ServerInfo] Java version: 1.5.0-rc,Sun Microsystems Inc.
                      09:56:55,562 INFO [ServerInfo] Java VM: Java HotSpot(TM) Client VM 1.5.0-rc-b63,Sun Microsystems Inc.
                      09:56:55,562 INFO [ServerInfo] OS-System: Windows XP 5.1,x86
                      09:56:56,517 INFO [Server] Core system initialized
                      09:57:00,474 INFO [WebService] Using RMI server codebase: http://Ops_1001930:8083/
                      09:57:00,505 INFO [Log4jService$URLWatchTimerTask] Configuring from URL: resource:log4j.xml
                      09:57:00,943 INFO [NamingService] Started jndi bootstrap jnpPort=1099, rmiPort=1098, backlog=50, bindAddress=/0.0.0.0, Client SocketFactory=null, Server SocketFactory=org.jboss.net.sockets.DefaultSocketFactory@ad093076
                      09:57:04,776 INFO [EJB3Deployer] Default persistence.properties: {hibernate.transaction.flush_before_completion=false, hibernate.jndi.java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces, hibernate.transaction.auto_close_session=false, hibernate.jndi.java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, hibernate.cache.provider_class=org.hibernate.cache.HashtableCacheProvider, hibernate.transaction.manager_lookup_class=org.hibernate.transaction.JBossTransactionManagerLookup, hibernate.dialect=org.hibernate.dialect.HSQLDialect, hibernate.query.factory_class=org.hibernate.hql.ast.ASTQueryTranslatorFactory, hibernate.hbm2ddl.auto=create-drop, hibernate.connection.datasource=java:/DefaultDS, hibernate.connection.release_mode=after_statement}
                      09:57:04,776 INFO [SocketServerInvoker] Invoker started for locator: InvokerLocator [socket://172.27.50.113:3873/0.0.0.0:3873]
                      09:57:05,996 INFO [AspectDeployer] Deployed AOP: file:/C:/seam-stuff/jboss-4.0.3SP1/server/all/deploy/ejb3-interceptors-aop.xml
                      09:57:11,049 INFO [SnmpAgentService] SNMP agent going active
                      09:57:12,347 INFO [DefaultPartition] Initializing
                      09:57:12,425 INFO [STDOUT]
                      -------------------------------------------------------
                      GMS: address is Ops_1001930:3896 (additional data: 18 bytes)
                      -------------------------------------------------------
                      09:57:14,459 INFO [DefaultPartition] Number of cluster members: 1
                      09:57:14,459 INFO [DefaultPartition] Other members: 0
                      09:57:14,459 INFO [DefaultPartition] Fetching state (will wait for 30000 milliseconds):
                      09:57:14,459 INFO [DefaultPartition] New cluster view for partition DefaultPartition (id: 0, delta: 0) : [172.27.50.113:1099]
                      09:57:14,474 INFO [DefaultPartition] I am (172.27.50.113:1099) received membershipChanged event:
                      09:57:14,474 INFO [DefaultPartition] Dead members: 0 ([])
                      09:57:14,474 INFO [DefaultPartition] New Members : 0 ([])
                      09:57:14,474 INFO [DefaultPartition] All Members : 1 ([172.27.50.113:1099])
                      09:57:14,537 INFO [HANamingService] Started ha-jndi bootstrap jnpPort=1100, backlog=50, bindAddress=/0.0.0.0
                      09:57:14,537 INFO [DetachedHANamingService$AutomaticDiscovery] Listening on /0.0.0.0:1102, group=230.0.0.4, HA-JNDI address=172.27.50.113:1100
                      09:57:16,398 INFO [TreeCache] setting cluster properties from xml to: UDP(ip_mcast=true;ip_ttl=64;loopback=false;mcast_addr=228.1.2.3;mcast_port=45551;mcast_recv_buf_size=80000;mcast_send_buf_size=150000;ucast_recv_buf_size=80000;ucast_send_buf_size=150000):PING(down_thread=false;num_initial_members=3;timeout=2000;up_thread=false):MERGE2(max_interval=20000;min_interval=10000):FD(down_thread=true;shun=true;up_thread=true):VERIFY_SUSPECT(down_thread=false;timeout=1500;up_thread=false):pbcast.NAKACK(down_thread=false;gc_lag=50;max_xmit_size=8192;retransmit_timeout=600,1200,2400,4800;up_thread=false):UNICAST(down_thread=false;min_threshold=10;timeout=600,1200,2400;window_size=100):pbcast.STABLE(desired_avg_gossip=20000;down_thread=false;up_thread=false):FRAG(down_thread=false;frag_size=8192;up_thread=false):pbcast.GMS(join_retry_timeout=2000;join_timeout=5000;print_local_addr=true;shun=true):pbcast.STATE_TRANSFER(down_thread=false;up_thread=false)
                      09:57:16,430 INFO [TreeCache] setEvictionPolicyConfig(): [config: null]
                      09:57:16,445 WARN [TreeCache] No transaction manager lookup class has been defined. Transactions cannot be used
                      09:57:16,477 INFO [TreeCache] interceptor chain is:
                      class org.jboss.cache.interceptors.CallInterceptor
                      class org.jboss.cache.interceptors.LockInterceptor
                      class org.jboss.cache.interceptors.CacheLoaderInterceptor
                      class org.jboss.cache.interceptors.UnlockInterceptor
                      class org.jboss.cache.interceptors.ReplicationInterceptor
                      class org.jboss.cache.interceptors.CacheStoreInterceptor
                      09:57:16,524 INFO [TreeCache] cache mode is REPL_SYNC
                      09:57:16,555 INFO [STDOUT]
                      -------------------------------------------------------
                      GMS: address is Ops_1001930:3899
                      -------------------------------------------------------
                      09:57:18,557 INFO [TreeCache] state could not be retrieved (must be first member in group)
                      09:57:18,557 INFO [TreeCache] viewAccepted(): new members: [Ops_1001930:3899]
                      09:57:18,557 INFO [LRUPolicy] Starting eviction policy using the provider: org.jboss.ejb3.cache.tree.StatefulEvictionPolicy
                      09:57:18,557 INFO [LRUPolicy] Starting a eviction timer with wake up interval of (secs) 1
                      09:57:18,557 INFO [TreeCache] new cache is null (maybe first member in cluster)
                      09:57:18,698 INFO [TreeCache] setting cluster properties from xml to: UDP(ip_mcast=true;ip_ttl=2;loopback=false;mcast_addr=228.1.2.3;mcast_port=43333;mcast_recv_buf_size=80000;mcast_send_buf_size=150000;ucast_recv_buf_size=80000;ucast_send_buf_size=150000):PING(down_thread=false;num_initial_members=3;timeout=2000;up_thread=false):MERGE2(max_interval=20000;min_interval=10000):FD(down_thread=true;shun=true;up_thread=true):VERIFY_SUSPECT(down_thread=false;timeout=1500;up_thread=false):pbcast.NAKACK(down_thread=false;gc_lag=50;max_xmit_size=8192;retransmit_timeout=600,1200,2400,4800;up_thread=false):UNICAST(down_thread=false;min_threshold=10;timeout=600,1200,2400;window_size=100):pbcast.STABLE(desired_avg_gossip=20000;down_thread=false;up_thread=false):FRAG(down_thread=false;frag_size=8192;up_thread=false):pbcast.GMS(join_retry_timeout=2000;join_timeout=5000;print_local_addr=true;shun=true):pbcast.STATE_TRANSFER(down_thread=false;up_thread=false)
                      09:57:18,729 INFO [TreeCache] setEvictionPolicyConfig(): [config: null]
                      09:57:18,729 INFO [TreeCache] interceptor chain is:
                      class org.jboss.cache.interceptors.CallInterceptor
                      class org.jboss.cache.interceptors.LockInterceptor
                      class org.jboss.cache.interceptors.UnlockInterceptor
                      class org.jboss.cache.interceptors.ReplicationInterceptor
                      09:57:18,745 INFO [TreeCache] cache mode is REPL_SYNC
                      09:57:18,761 INFO [STDOUT]
                      -------------------------------------------------------
                      GMS: address is Ops_1001930:3902
                      -------------------------------------------------------
                      09:57:20,763 INFO [TreeCache] viewAccepted(): new members: [Ops_1001930:3902]
                      09:57:20,763 INFO [TreeCache] state could not be retrieved (must be first member in group)
                      09:57:20,763 INFO [LRUPolicy] Starting eviction policy using the provider: org.jboss.cache.eviction.LRUPolicy
                      09:57:20,763 INFO [LRUPolicy] Starting a eviction timer with wake up interval of (secs) 5
                      09:57:20,763 INFO [TreeCache] new cache is null (maybe first member in cluster)
                      09:57:21,607 INFO [orb] ORB run
                      09:57:21,967 INFO [CorbaNamingService] Naming: [IOR:000000000000002B49444C3A6F6D672E6F72672F436F734E616D696E672F4E616D696E67436F6E746578744578743A312E3000000000000200000000000000D8000102000000000E3137322E32372E35302E313133000DC8000000114A426F73732F4E616D696E672F726F6F74000000000000050000000000000008000000004A414300000000010000001C00000000000100010000000105010001000101090000000105010001000000210000005000000000000000010000000000000024000000200000007E00000000000000010000000E3137322E32372E35302E313133000DC9000000000000000000000000000000000000000000000000000000000000002000000004000000000000001F0000000400000003000000010000002000000000000000020000002000000004000000000000001F0000000400000003]
                      09:57:22,124 INFO [CorbaTransactionService] TransactionFactory: [IOR:000000000000003049444C3A6F72672F6A626F73732F746D2F69696F702F5472616E73616374696F6E466163746F72794578743A312E30000000000200000000000000D8000102000000000E3137322E32372E35302E313133000DC8000000144A426F73732F5472616E73616374696F6E732F46000000050000000000000008000000004A414300000000010000001C00000000000100010000000105010001000101090000000105010001000000210000005000000000000000010000000000000024000000200000007E00000000000000010000000E3137322E32372E35302E313133000DC9000000000000000000000000000000000000000000000000000000000000002000000004000000000000001F0000000400000003000000010000002000000000000000020000002000000004000000000000001F0000000400000003]
                      09:57:23,500 INFO [MailService] Mail Service bound to java:/Mail
                      09:57:24,016 INFO [TreeCache] setting cluster properties from xml to: UDP(ip_mcast=true;ip_ttl=8;loopback=false;mcast_addr=230.1.2.7;mcast_port=45577;mcast_recv_buf_size=80000;mcast_send_buf_size=150000;ucast_recv_buf_size=80000;ucast_send_buf_size=150000):PING(down_thread=false;num_initial_members=3;timeout=2000;up_thread=false):MERGE2(max_interval=20000;min_interval=10000):FD_SOCK:VERIFY_SUSPECT(down_thread=false;timeout=1500;up_thread=false):pbcast.NAKACK(down_thread=false;gc_lag=50;max_xmit_size=8192;retransmit_timeout=600,1200,2400,4800;up_thread=false):UNICAST(down_thread=false;min_threshold=10;timeout=600,1200,2400;window_size=100):pbcast.STABLE(desired_avg_gossip=20000;down_thread=false;up_thread=false):FRAG(down_thread=false;frag_size=8192;up_thread=false):pbcast.GMS(join_retry_timeout=2000;join_timeout=5000;print_local_addr=true;shun=true):pbcast.STATE_TRANSFER(down_thread=true;up_thread=true)
                      09:57:24,063 INFO [TreeCache] interceptor chain is:
                      class org.jboss.cache.interceptors.CallInterceptor
                      class org.jboss.cache.interceptors.LockInterceptor
                      class org.jboss.cache.interceptors.UnlockInterceptor
                      class org.jboss.cache.interceptors.ReplicationInterceptor
                      09:57:24,063 INFO [TreeCache] cache mode is REPL_ASYNC
                      09:57:24,110 INFO [STDOUT]
                      -------------------------------------------------------
                      GMS: address is Ops_1001930:3906
                      -------------------------------------------------------
                      09:57:26,113 INFO [TreeCache] viewAccepted(): new members: [Ops_1001930:3906]
                      09:57:26,113 INFO [TreeCache] new cache is null (maybe first member in cluster)
                      09:57:26,113 INFO [TreeCache] state could not be retrieved (must be first member in group)
                      09:57:26,410 INFO [Embedded] Catalina naming disabled
                      09:57:27,020 INFO [Http11Protocol] Initializing Coyote HTTP/1.1 on http-0.0.0.0-8080
                      09:57:27,020 INFO [Catalina] Initialization processed in 532 ms
                      09:57:27,036 INFO [StandardService] Starting service jboss.web
                      09:57:27,036 INFO [StandardEngine] Starting Servlet Engine: Apache Tomcat/5.5
                      09:57:27,114 INFO [StandardHost] XML validation disabled
                      09:57:27,176 INFO [Catalina] Server startup in 156 ms
                      09:57:27,442 INFO [TomcatDeployer] deploy, ctxPath=/invoker, warUrl=.../deploy/httpha-invoker.sar/invoker.war/
                      09:57:27,974 INFO [WebappLoader] Dual registration of jndi stream handler: factory already defined
                      09:57:29,053 INFO [TomcatDeployer] deploy, ctxPath=/ws4ee, warUrl=.../tmp/deploy/tmp3783jboss-ws4ee-exp.war/
                      09:57:29,288 INFO [TomcatDeployer] deploy, ctxPath=/, warUrl=.../deploy/jbossweb-tomcat55.sar/ROOT.war/
                      09:57:29,476 INFO [TomcatDeployer] deploy, ctxPath=/juddi, warUrl=.../deploy/juddi-service.sar/juddiws.war/
                      09:57:29,663 INFO [RegistryServlet] Loading jUDDI configuration.
                      09:57:29,695 INFO [RegistryServlet] Resources loaded from: /WEB-INF/juddi.properties
                      09:57:29,695 INFO [RegistryServlet] Initializing jUDDI components.
                      09:57:30,133 INFO [TomcatDeployer] deploy, ctxPath=/web-console, warUrl=.../deploy/management/console-mgr.sar/web-console.war/
                      09:57:30,993 INFO [TomcatDeployer] deploy, ctxPath=/jbossmq-httpil, warUrl=.../deploy-hasingleton/jms/jbossmq-httpil.sar/jbossmq-httpil.war/
                      09:57:31,697 INFO [RARDeployment] Required license terms exist, view META-INF/ra.xml in .../deploy/jboss-ha-local-jdbc.rar
                      09:57:31,916 INFO [RARDeployment] Required license terms exist, view META-INF/ra.xml in .../deploy/jboss-ha-xa-jdbc.rar
                      09:57:32,104 INFO [RARDeployment] Required license terms exist, view META-INF/ra.xml in .../deploy/jboss-local-jdbc.rar
                      09:57:32,323 INFO [RARDeployment] Required license terms exist, view META-INF/ra.xml in .../deploy/jboss-xa-jdbc.rar
                      09:57:32,526 INFO [RARDeployment] Required license terms exist, view META-INF/ra.xml in .../deploy/jms/jms-ra.rar
                      09:57:32,745 INFO [RARDeployment] Required license terms exist, view META-INF/ra.xml in .../deploy/mail-ra.rar
                      09:57:34,325 INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=DataSourceBinding,name=DefaultDS' to JNDI name 'java:DefaultDS'
                      09:57:34,700 INFO [A] Bound to JNDI name: queue/A
                      09:57:34,716 INFO [B] Bound to JNDI name: queue/B
                      09:57:34,716 INFO [C] Bound to JNDI name: queue/C
                      09:57:34,716 INFO [D] Bound to JNDI name: queue/D
                      09:57:34,716 INFO [ex] Bound to JNDI name: queue/ex
                      09:57:34,763 INFO [testTopic] Bound to JNDI name: topic/testTopic
                      09:57:34,763 INFO [securedTopic] Bound to JNDI name: topic/securedTopic
                      09:57:34,763 INFO [testDurableTopic] Bound to JNDI name: topic/testDurableTopic
                      09:57:34,779 INFO [testQueue] Bound to JNDI name: queue/testQueue
                      09:57:34,857 INFO [UILServerILService] JBossMQ UIL service available at : /0.0.0.0:8093
                      09:57:34,919 INFO [DLQ] Bound to JNDI name: queue/DLQ
                      09:57:35,295 INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=ConnectionFactoryBinding,name=JmsXA' to JNDI name 'java:JmsXA'
                      09:57:35,467 INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=DataSourceBinding,name=bookingDatasource' to JNDI name 'java:bookingDatasource'
                      09:57:35,545 INFO [TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=.../deploy/jmx-console.war/
                      09:57:35,748 INFO [EARDeployer] Init J2EE application: file:/C:/seam-stuff/jboss-4.0.3SP1/server/all/deploy/SampleApp.ear
                      09:57:36,124 INFO [JaccHelper] Initialising JACC Context for deployment: SampleAppEJB.ejb3
                      09:57:36,421 INFO [Ejb3AnnotationHandler] found EJB3: ejbName=org.jboss.seam.example.registration.RegisterAction, class=org.jboss.seam.example.registration.RegisterAction, type=STATELESS
                      09:57:36,843 INFO [JaccHelper] org.jboss.seam.example.registration.RegisterAction has no @SecurityDomain - skipping JACC configuration
                      09:57:36,890 INFO [Ejb3Deployment] default entity manager name: SampleAppEJB
                      09:57:37,000 INFO [Environment] Hibernate 3.1
                      09:57:37,016 INFO [Environment] hibernate.properties not found
                      09:57:37,031 INFO [Environment] using CGLIB reflection optimizer
                      09:57:37,031 INFO [Environment] using JDK 1.4 java.sql.Timestamp handling
                      09:57:37,235 INFO [Ejb3Configuration] found EJB3 Entity bean: org.jboss.seam.example.registration.User
                      09:57:37,673 INFO [Configuration] processing extends queue
                      09:57:37,673 INFO [Configuration] processing collection mappings
                      09:57:37,673 INFO [Configuration] processing association property references
                      09:57:37,673 INFO [Configuration] processing foreign key constraints
                      09:57:37,751 INFO [Configuration] processing extends queue
                      09:57:37,751 INFO [Configuration] processing collection mappings
                      09:57:37,751 INFO [Configuration] processing association property references
                      09:57:37,751 INFO [Configuration] processing foreign key constraints
                      09:57:37,938 INFO [ConnectionProviderFactory] Initializing connection provider: org.hibernate.ejb.InjectedDataSourceConnectionProvider
                      09:57:37,954 INFO [InjectedDataSourceConnectionProvider] Using provided datasource
                      09:57:37,954 INFO [SettingsFactory] RDBMS: HSQL Database Engine, version: 1.8.0
                      09:57:37,954 INFO [SettingsFactory] JDBC driver: HSQL Database Engine Driver, version: 1.8.0
                      09:57:38,017 INFO [Dialect] Using dialect: org.hibernate.dialect.HSQLDialect
                      09:57:38,032 INFO [TransactionFactoryFactory] Using default transaction strategy (direct JDBC transactions)
                      09:57:38,048 INFO [TransactionManagerLookupFactory] instantiating TransactionManagerLookup: org.hibernate.transaction.JBossTransactionManagerLookup
                      09:57:38,048 INFO [TransactionManagerLookupFactory] instantiated TransactionManagerLookup
                      09:57:38,048 INFO [SettingsFactory] Automatic flush during beforeCompletion(): disabled
                      09:57:38,048 INFO [SettingsFactory] Automatic session close at end of transaction: disabled
                      09:57:38,048 INFO [SettingsFactory] JDBC batch size: 15
                      09:57:38,048 INFO [SettingsFactory] JDBC batch updates for versioned data: disabled
                      09:57:38,048 INFO [SettingsFactory] Scrollable result sets: enabled
                      09:57:38,048 INFO [SettingsFactory] JDBC3 getGeneratedKeys(): disabled
                      09:57:38,064 INFO [SettingsFactory] Connection release mode: after_statement
                      09:57:38,064 INFO [SettingsFactory] Default batch fetch size: 1
                      09:57:38,064 INFO [SettingsFactory] Generate SQL with comments: disabled
                      09:57:38,064 INFO [SettingsFactory] Order SQL updates by primary key: disabled
                      09:57:38,064 INFO [SettingsFactory] Query translator: org.hibernate.hql.ast.ASTQueryTranslatorFactory
                      09:57:38,064 INFO [ASTQueryTranslatorFactory] Using ASTQueryTranslatorFactory
                      09:57:38,064 INFO [SettingsFactory] Query language substitutions: {}
                      09:57:38,064 INFO [SettingsFactory] Second-level cache: enabled
                      09:57:38,064 INFO [SettingsFactory] Query cache: disabled
                      09:57:38,064 INFO [SettingsFactory] Cache provider: org.hibernate.cache.HashtableCacheProvider
                      09:57:38,079 INFO [SettingsFactory] Optimize cache for minimal puts: disabled
                      09:57:38,079 INFO [SettingsFactory] Structured second-level cache entries: disabled
                      09:57:38,111 INFO [SettingsFactory] Statistics: disabled
                      09:57:38,111 INFO [SettingsFactory] Deleted entity synthetic identifier rollback: enabled
                      09:57:38,111 INFO [SettingsFactory] Default entity-mode: POJO
                      09:57:38,439 INFO [SessionFactoryImpl] building session factory
                      09:57:39,393 INFO [SessionFactoryObjectFactory] Not binding factory to JNDI, no JNDI name configured
                      09:57:39,409 INFO [Configuration] processing extends queue
                      09:57:39,409 INFO [Configuration] processing collection mappings
                      09:57:39,409 INFO [Configuration] processing association property references
                      09:57:39,409 INFO [Configuration] processing foreign key constraints
                      09:57:39,409 INFO [Configuration] processing extends queue
                      09:57:39,409 INFO [Configuration] processing collection mappings
                      09:57:39,409 INFO [Configuration] processing association property references
                      09:57:39,409 INFO [Configuration] processing foreign key constraints
                      09:57:39,409 INFO [SchemaExport] Running hbm2ddl schema export
                      09:57:39,409 INFO [SchemaExport] exporting generated schema to database
                      09:57:39,425 INFO [SchemaExport] schema export complete
                      09:57:39,425 INFO [Configuration] processing extends queue
                      09:57:39,425 INFO [Configuration] processing collection mappings
                      09:57:39,425 INFO [Configuration] processing association property references
                      09:57:39,425 INFO [Configuration] processing foreign key constraints
                      09:57:39,425 INFO [Configuration] processing extends queue
                      09:57:39,425 INFO [Configuration] processing collection mappings
                      09:57:39,425 INFO [Configuration] processing association property references
                      09:57:39,425 INFO [Configuration] processing foreign key constraints
                      09:57:39,425 INFO [NamingHelper] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
                      09:57:39,425 INFO [SessionFactoryImpl] Checking 0 named queries
                      09:57:39,440 INFO [Ejb3Deployment] Create EntityManager with JNDI name: SampleAppEJB
                      09:57:39,456 INFO [JaccHelper] JACC Policy Configuration for deployment has been put in service
                      09:57:39,456 INFO [Ejb3Deployment] EJB3 deployment time took: 3348
                      09:57:39,690 INFO [ProxyDeployer] no declared remote bindings for : org.jboss.seam.example.registration.RegisterAction
                      09:57:39,816 INFO [EJB3Deployer] Deployed: file:/C:/seam-stuff/jboss-4.0.3SP1/server/all/tmp/deploy/tmp3849SampleApp.ear-contents/SampleAppEJB.ejb3
                      09:57:39,831 INFO [TomcatDeployer] deploy, ctxPath=/SampleAppWeb, warUrl=.../tmp/deploy/tmp3849SampleApp.ear-contents/SampleAppWeb-exp.war/
                      09:57:39,972 INFO [ServletContextListener] Welcome to Seam 1.0 beta 1
                      09:57:39,972 INFO [Seam] initializing Seam
                      09:57:40,066 INFO [Component] Component: org.jboss.seam.core.init, scope: APPLICATION, type: JAVA_BEAN, class: org.jboss.seam.core.Init
                      09:57:40,160 INFO [Component] Component: org.jboss.seam.core.manager, scope: EVENT, type: JAVA_BEAN, class: org.jboss.seam.core.Manager
                      09:57:40,222 INFO [Component] Component: facesContext, scope: APPLICATION, type: JAVA_BEAN, class: org.jboss.seam.core.FacesContext
                      09:57:40,238 INFO [Component] Component: eventContext, scope: APPLICATION, type: JAVA_BEAN, class: org.jboss.seam.core.EventContext
                      09:57:40,254 INFO [Component] Component: sessionContext, scope: APPLICATION, type: JAVA_BEAN, class: org.jboss.seam.core.SessionContext
                      09:57:40,285 INFO [Component] Component: statelessContext, scope: APPLICATION, type: JAVA_BEAN, class: org.jboss.seam.core.StatelessContext
                      09:57:40,332 INFO [Component] Component: conversationContext, scope: APPLICATION, type: JAVA_BEAN, class: org.jboss.seam.core.ConversationContext
                      09:57:40,347 INFO [Component] Component: applicationContext, scope: APPLICATION, type: JAVA_BEAN, class: org.jboss.seam.core.ApplicationContext
                      09:57:40,379 INFO [Component] Component: businessProcessContext, scope: APPLICATION, type: JAVA_BEAN, class: org.jboss.seam.core.BusinessProcessContext
                      09:57:40,410 INFO [Scanner] scanning: C:\seam-stuff\jboss-4.0.3SP1\server\all\tmp\deploy\tmp3849SampleApp.ear-contents\SampleAppWeb-exp.war
                      09:57:40,426 INFO [Seam] done initializing Seam
                      09:57:40,676 INFO [FacesConfigurator] Reading standard config org/apache/myfaces/resource/standard-faces-config.xml
                      09:57:40,817 INFO [FacesConfigurator] Reading config jar:file:/C:/seam-stuff/jboss-4.0.3SP1/server/all/tmp/deploy/tmp3849SampleApp.ear-contents/SampleAppWeb-exp.war/WEB-INF/lib/jsf-facelets.jar!/META-INF/faces-config.xml
                      09:57:40,817 INFO [FacesConfigurator] Reading config /WEB-INF/faces-config.xml
                      09:57:40,973 ERROR [LocaleUtils] Locale name null or empty, ignoring
                      09:57:41,489 INFO [StartupServletContextListener] ServletContext 'C:\seam-stuff\jboss-4.0.3SP1\server\all\.\tmp\deploy\tmp3849SampleApp.ear-contents\SampleAppWeb-exp.war\' initialized.
                      09:57:41,599 INFO [EARDeployer] Started J2EE application: file:/C:/seam-stuff/jboss-4.0.3SP1/server/all/deploy/SampleApp.ear
                      09:57:42,099 INFO [Http11Protocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8080
                      09:57:42,381 INFO [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8009
                      09:57:42,412 INFO [JkMain] Jk running ID=0 time=0/78 config=null
                      09:57:42,428 INFO [Server] JBoss (MX MicroKernel) [4.0.3SP1 (build: CVSTag=JBoss_4_0_3_SP1 date=200510231054)] Started in 47s:382ms
                      09:58:12,399 INFO [MyfacesConfig] No context init parameter 'org.apache.myfaces.PRETTY_HTML' found, using default value true
                      09:58:12,399 INFO [MyfacesConfig] No context init parameter 'org.apache.myfaces.ALLOW_JAVASCRIPT' found, using default value true
                      09:58:12,399 INFO [MyfacesConfig] No context init parameter 'org.apache.myfaces.DETECT_JAVASCRIPT' found, using default value false
                      09:58:12,399 INFO [MyfacesConfig] No context init parameter 'org.apache.myfaces.AUTO_SCROLL' found, using default value false

                      • 8. Re: Newb needs help...
                        gavin.king

                        That log looks fine to me. What exactly is the problem?

                        • 9. Re: Newb needs help...
                          bkyrlach

                          Here's the problem I'm experiencing...

                          1) I navigate to the web app URL (in my case, http://localhost:8080/SampleAppWeb/register.jsf)
                          2) I fill out the form from the sample seam application (a username field, real name field, and password field)
                          3) I submit the form.

                          When I submit the form, it reloads the form with the following addition: an unordered list containing three list items, each of which read "Conversion Error". From what I've been able to Google, this is a standard JSF validation error message when the data entered into a form field doesn't match the expected type. My theory is that the user bean is not being deployed correctly, and therefore when it trys to do the seam component lookup it gets nothing, and JSF is mis-interpreting this as a validation error.

                          Or, I could be entirely off my rocker... which has, on occasion, been known to happen. :)

                          • 10. Re: Newb needs help...

                            Hi

                            you seem to be on the right route as there is no mention of your 'User' seam component when seam is initialised. You should see something like this appear underneath the normal seam components.

                            09:57:40,379 INFO [Component] Component: User, scope: Conversation, type: JAVA_BEAN, class: org.sample.User

                            So it looks like when you deploy your app the seam initialisation is not picking up any of your components.

                            A couple of scenarios are : are your components packaged into a ejb3 ?
                            Is there a seam.properties file present in the root of your ejb3 file.
                            Are your classes annotated with the @name tag.

                            You are looking for seam specific issues as it is seam that is not detecting the class user, and therefore not instantiating it in the faces context.

                            Hope this goes away to helping.

                            James

                            • 11. Re: Newb needs help...
                              bkyrlach

                              Doh!

                              I forgot the seam.properties file in my SampleAppEJB.ejb3 jar. However, it still doesn't work. Maybe you can explain this to me? From my logs, I see the following...

                              09:13:19,524 INFO [Scanner] scanning: /C:/seam-stuff/jboss-4.0.3SP1/server/all/tmp/deploy/tmp38060SampleApp.ear-contents/SampleAppEJB.ejb3
                              09:13:19,524 INFO [Scanner] scanning: C:\seam-stuff\jboss-4.0.3SP1\server\all\tmp\deploy\tmp38060SampleApp.ear-contents\SampleAppWeb-exp.war
                              09:13:19,539 INFO [Seam] done initializing Seam

                              I noticed that for the booking example application that comes with seam that seam does lots of nice things (like, you know... actually deploying beans and stuff) after scanning the ejb3 jar file. For me, it seems as if it's not finding anything inside the .ejb3 file. Any ideas?

                              • 12. Re: Newb needs help...

                                Hi

                                is your User class annotated with @Name("user") and @Scope(CONVERSATION).

                                these are the likely annotations that Seam is looking for.

                                James

                                • 13. Re: Newb needs help...
                                  bkyrlach

                                  Here's the source from my user bean. Please note that it's identical to the one used in the examples/registration from seam.

                                  package org.jboss.seam.example.registration;

                                  import static org.jboss.seam.ScopeType.SESSION;

                                  import java.io.Serializable;

                                  import javax.persistence.Entity;
                                  import javax.persistence.Id;
                                  import javax.persistence.Table;

                                  import org.hibernate.validator.Length;
                                  import org.hibernate.validator.NotNull;
                                  import org.jboss.seam.annotations.Name;
                                  import org.jboss.seam.annotations.Scope;

                                  @Entity
                                  @Name("user")
                                  @Scope(SESSION)
                                  @Table(name="users")
                                  public class User implements Serializable
                                  {
                                  private static final long serialVersionUID = 1881413500711441951L;

                                  private String username;
                                  private String password;
                                  private String name;

                                  public User(String name, String password, String username)
                                  {
                                  this.name = name;
                                  this.password = password;
                                  this.username = username;
                                  }

                                  public User() {}

                                  @NotNull
                                  public String getName()
                                  {
                                  return name;
                                  }

                                  public void setName(String name)
                                  {
                                  this.name = name;
                                  }

                                  @NotNull @Length(min=5, max=15)
                                  public String getPassword()
                                  {
                                  return password;
                                  }

                                  public void setPassword(String password)
                                  {
                                  this.password = password;
                                  }

                                  @Id @NotNull @Length(min=5, max=15)
                                  public String getUsername()
                                  {
                                  return username;
                                  }

                                  public void setUsername(String username)
                                  {
                                  this.username = username;
                                  }

                                  public String toString()
                                  {
                                  return "User(" + username + ")";
                                  }
                                  }

                                  It' doesn't use the conversation scope, but that doesn't prevent it from working in the registration example. :-/

                                  • 14. Re: Newb needs help...
                                    gavin.king

                                    @Name is the annotation that Seam looks for.

                                    I can't tell what you are doing wrong here. Looks basically correct.

                                    1 2 Previous Next