3 Replies Latest reply: Sep 3, 2013 3:57 AM by user5636757 RSS

    MissingResourceException for xliff bundle, same configuration works for properties bundle



      it's seems very small issue but i am not able to figure out.

      if i use properties file resource bundle, i do following:

      1. create PortalBundle.properties file in portal package

      2. in proect properties, specify resource bundle type as properties file

      3. in faces-config.xml, add following entry:








      4. in jspx, i can now use this resource bundle:

      <f:loadBundle basename="portal.PortalBundle" var="portalBundle"/>


      <af:goLink text="#{portalBundle.YOUR_COMPANY}" id="pt_ot4" destination="/"

                                 inlineStyle="font-size:x-large; color:White;"/>


      it all works fine.


      however i want to use xliff (xlf file) type resource bundle, i did similar configuration:

      1. create PortalBundle.xlf file in portal package. it has following content:

      <?xml version="1.0" encoding="UTF-8" ?>

      <xliff version="1.1" xmlns="urn:oasis:names:tc:xliff:document:1.1">

        <file source-language="en" original="portal.PortalBundle"



            <trans-unit id="YOUR_COMPANY">

              <source>Your Company</source>








      2. in project properties, specified bundle type as xliff.

      3rd and 4th steps are same as above.


      however surprisingly i get missing resource exception:


      java.util.MissingResourceException: Can't find bundle for base name portal.PortalBundle, locale en

          at java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:1427)

          at java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1250)



      i am confused what else is required for xliff bundle?