4 Replies Latest reply on Nov 24, 2006 2:27 PM by Gavin King

    Update to Seam i18n to support resource bundle types related

    Laumond Christophe Newbie

      Hi all,

      We are using
      jboss-seam-1_1.1.0.CR1
      jboss-4.0.5.GA - ejb3 profile using jems installer

      We need to change the language in our webapplication according to administrator settings and we want to give the possibility to change any test in a database.

      We have found this post in JIRA :

      Update to Seam i18n to support resource bundle types
      http://jira.jboss.com/jira/browse/JBSEAM-421

      which is a change included in the last release of seam as far as we know.

      so we would like to try this feature using the provided sample.

      We have included in our project the code for the DatabaseResourceBundle and all the related classes.
      According to the attached sample, we have to add :

      resourceBundle.bundleName testBundleName
      resourceBundle.resourceType org.sadun.util.DatabaseResourceBundle
      databaseResourceBundle.bundleName testBundleName
      databaseResourceBundle.connectionString jdbc:mysql://localhost:3308/accountingaudit?user=root&password=root


      in the seam.properties

      in the server.log, I have found those line about that :

      2006-11-23 16:00:01,593 WARN [org.jboss.seam.Component] Component class should be serializable: databaseResourceBundle
      2006-11-23 16:00:01,593 INFO [org.jboss.seam.Component] Component: databaseResourceBundle, scope: SESSION, type: JAVA_BEAN, class: org.sadun.util.DatabaseResourceBundle

      then

      2006-11-23 16:00:01,593 DEBUG [org.jboss.seam.Component] databaseResourceBundle.bundleName=testBundleName
      2006-11-23 16:00:01,593 DEBUG [org.jboss.seam.Component] databaseResourceBundle.connectionString=jdbc:mysql://localhost:3308/accountingaudit?user=root&password=root

      but when I try to use it in a JSF page :

      #{testBundleName.message}

      I got this :

      2006-11-23 16:24:54,093 DEBUG [org.jboss.seam.jsf.SeamVariableResolver] resolving name: testBundleName
      2006-11-23 16:24:54,093 DEBUG [org.jboss.seam.Component] seam component not found: testBundleName

      could help us about that please ?

      there is no error messages so we have no idea why it doesn't work.

      Is there a configuration missing somewhere in order to activate this new functionnality provided by Seam ?

      Thanks in advance for your feedback

      Christophe Laumond,
      Sofware Consultant,
      http://www.m-itc.net