from 'headers output' import-packages looks suspicious where i dont
see javax.face....
karaf@root> headers 219
mc (219)
--------
Manifest-Version = 1.0
Bnd-LastModified = 1299142961025
Archiver-Version = Plexus Archiver
Tool = Bnd-0.0.357
Originally-Created-By = Apache Maven
WAR-URL = file:/C:/Users/dan.tran/dev/karaf/apache-karaf-2.2.0/deploy/mc.war
Built-By = dan.tran
Web-ContextPath = /mc
Generated-By-Ops4j-Pax-From =
file:/C:/Users/dan.tran/dev/karaf/apache-karaf-2.2.0/deploy/mc.war
Build-Jdk = 1.6.0_22
Created-By = 1.6.0_22 (Sun Microsystems Inc.)
Bundle-Name = mc
Bundle-SymbolicName = mc
Bundle-Version = 0.0.0
Bundle-ManifestVersion = 2
Bundle-ClassPath =
WEB-INF/classes,WEB-INF/lib/antlr-2.7.6.jar,WEB-INF/lib/aopalliance-1.0.jar,WEB-INF/lib/asm-3.1.jar,WEB-INF/lib/aspectjrt-1.5.4.jar,WEB-INF/lib/aspectjtools-1.5.4.jar,WEB-INF/lib/bluesky-1.0.0.jar,WEB-INF/lib/cglib-2.2.jar,WEB-INF/lib/cglib-nodep-2.2.jar,WEB-INF/lib/commons-beanut
ils-1.8.3.jar,WEB-INF/lib/commons-codec-1.3.jar,WEB-INF/lib/commons-collections-3.1.jar,WEB-INF/lib/commons-dbcp-1.4.jar,WEB-INF/lib/commons-digester-1.8.jar,WEB-INF/lib/commons-fileupload-1.2.2.jar,WEB-INF/lib/commons-io-1.4.jar,WEB-INF/lib/commons-lang-2.5.jar,WEB-INF/lib/commons-logging-1.1.1.jar
,WEB-INF/lib/commons-pool-1.5.4.jar,WEB-INF/lib/derby-10.6.2.1.jar,WEB-INF/lib/dom4j-1.6.1.jar,WEB-INF/lib/h2-1.2.147.jar,WEB-INF/lib/hibernate-commons-annotations-3.2.0.Final.jar,WEB-INF/lib/hibernate-core-3.6.1.Final.jar,WEB-INF/lib/hibernate-entitymanager-3.6.1.Final.jar,WEB-INF/lib/hibernate-jpa
-2.0-api-1.0.0.Final.jar,WEB-INF/lib/javassist-3.12.0.GA.jar,WEB-INF/lib/jcl-over-slf4j-1.6.1.jar,WEB-INF/lib/jcommon-1.0.16.jar,WEB-INF/lib/jfreechart-1.0.13.jar,WEB-INF/lib/jstl-api-1.2.jar,WEB-INF/lib/jstl-impl-1.2.jar,WEB-INF/lib/jta-1.1.jar,WEB-INF/lib/log4j-1.2.14.jar,WEB-INF/lib/mc-common-1.0
.0.CI-SNAPSHOT.jar,WEB-INF/lib/mc-config-1.0.0.CI-SNAPSHOT.jar,WEB-INF/lib/mc-dbsetup-1.0.0.CI-SNAPSHOT.jar,WEB-INF/lib/mc-mgmt-1.0.0.CI-SNAPSHOT.jar,WEB-INF/lib/mc-theme-1.0.0.CI-SNAPSHOT.jar,WEB-INF/lib/mc-user-1.0.0.CI-SNAPSHOT.jar,WEB-INF/lib/myfaces-api-2.0.4.jar,WEB-INF/lib/myfaces-impl-2.0.4.
jar,WEB-INF/lib/plexus-utils-2.0.5.jar,WEB-INF/lib/primefaces-2.2.1.jar,WEB-INF/lib/shiro-core-1.1.0.jar,WEB-INF/lib/shiro-spring-1.1.0.jar,WEB-INF/lib/shiro-web-1.1.0.jar,WEB-INF/lib/slf4j-api-1.6.1.jar,WEB-INF/lib/slf4j-log4j12-1.6.1.jar,WEB-INF/lib/spring-aop-3.0.5.RELEASE.jar,WEB-INF/lib/spring-
asm-3.0.5.RELEASE.jar,WEB-INF/lib/spring-beans-3.0.5.RELEASE.jar,WEB-INF/lib/spring-context-3.0.5.RELEASE.jar,WEB-INF/lib/spring-core-3.0.5.RELEASE.jar,WEB-INF/lib/spring-expression-3.0.5.RELEASE.jar,WEB-INF/lib/spring-jdbc-3.0.5.RELEASE.jar,WEB-INF/lib/spring-orm-3.0.5.RELEASE.jar,WEB-INF/lib/sprin
g-tx-3.0.5.RELEASE.jar,WEB-INF/lib/spring-web-3.0.5.RELEASE.jar
Import-Package =
javax.accessibility;resolution:=optional,
javax.activation;resolution:=optional,
javax.annotation;resolution:=optional,
javax.crypto;resolution:=optional,
javax.crypto.spec;resolution:=optional,
javax.ejb;resolution:=optional,
javax.el;resolution:=optional,
javax.imageio;resolution:=optional,
javax.imageio.metadata;resolution:=optional,
-Dan
On Thu, Mar 3, 2011 at 1:03 AM, Dan Tran <[email protected]> wrote:
> I am using mojarra 2.1.0-b11 and 2.0.4-b09, switching to myfaces 2.0.4
> gives me further error like this
>
> java.lang.IllegalStateException: No Factories configured for this
> Application. This happens if the faces-initialization does not work at
> all - make sure that you properly include all configuration settings
> necessary for a basic faces applic
> ck the logging output of your web application and your container for
> any exceptions!
> If you did that and find nothing, the mistake might be due to the fact
> that you use some special web-containers which do not support
> registering context-listeners via TLD files and a context listener is
> not setup in your web.xml.
> A typical config looks like this;
> <listener>
> <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
> </listener>
>
> at
> javax.faces.FactoryFinder.getFactory(FactoryFinder.java:196)[219:mc:0.0.0]
>
> -D
>
>
> On Thu, Mar 3, 2011 at 12:52 AM, Charles Moulliard <[email protected]>
> wrote:
>> Hi,
>>
>> This is an issue that I experienced some weeks ago with a JSF project
>> based on PrimeFaces. Can you tell me if the JSF (spec) and
>> implementation lib are embedded into your bundle or deployed
>> separately ?
>>
>> Regards,
>>
>> Charles Moulliard
>> Apache Committer
>>
>> Blog : http://cmoulliard.blogspot.com
>> Twitter : http://twitter.com/cmoulliard
>> Linkedin : http://www.linkedin.com/in/charlesmoulliard
>> Skype: cmoulliard
>>
>>
>>
>> On Thu, Mar 3, 2011 at 9:32 AM, Dan Tran <[email protected]> wrote:
>>> ouch, I will need to temporary add simple onelines bean definitions
>>> for all the annotated beans. But that is ok
>>>
>>> NowI run into
>>>
>>> java.lang.IllegalStateException: Application was not properly
>>> initialized at startup, could not find Factory:
>>> javax.faces.context.FacesContextFactory
>>> at
>>> javax.faces.FactoryFinder$FactoryManager.getFactory(FactoryFinder.java:815)[211:mc:0.0.0]
>>> at
>>> javax.faces.FactoryFinder.getFactory(FactoryFinder.java:317)[211:mc:0.0.0]
>>> at
>>> javax.faces.webapp.FacesServlet.init(FacesServlet.java:253)[211:mc:0.0.0]
>>> at
>>> org.eclipse.jetty.servlet.ServletHolder.initServlet(ServletHolder.java:432)[199:org.eclipse.jetty.servlet:7.2.2.v20101205]
>>> at
>>> org.eclipse.jetty.servlet.ServletHolder.doStart(ServletHolder.java:260)[199:org.eclipse.jetty.servlet:7.2.2.v20101205]
>>> at
>>> org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)[193:org.eclipse.jetty.util:7.2.2.v20101205]
>>> at
>>> org.eclipse.jetty.servlet.ServletHandler.initialize(ServletHandler.java:762)[199:org.eclipse.jetty.servlet:7.2.2.v20101205]
>>>
>>> Big Thanks
>>>
>>> -Dan
>>>
>>> On Wed, Mar 2, 2011 at 11:52 PM, Charles Moulliard <[email protected]>
>>> wrote:
>>>> Hi Dan,
>>>>
>>>> Can you make a test using <context:annotation-config/> instead of
>>>> <context:component-scan> (see here for more info -
>>>> http://wiki.ops4j.org/display/ops4j/Pax+Web+Extender+-+War+-+Examples)
>>>> to see if the error is still there ?
>>>>
>>>> Regards,
>>>>
>>>> Charles
>>>>
>>>>
>>>> On Thu, Mar 3, 2011 at 8:33 AM, Dan Tran <[email protected]> wrote:
>>>>> Hi Charles , thank you for looking into this issue:
>>>>>
>>>>> Here is the stack trace
>>>>>
>>>>> Problem accessing /mc/index.jsp. Reason:
>>>>>
>>>>> Error creating bean with name 'shiroFilter' defined in
>>>>> ServletContext resource [/WEB-INF/applicationContext.xml]: Cannot
>>>>> resolve reference to bean 'securityManager' while setting bean
>>>>> property 'securityManager'; nested exception is
>>>>> org.springframework.beans.factory.BeanCreationException: Error
>>>>> creating bean with name 'securityManager' defined in ServletContext
>>>>> resource [/WEB-INF/applicationContext.xml]: Cannot resolve reference
>>>>> to bean 'localRealm' while setting bean property 'realm'; nested
>>>>> exception is
>>>>> org.springframework.beans.factory.NoSuchBeanDefinitionException:
>>>>> No bean named 'localRealm' is defined
>>>>> at
>>>>> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328)[93:mc:0.0.0]
>>>>> at
>>>>> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:106)[93:mc:0.0.0]
>>>>>
>>>>>
>>>>> This means my 'shiroBean' is defined in applicationContext.xml which
>>>>> needs to reference 'securityContext' , also defined in the same Spring
>>>>> xml file, which then requires 'localRealm' bean which is annotated via
>>>>> Spring @Component.
>>>>>
>>>>> If I manually add my 'localRealm' to the Spring XML, then same issue
>>>>> happens on other annotated bean.
>>>>>
>>>>> It sound like ' <context:component-scan ...' got muted ( no problem
>>>>> under Virgo )
>>>>>
>>>>> I you see no hints from this log, i will try to scale down the project
>>>>> and post it
>>>>>
>>>>> Thanks
>>>>>
>>>>> -D
>>>>>
>>>>>
>>>>> On Wed, Mar 2, 2011 at 10:44 PM, Charles Moulliard <[email protected]>
>>>>> wrote:
>>>>>> Hi Dan,
>>>>>>
>>>>>> Can you provide us the exception generated in the stack trace of Karaf
>>>>>> (using command log:display -n 10) and maybe a test case or the war
>>>>>> used to reproduce the error and check what happens ?
>>>>>>
>>>>>> Regards,
>>>>>>
>>>>>> Charles Moulliard
>>>>>>
>>>>>> Sr. Principal Solution Architect - FuseSource
>>>>>> Apache Committer
>>>>>>
>>>>>> Blog : http://cmoulliard.blogspot.com
>>>>>> Twitter : http://twitter.com/cmoulliard
>>>>>> Linkedin : http://www.linkedin.com/in/charlesmoulliard
>>>>>> Skype: cmoulliard
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Thu, Mar 3, 2011 at 3:53 AM, Dan Tran <[email protected]> wrote:
>>>>>>> Hi,
>>>>>>>
>>>>>>> I have a JSF 2.0 + Spring + JPA 2.0 standalone webapp loading fine on
>>>>>>> Eclipse Virgo 2.1[1], but not with Karaf. It seems like no Spring
>>>>>>> annotated beans can be created. No problem creating beans via XML
>>>>>>> configuration thou.
>>>>>>>
>>>>>>> Any advice for me to trouble this issue? or Have any one successfully
>>>>>>> get this combination working?
>>>>>>>
>>>>>>> Big thanks ahead
>>>>>>>
>>>>>>> -Dan
>>>>>>>
>>>>>>> PS: I see the same issue with Karaf 2.1.4
>>>>>>>
>>>>>>> [1]
>>>>>>> http://www.eclipse.org/forums/index.php?t=msg&goto=657502&S=b35e653a8e2ccc6da8734a1cfb0eed16
>>>>>>>
>>>>>>
>>>>>
>>>>
>>>
>>
>