geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ivan <xhh...@gmail.com>
Subject Re: svn commit: r1031343 - /geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
Date Fri, 05 Nov 2010 01:28:09 GMT
Thanks for fixing the typo issues, I was thinking I have done in my last
commit :-)
The default faces-config.xml file is handled by MyFaces now, you might check
the FacesConfigurator.configure() method. I have posted a thread in the
myfaces community, and wish them could provide a spi for us to pass the
combined faces configurations, so that we could avoid parsing those
configuration files while starting the application.
thanks.

2010/11/5 <djencks@apache.org>

> Author: djencks
> Date: Thu Nov  4 23:21:49 2010
> New Revision: 1031343
>
> URL: http://svn.apache.org/viewvc?rev=1031343&view=rev
> Log:
> GERONIMO-5561 fix some typos and minor logic errors.  Also I'm hoping Ivan
> can confirm how default WEB-INF/faces-config.xml is handled
>
> Modified:
>
>  geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
>
> Modified:
> geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
> URL:
> http://svn.apache.org/viewvc/geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java?rev=1031343&r1=1031342&r2=1031343&view=diff
>
> ==============================================================================
> ---
> geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
> (original)
> +++
> geronimo/server/trunk/plugins/myfaces/geronimo-myfaces-builder/src/main/java/org/apache/geronimo/myfaces/deployment/MyFacesModuleBuilderExtension.java
> Thu Nov  4 23:21:49 2010
> @@ -410,7 +410,7 @@ public class MyFacesModuleBuilderExtensi
>         if (webInfClassesDirectory.exists() &&
> webInfClassesDirectory.isDirectory()) {
>             for (File file : webInfClassesDirectory.listFiles()) {
>                 String fileName = file.getName();
> -                if (fileName.equals("META-INF/faces-cofig.xml") ||
> (fileName.startsWith("META-INF/") &&
> fileName.endsWith(".faces-config.xml"))) {
> +                if (fileName.equals("faces-config.xml") ||
> fileName.endsWith(".faces-config.xml")) {
>                     //TODO Double check the relative jar file path once EAR
> is really supported
>                     String filePath = "WEB-INF/classes/META-INF/" +
> fileName;
>                     metaInfConfigurationResources.add(new
> ConfigurationResource(null, filePath, filePath));
> @@ -422,13 +422,26 @@ public class MyFacesModuleBuilderExtensi
>         if (baseDirectory.exists() && baseDirectory.isDirectory()) {
>             for (File file : baseDirectory.listFiles()) {
>                 String fileName = file.getName();
> -                if (fileName.equals("META-INF/faces-cofig.xml") ||
> (fileName.startsWith("META-INF/") &&
> fileName.endsWith(".faces-config.xml"))) {
> +                if (fileName.equals("faces-config.xml") ||
> fileName.endsWith(".faces-config.xml")) {
>                     //TODO Double check the relative jar file path once EAR
> is really supported
>                     String filePath = "META-INF/" + fileName;
>                     metaInfConfigurationResources.add(new
> ConfigurationResource(null, filePath, filePath));
>                 }
>             }
>         }
> +        //default WEB-INF/faces-config.xml is handled by myfaces no matter
> what we do???
> +//        //4. WEB-INF folder
> +//        baseDirectory = new File(earContext.getBaseDir() +
> File.separator + "WEB-INF");
> +//        if (baseDirectory.exists() && baseDirectory.isDirectory()) {
> +//            for (File file : baseDirectory.listFiles()) {
> +//                String fileName = file.getName();
> +//                if (fileName.equals("faces-config.xml") ||
> fileName.endsWith(".faces-config.xml")) {
> +//                    //TODO Double check the relative jar file path once
> EAR is really supported
> +//                    String filePath = "WEB-INF/" + fileName;
> +//                    metaInfConfigurationResources.add(new
> ConfigurationResource(null, filePath, filePath));
> +//                }
> +//            }
> +//        }
>         return metaInfConfigurationResources;
>     }
>
>
>
>


-- 
Ivan

Mime
View raw message