wpgsh / cloud4water

Apache License 2.0
0 stars 0 forks source link

karaf problem #5

Closed yedengfang closed 8 years ago

yedengfang commented 8 years ago

@alexlukichev I'm xintong yu,charge of the user register module development.

when I put a .kar document into ..\apache-karaf-4.0.5\deploy ,the karaf simetimes may have error as following: image image image image image image

when I restart the karaf , the karaf can run well and no problem display . This problem has been in existence for a long time. everytime I restart to solve. karaf.log

alexlukichev commented 8 years ago

Well, it's just an exception stack trace. Any other symptoms that you are experiencing?

asd1245dss commented 8 years ago

It offen occured when we restart karaf,sometimes it may start sucessfully but sometimes wrong.You can see the attachment. karaf.log

alexlukichev commented 8 years ago

Are you experiencing any other problems besides errors in the logs? E.g. some component fails to come up, etc.

asd1245dss commented 8 years ago

image image image We will see the warnings and errors three or four times every day when we first start the karaf and repeat when we redeploy our kar file(More times the redeploy would be failed after a long time).But if we clean the karaf data folder and deploy,everything is ok,redeploy will soon be sucessfully without theses errors.This is the most notable effect to us.

alexlukichev commented 8 years ago

Next time when you see the problem, please, do this:

  1. attach a log from data/log
  2. karaf console run:
    • la
    • service:list
    • scr:list
    • bundle:diag
alexlukichev commented 8 years ago

I've made several changes to service definitions. The system should be a bit more stable now. It still spits out some exceptions during re-deploy but they should not cause any trouble IMO.

Please also note that due to initialization function in H2TxAwareEntityManager the initialization of services takes pretty long time. Before all DDL queries are executed some dependencies may be in unsatisfied state and thus services not available.

asd1245dss commented 8 years ago

Like this bundle ?(I 've pull your latest commit and do the above commands,I just paster part of my console,there are some exceptions at the last) image service.id = 206 service.scope = singleton Provided by : net.wapwag.authn.ui (151) Used by: OPS4J Pax Web - Extender - WAR (137) OSGi JAX-RS Connector (71)

[org.ops4j.pax.web.service.spi.ServerControllerFactory]

service.bundleid = 139 service.id = 151 service.scope = singleton Provided by : OPS4J Pax Web - Jetty (139) Used by: OPS4J Pax Web - Runtime (141) OSGi JAX-RS Connector (71)

[org.ops4j.pax.web.service.spi.ServletListener]

service.bundleid = 96 service.id = 155 service.scope = singleton Provided by : Apache Karaf :: HTTP :: Core (96) Used by: OPS4J Pax Web - Runtime (141) OSGi JAX-RS Connector (71)

[org.ops4j.pax.web.service.spi.ServletListener]

service.bundleid = 141 service.id = 152 service.scope = singleton Provided by : OPS4J Pax Web - Runtime (141) Used by: OPS4J Pax Web - Runtime (141) OSGi JAX-RS Connector (71)

[org.ops4j.pax.web.service.spi.ServletListener]

service.bundleid = 141 service.id = 153 service.scope = singleton Provided by : OPS4J Pax Web - Runtime (141) Used by: OPS4J Pax Web - Runtime (141) OSGi JAX-RS Connector (71)

[org.ops4j.pax.web.service.spi.WarManager]

service.bundleid = 137 service.id = 160 service.scope = singleton Provided by : OPS4J Pax Web - Extender - WAR (137) Used by: Apache Karaf :: Web :: Core (100) OSGi JAX-RS Connector (71)

[org.ops4j.pax.web.service.spi.WebListener]

service.bundleid = 100 service.id = 161 service.scope = singleton Provided by : Apache Karaf :: Web :: Core (100) Used by: OPS4J Pax Web - Extender - WAR (137) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.bundle.CollisionHook]

service.bundleid = 9 service.id = 21 service.scope = singleton Provided by : Apache Karaf :: Features :: Core (9) Used by: OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.bundle.EventHook]

service.bundleid = 9 service.id = 23 service.scope = singleton Provided by : Apache Karaf :: Features :: Core (9) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.bundle.EventHook]

service.bundleid = 13 service.id = 37 service.scope = singleton Provided by : Apache Aries Blueprint Core (13) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.bundle.FindHook]

service.bundleid = 9 service.id = 22 service.scope = singleton Provided by : Apache Karaf :: Features :: Core (9) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.resolver.ResolverHookFactory]

service.bundleid = 9 service.id = 20 service.scope = singleton Provided by : Apache Karaf :: Features :: Core (9) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.service.EventHook]

service.bundleid = 9 service.id = 25 service.scope = singleton Provided by : Apache Karaf :: Features :: Core (9) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.service.FindHook]

service.bundleid = 9 service.id = 24 service.scope = singleton Provided by : Apache Karaf :: Features :: Core (9) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.weaving.WeavingHook]

osgi.woven.packages = org.apache.aries.proxy.weaving,org.apache.aries.proxy service.bundleid = 21 service.id = 35 service.scope = singleton Provided by : Apache Aries Proxy Service (21) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.weaving.WeavingHook]

service.bundleid = 86 service.id = 184 service.ranking = 2147483647 service.scope = singleton Provided by : Apache Aries JPA container (86) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.framework.hooks.weaving.WeavingHook]

service.bundleid = 88 service.id = 141 service.scope = singleton Provided by : Apache Aries SPI Fly Dynamic Weaving Bundle (88) Used by: System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.service.blueprint.container.BlueprintContainer]

osgi.blueprint.container.symbolicname = org.apache.aries.blueprint.cm osgi.blueprint.container.version = 1.0.8 service.bundleid = 12 service.id = 50 service.scope = singleton Provided by : Apache Aries Blueprint CM (12) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.blueprint.container.BlueprintContainer]

osgi.blueprint.container.symbolicname = org.apache.aries.blueprint.core osgi.blueprint.container.version = 1.6.1 service.bundleid = 13 service.id = 45 service.scope = singleton Provided by : Apache Aries Blueprint Core (13) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.blueprint.container.BlueprintContainer]

osgi.blueprint.container.symbolicname = org.apache.karaf.jaas.blueprint.config osgi.blueprint.container.version = 4.0.5 service.bundleid = 33 service.id = 111 service.scope = singleton Provided by : Apache Karaf :: JAAS :: Blueprint :: Config (33) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.blueprint.container.BlueprintContainer]

osgi.blueprint.container.symbolicname = org.apache.karaf.shell.core osgi.blueprint.container.version = 4.0.5 service.bundleid = 44 service.id = 61 service.scope = singleton Provided by : Apache Karaf :: Shell :: Core (44) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.blueprint.container.BlueprintContainer]

osgi.blueprint.container.symbolicname = net.wapwag.authn.h2 osgi.blueprint.container.version = 0.1.0.SNAPSHOT service.bundleid = 148 service.id = 205 service.scope = singleton Provided by : net.wapwag.authn.h2 (148) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.blueprint.container.BlueprintListener]

service.bundleid = 17 service.id = 122 service.scope = singleton Provided by : Apache Aries JMX Blueprint Core (17) Used by: Apache Aries Blueprint Core (13) OSGi JAX-RS Connector (71)

[org.osgi.service.blueprint.container.BlueprintListener, org.apache.karaf.bundle.core.BundleStateService, org.osgi.framework.BundleListener]

service.bundleid = 23 service.id = 74 service.scope = singleton Provided by : Apache Karaf :: Bundle :: BlueprintStateService (23) Used by: Apache Karaf :: Bundle :: Core (24) Apache Aries Blueprint Core (13) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ConfigurationAdmin]

service.bundleid = 7 service.description = Configuration Admin Service Specification 1.2 Implementation service.id = 14 service.pid = org.apache.felix.cm.ConfigurationAdmin service.scope = bundle service.vendor = Apache Software Foundation Provided by : Apache Felix Configuration Admin Service (7) Used by: Apache Karaf :: Log :: Core (38) Apache Karaf :: SCR :: Management MBeans (99) Apache Karaf :: ConfigAdmin :: Core (25) net.wapwag.authn.dao (147) net.wapwag.authn (146) Apache Karaf :: Features :: Core (9) Apache Aries JMX Core (18) jaxrs-utils (145) Apache Karaf :: Management (39) net.wapwag.authn.rest (150) Apache Felix File Install (8) net.wapwag.authn.h2.hibernate (149) Apache Karaf :: Shell :: Core (44) Apache Karaf :: Bundle :: Core (24) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ConfigurationListener, org.apache.felix.fileinstall.ArtifactListener, org.apache.felix.fileinstall.ArtifactInstaller]

service.bundleid = 8 service.id = 18 service.scope = singleton Provided by : Apache Felix File Install (8) Used by: Apache Felix File Install (8) Apache Felix Configuration Admin Service (7) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ConfigurationListener]

service.bundleid = 25 service.id = 80 service.scope = singleton Provided by : Apache Karaf :: ConfigAdmin :: Core (25) Used by: Apache Felix Configuration Admin Service (7) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ConfigurationListener]

service.bundleid = 44 service.id = 56 service.scope = singleton Provided by : Apache Karaf :: Shell :: Core (44) Used by: Apache Felix Configuration Admin Service (7) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ConfigurationListener]

service.bundleid = 93 service.description = Declarative Services Configuration Support Listener service.id = 135 service.scope = singleton service.vendor = The Apache Software Foundation Provided by : Apache Felix Declarative Services (93) Used by: Apache Felix Configuration Admin Service (7) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService, org.osgi.service.metatype.MetaTypeProvider]

service.bundleid = 3 service.id = 7 service.pid = org.apache.felix.eventadmin.impl.EventAdmin service.scope = singleton Provided by : Apache Karaf :: OSGi Services :: EventAdmin (3) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 4 service.id = 9 service.pid = org.ops4j.pax.url.mvn service.scope = singleton Provided by : OPS4J Pax Url - aether: (4) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 9 service.id = 28 service.pid = org.apache.karaf.features.repos service.scope = singleton Provided by : Apache Karaf :: Features :: Core (9) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 18 service.id = 90 service.pid = org.apache.aries.jmx.framework.StateConfig service.scope = singleton Provided by : Apache Aries JMX Core (18) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 36 service.id = 82 service.pid = org.apache.karaf.jaas service.scope = singleton Provided by : Apache Karaf :: JAAS :: Modules (36) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 37 service.id = 96 service.pid = org.apache.karaf.kar service.scope = singleton Provided by : Apache Karaf :: KAR :: Core (37) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 38 service.id = 62 service.pid = org.apache.karaf.log service.scope = singleton Provided by : Apache Karaf :: Log :: Core (38) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 39 service.id = 95 service.pid = org.apache.karaf.management service.scope = singleton Provided by : Apache Karaf :: Management (39) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 45 service.id = 87 service.pid = org.apache.karaf.shell service.scope = singleton Provided by : Apache Karaf :: Shell :: SSH (45) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 51 service.id = 32 service.pid = org.ops4j.pax.url.wrap service.scope = singleton Provided by : OPS4J Pax Url - wrap: (51) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 71 service.id = 179 service.pid = com.eclipsesource.jaxrs.connector service.scope = singleton Provided by : OSGi JAX-RS Connector (71) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 86 service.id = 204 service.pid = org.apache.aries.jpa.user-jpa service.scope = singleton Provided by : Apache Aries JPA container (86) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 91 service.id = 176 service.pid = org.apache.aries.transaction service.scope = singleton Provided by : Apache Aries Transaction Manager (91) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 93 service.description = SCR Configurator service.id = 138 service.pid = org.apache.felix.scr.ScrService service.scope = bundle service.vendor = The Apache Software Foundation Provided by : Apache Felix Declarative Services (93) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 134 service.id = 148 service.pid = org.ops4j.pax.url.war service.scope = singleton Provided by : OPS4J Pax Url - war (134) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedService]

service.bundleid = 141 service.id = 154 service.pid = org.ops4j.pax.web service.scope = singleton Provided by : OPS4J Pax Web - Runtime (141) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedServiceFactory]

service.bundleid = 8 service.id = 17 service.pid = org.apache.felix.fileinstall service.scope = singleton Provided by : Apache Felix File Install (8) Used by: Apache Felix Configuration Admin Service (7) Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedServiceFactory]

service.bundleid = 132 service.id = 183 service.pid = org.ops4j.datasource service.scope = singleton Provided by : OPS4J Pax JDBC Config (132) Used by: Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.cm.ManagedServiceFactory]

service.bundleid = 155 service.description = Apache HTTP Client Proxy Configuration Factory service.id = 201 service.pid = org.apache.http.proxyconfigurator service.scope = singleton service.vendor = {Bnd-LastModified=1456070977471, Build-Jdk=1.7.0_75, Built-By=oleg, Bundle-Activator=org.apache.http.osgi.impl.HttpProxyConfigurationActivator, Bundle-Description=Apache HttpComponents Client (OSGi bundle), Bundle-DocURL=http://www.apache.org/, Bundle-License=http://www.apache.org/licenses/LICENSE-2.0.txt, Bundle-ManifestVersion=2, Bundle-Name=Apache Apache HttpClient OSGi bundle, Bundle-SymbolicName=org.apache.httpcomponents.httpclient, Bundle-Vendor=The Apache Software Foundation, Bundle-Version=4.5.2, Created-By=Apache Maven Bundle Plugin, Embed-Dependency=*;scope=compile|runtime;inline=true, Export-Package=org.apache.http.auth;version="4.5.2";uses:="org.apache.http,org.apache.http.config,org.apache.http.params,org.apache.http.protocol,org.ietf.jgss",org.apache.http.auth.params;version="4.5.2";uses:="org.apache.http.params",org.apache.http.cookie;version="4.5.2";uses:="org.apache.http,org.apache.http.config,org.apache.http.params,org.apache.http.protocol",org.apache.http.cookie.params;version="4.5.2";uses:="org.apache.http.params",org.apache.http.conn;version="4.5.2";uses:="javax.net.ssl,org.apache.http,org.apache.http.concurrent,org.apache.http.config,org.apache.http.conn.routing,org.apache.http.conn.scheme,org.apache.http.entity,org.apache.http.params,org.apache.http.protocol",org.apache.http.conn.params;version="4.5.2";uses:="org.apache.http,org.apache.http.conn.routing,org.apache.http.params",org.apache.http.conn.routing;version="4.5.2";uses:="org.apache.http,org.apache.http.protocol",org.apache.http.conn.scheme;version="4.5.2";uses:="org.apache.http,org.apache.http.conn,org.apache.http.params",org.apache.http.conn.socket;version="4.5.2";uses:="org.apache.http,org.apache.http.protocol",org.apache.http.conn.ssl;version="4.5.2";uses:="javax.net.ssl,org.apache.http,org.apache.http.conn,org.apache.http.conn.scheme,org.apache.http.conn.socket,org.apache.http.conn.util,org.apache.http.params,org.apache.http.protocol,org.apache.http.ssl",org.apache.http.conn.util;version="4.5.2",org.apache.http.client;version="4.5.2";uses:="org.apache.http,org.apache.http.auth,org.apache.http.client.methods,org.apache.http.conn,org.apache.http.conn.routing,org.apache.http.cookie,org.apache.http.params,org.apache.http.protocol",org.apache.http.client.cache;version="4.5.2";uses:="org.apache.http,org.apache.http.client.protocol,org.apache.http.protocol",org.apache.http.client.config;version="4.5.2";uses:="org.apache.http",org.apache.http.client.entity;version="4.5.2";uses:="org.apache.http,org.apache.http.entity",org.apache.http.client.fluent;version="4.5.2";uses:="org.apache.http,org.apache.http.auth,org.apache.http.client,org.apache.http.concurrent,org.apache.http.conn.scheme,org.apache.http.entity,org.apache.http.impl.client",org.apache.http.client.methods;version="4.5.2";uses:="org.apache.http,org.apache.http.client.config,org.apache.http.concurrent,org.apache.http.conn,org.apache.http.message,org.apache.http.params",org.apache.http.client.params;version="4.5.2";uses:="org.apache.http,org.apache.http.auth.params,org.apache.http.client.config,org.apache.http.conn.params,org.apache.http.cookie.params,org.apache.http.params",org.apache.http.client.protocol;version="4.5.2";uses:="org.apache.http,org.apache.http.auth,org.apache.http.client,org.apache.http.client.config,org.apache.http.client.entity,org.apache.http.config,org.apache.http.conn.routing,org.apache.http.cookie,org.apache.http.protocol",org.apache.http.client.utils;version="4.5.2";uses:="org.apache.http,org.apache.http.client,org.apache.http.client.methods,org.apache.http.conn.routing,org.apache.http.util",org.apache.http.entity.mime;version="4.5.2";uses:="org.apache.http,org.apache.http.entity,org.apache.http.entity.mime.content",org.apache.http.entity.mime.content;version="4.5.2";uses:="org.apache.http.entity",org.apache.http.impl.auth;version="4.5.2";uses:="org.apache.commons.logging,org.apache.http,org.apache.http.auth,org.apache.http.client,org.apache.http.params,org.apache.http.protocol,org.apache.http.util,org.ietf.jgss",org.apache.http.impl.cookie;version="4.5.2";uses:="org.apache.http,org.apache.http.conn.util,org.apache.http.cookie,org.apache.http.message,org.apache.http.params,org.apache.http.protocol,org.apache.http.util",org.apache.http.impl.conn;version="4.5.2";uses:="javax.net.ssl,org.apache.commons.logging,org.apache.http,org.apache.http.config,org.apache.http.conn,org.apache.http.conn.routing,org.apache.http.conn.scheme,org.apache.http.conn.socket,org.apache.http.entity,org.apache.http.impl,org.apache.http.impl.io,org.apache.http.io,org.apache.http.message,org.apache.http.params,org.apache.http.pool,org.apache.http.protocol,org.apache.http.util",org.apache.http.impl.conn.tsccm;version="4.5.2";uses:="org.apache.http.conn,org.apache.http.conn.params,org.apache.http.conn.routing,org.apache.http.conn.scheme,org.apache.http.impl.conn,org.apache.http.params",org.apache.http.impl.execchain;version="4.5.2";uses:="org.apache.http,org.apache.http.client,org.apache.http.client.methods,org.apache.http.client.protocol,org.apache.http.conn,org.apache.http.conn.routing,org.apache.http.protocol",org.apache.http.impl.client;version="4.5.2";uses:="javax.net.ssl,org.apache.commons.logging,org.apache.http,org.apache.http.auth,org.apache.http.client,org.apache.http.client.config,org.apache.http.client.entity,org.apache.http.client.methods,org.apache.http.concurrent,org.apache.http.config,org.apache.http.conn,org.apache.http.conn.routing,org.apache.http.conn.socket,org.apache.http.conn.ssl,org.apache.http.conn.util,org.apache.http.cookie,org.apache.http.impl,org.apache.http.impl.auth,org.apache.http.impl.execchain,org.apache.http.message,org.apache.http.params,org.apache.http.pool,org.apache.http.protocol",org.apache.http.impl.client.cache;version="4.5.2";uses:="org.apache.http,org.apache.http.client,org.apache.http.client.cache,org.apache.http.client.methods,org.apache.http.client.protocol,org.apache.http.conn,org.apache.http.conn.routing,org.apache.http.impl.client,org.apache.http.impl.execchain,org.apache.http.params,org.apache.http.protocol",org.apache.http.impl.client.cache.ehcache;version="4.5.2";uses:="net.sf.ehcache,org.apache.http.client.cache,org.apache.http.impl.client.cache",org.apache.http.impl.client.cache.memcached;version="4.5.2";uses:="net.spy.memcached,org.apache.http.client.cache,org.apache.http.impl.client.cache",org.apache.http.osgi.services;version="4.5.2";uses:="org.apache.http.impl.client", Implementation-Build=${scmBranch}@r${buildNumber}; 2016-02-21 17:03:53+0100, Implementation-Title=HttpComponents Apache HttpClient OSGi bundle, Implementation-Vendor=The Apache Software Foundation, Implementation-Vendor-Id=org.apache, Implementation-Version=4.5.2, Import-Package=javax.crypto,javax.crypto.spec,javax.naming,javax.naming.directory,javax.naming.ldap,javax.net,javax.net.ssl,javax.security.auth.x500,org.ietf.jgss,org.osgi.framework;version="[1.5,2)",org.osgi.service.cm;version="[1.3,2)",org.apache.commons.logging;version="[1.1.0,1.3.0)",org.apache.http;version="[4.4.0,4.5.0)",org.apache.http.config;version="[4.4.0,4.5.0)",org.apache.http.concurrent;version="[4.4.0,4.5.0)",org.apache.http.entity;version="[4.4.0,4.5.0)",org.apache.http.io;version="[4.4.0,4.5.0)",org.apache.http.message;version="[4.4.0,4.5.0)",org.apache.http.params;version="[4.4.0,4.5.0)",org.apache.http.pool;version="[4.4.0,4.5.0)",org.apache.http.protocol;version="[4.4.0,4.5.0)",org.apache.http.ssl;version="[4.4.0,4.5.0)",org.apache.http.util;version="[4.4.0,4.5.0)",org.apache.http.impl;version="[4.4.0,4.5.0)",org.apache.http.impl.entity;version="[4.4.0,4.5.0)",org.apache.http.impl.io;version="[4.4.0,4.5.0)",net.sf.ehcache;resolution:=optional,net.spy.memcached;resolution:=optional,org.apache.http.impl.pool;version="[4.4.0,4.5.0)", Include-Resource=@/home/oleg/src/apache.org/httpcomponents/project-release-tools/build/repos-asf-httpcomponents-httpclient-tags-4.5.2-RC1/httpclient/target/httpclient-4.5.2.jar,@/home/oleg/.m2/repository/commons-codec/commons-codec/1.9/commons-codec-1.9.jar,@/home/oleg/src/apache.org/httpcomponents/project-release-tools/build/repos-asf-httpcomponents-httpclient-tags-4.5.2-RC1/httpmime/target/httpmime-4.5.2.jar,@/home/oleg/src/apache.org/httpcomponents/project-release-tools/build/repos-asf-httpcomponents-httpclient-tags-4.5.2-RC1/httpclient-cache/target/httpclient-cache-4.5.2.jar,@/home/oleg/src/apache.org/httpcomponents/project-release-tools/build/repos-asf-httpcomponents-httpclient-tags-4.5.2-RC1/fluent-hc/target/fluent-hc-4.5.2.jar,OSGI-INF/metatype/metatype.xml=src/main/resources/OSGI-INF/metatype/metatype.xml,OSGI-INF/metatype/metatype.properties=src/main/resources/OSGI-INF/metatype/metatype.properties,META-INF/DEPENDENCIES=target/maven-shared-archive-resources/META-INF/DEPENDENCIES,META-INF/NOTICE=target/maven-shared-archive-resources/META-INF/NOTICE,META-INF/LICENSE=target/maven-shared-archive-resources/META-INF/LICENSE, Manifest-Version=1.0, Private-Package=mozilla,org.apache.commons.codec,org.apache.commons.codec.binary,org.apache.commons.codec.digest,org.apache.commons.codec.language,org.apache.commons.codec.language.bm,org.apache.commons.codec.net,org.apache.http.osgi.impl, Specification-Title=HttpComponents Apache HttpClient OSGi bundle, Specification-Vendor=The Apache Software Foundation, Specification-Version=4.5.2, Tool=Bnd-2.1.0.20130426-122213, url=http://hc.apache.org/httpcomponents-client, X-Compile-Source-JDK=1.6, X-Compile-Target-JDK=1.6} Provided by : Apache Apache HttpClient OSGi bundle (155) Used by: Apache Felix Metatype Service (2) OSGi JAX-RS Connector (71)

[org.osgi.service.component.runtime.ServiceComponentRuntime]

service.bundleid = 93 service.id = 136 service.scope = singleton Provided by : Apache Felix Declarative Services (93) Used by: Apache Felix Declarative Services Compatibility Extension (94) OSGi JAX-RS Connector (71)

[org.osgi.service.coordinator.Coordinator]

service.bundleid = 92 service.description = Coordinator Service Implementation service.id = 171 service.scope = bundle service.vendor = The Apache Software Foundation Provided by : Apache Felix Coordinator Service (92) Used by: Apache Aries JPA support (87) OSGi JAX-RS Connector (71)

[org.osgi.service.event.EventAdmin]

service.bundleid = 3 service.id = 6 service.scope = bundle Provided by : Apache Karaf :: OSGi Services :: EventAdmin (3) Used by: OPS4J Pax Logging - Service (6) Apache Karaf :: Features :: Core (9) OPS4J Pax Web - Runtime (141) Apache Karaf :: Shell :: Core (44) Apache Aries Blueprint Core (13) OPS4J Pax Web - Extender - WAR (137) OSGi JAX-RS Connector (71) Apache Karaf :: JAAS :: Modules (36)

[org.osgi.service.http.HttpService, org.ops4j.pax.web.service.WebContainer]

felix.fileinstall.filename = file:/D:/apache-karaf-4.0.5/etc/org.ops4j.pax.web.cfg javax.servlet.context.tempdir = D:\apache-karaf-4.0.5\data\pax-web-jsp org.ops4j.pax.web.jsp.check.interval = 300 org.ops4j.pax.web.jsp.debug.info = true org.ops4j.pax.web.jsp.development = true org.ops4j.pax.web.jsp.enable.pooling = true org.ops4j.pax.web.jsp.ie.classid = clsid:8AD9C840-044E-11D1-B3E9-00805F499D93 org.ops4j.pax.web.jsp.java.encoding = UTF-8 org.ops4j.pax.web.jsp.keep.generated = true org.ops4j.pax.web.jsp.log.verbosity.level = WARNING org.ops4j.pax.web.jsp.mapped.file = false org.ops4j.pax.web.jsp.precompilation = false org.ops4j.pax.web.jsp.tagpool.max.size = 5 org.ops4j.pax.web.listening.addresses = 0.0.0.0 org.ops4j.pax.web.log.ncsa.append = true org.ops4j.pax.web.log.ncsa.dispatch = false org.ops4j.pax.web.log.ncsa.extended = true org.ops4j.pax.web.log.ncsa.format = yyyy_mm_dd.request.log org.ops4j.pax.web.log.ncsa.logtimezone = GMT org.ops4j.pax.web.log.ncsa.retaindays = 90 org.ops4j.pax.web.session.cookie = JSESSIONID org.ops4j.pax.web.session.cookie.secure = false org.ops4j.pax.web.session.timeout = 5 org.ops4j.pax.web.session.url = jsessionid org.ops4j.pax.web.ssl.clientauthneeded = false org.ops4j.pax.web.ssl.clientauthwanted = false org.ops4j.pax.web.ssl.keystore = .keystore org.ops4j.pax.web.ssl.renegotiationAllowed = true org.ops4j.pax.webssl.cyphersuites.excluded = [] org.ops4j.pax.webssl.cyphersuites.included = [] org.osgi.service.http.connector.name = default org.osgi.service.http.enabled = true org.osgi.service.http.port = 8181 org.osgi.service.http.port.secure = 8443 org.osgi.service.http.secure.connector.name = secureDefault org.osgi.service.http.secure.enabled = false org.osgi.service.http.useNIO = true service.bundleid = 141 service.id = 174 service.pid = org.ops4j.pax.web service.scope = bundle Provided by : OPS4J Pax Web - Runtime (141) Used by: net.wapwag.authn.ui (151) OSGi JAX-RS Connector (71)

[org.osgi.service.jdbc.DataSourceFactory]

osgi.jdbc.driver.class = org.h2.Driver osgi.jdbc.driver.name = H2 osgi.jdbc.driver.version = 1.3.172 service.bundleid = 131 service.id = 169 service.scope = singleton Provided by : H2 Database Engine (131) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.jdbc.DataSourceFactory]

osgi.jdbc.driver.class = com.mysql.jdbc.Driver osgi.jdbc.driver.name = mysql service.bundleid = 133 service.id = 170 service.scope = singleton Provided by : OPS4J Pax JDBC MySQL Driver Adapter (133) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.jndi.JNDIContextManager]

service.bundleid = 80 service.id = 167 service.scope = bundle Provided by : Apache Aries JNDI Core (80) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.jndi.JNDIProviderAdmin]

service.bundleid = 80 service.id = 165 service.scope = bundle Provided by : Apache Aries JNDI Core (80) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.jpa.EntityManagerFactoryBuilder]

osgi.unit.name = user-jpa osgi.unit.provider = org.hibernate.jpa.HibernatePersistenceProvider osgi.unit.version = 0.1.0.SNAPSHOT service.bundleid = 86 service.id = 197 service.scope = singleton Provided by : Apache Aries JPA container (86) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.log.LogReaderService]

service.bundleid = 6 service.id = 133 service.ranking = 1 service.scope = singleton Provided by : OPS4J Pax Logging - Service (6) Used by: Apache Karaf :: OSGi Services :: EventAdmin (3) OSGi JAX-RS Connector (71)

[org.osgi.service.log.LogService, org.knopflerfish.service.log.LogService, org.ops4j.pax.logging.PaxLoggingService, org.osgi.service.cm.ManagedService]

service.bundleid = 6 service.id = 134 service.pid = org.ops4j.pax.logging service.ranking = 1 service.scope = bundle Provided by : OPS4J Pax Logging - Service (6) Used by: Apache Karaf :: Log :: Core (38) Apache Karaf :: SCR :: Management MBeans (99) net.wapwag.authn.dao (147) net.wapwag.authn (146) Apache Felix Declarative Services (93) OPS4J Pax Web - Runtime (141) Apache Aries JMX Core (18) jaxrs-utils (145) net.wapwag.authn.rest (150) OPS4J Pax Logging - API (5) Apache Felix Configuration Admin Service (7) net.wapwag.authn.h2.hibernate (149) OPS4J Pax Web - Extender - WAR (137) Apache Felix Metatype Service (2) Apache Aries SPI Fly Dynamic Weaving Bundle (88) OSGi JAX-RS Connector (71)

[org.osgi.service.metatype.MetaTypeService]

service.bundleid = 2 service.description = MetaTypeService Specification 1.2 Implementation service.id = 5 service.pid = org.apache.felix.metatype.MetaTypeService service.scope = singleton service.vendor = Apache Software Foundation Provided by : Apache Felix Metatype Service (2) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.packageadmin.PackageAdmin]

service.bundleid = 0 service.id = 2 service.scope = singleton Provided by : System Bundle (0) Used by: Apache Aries JMX Core (18) OPS4J Pax Web - Jetty (139) OPS4J Pax Web - Extender - WAR (137) OSGi JAX-RS Connector (71)

[org.osgi.service.resolver.Resolver]

service.bundleid = 0 service.id = 1 service.scope = singleton Provided by : System Bundle (0) Used by: Apache Karaf :: Features :: Core (9) OSGi JAX-RS Connector (71)

[org.osgi.service.startlevel.StartLevel]

service.bundleid = 0 service.id = 3 service.scope = singleton Provided by : System Bundle (0) Used by: Apache Aries JMX Core (18) OSGi JAX-RS Connector (71)

[org.osgi.service.url.URLStreamHandlerService]

service.bundleid = 4 service.id = 10 service.scope = singleton url.handler.protocol = mvn Provided by : OPS4J Pax Url - aether: (4) Used by: Apache Karaf :: Features :: Core (9) System Bundle (0) OSGi JAX-RS Connector (71)

[org.osgi.service.url.URLStreamHandlerService]

service.bundleid = 8 service.id = 16 service.scope = singleton url.handler.protocol = jardir Provided by : Apache Felix File Install (8) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.url.URLStreamHandlerService]

service.bundleid = 26 service.id = 51 service.scope = singleton url.handler.protocol = blueprint Provided by : Apache Karaf :: Deployer :: Blueprint (26) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.url.URLStreamHandlerService]

service.bundleid = 27 service.id = 54 service.scope = singleton url.handler.protocol = feature Provided by : Apache Karaf :: Deployer :: Features (27) Used by: OSGi JAX-RS Connector (71)

[org.osgi.service.url.URLStreamHandlerService]

service.bundleid = 51 service.id = 31 service.scope = singleton url.handler.protocol = [wrap] Provided by : OPS4J Pax Url - wrap: (51) Used by: System Bundle (0) Apache Karaf :: Deployer :: Wrap Non OSGi Jar (29) OSGi JAX-RS Connector (71)

[org.osgi.service.url.URLStreamHandlerService]

service.bundleid = 134 service.id = 147 service.scope = singleton url.handler.protocol = [war, war-i, warref, webbundle] Provided by : OPS4J Pax Url - war (134) Used by: OSGi JAX-RS Connector (71)

karaf@root()> scr scr scr:activate scr:components scr:config scr:deactivate scr:details scr:disable
scr:enable scr:info scr:list
karaf@root()> scr:list BundleId Component Name Default State Component Id State PIDs (Factory PID) [ 99] ScrServiceMBean enabled [ 0] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.AppframeworkDynamicFeature enabled [ 1] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.AuthorizationAnnotationProcessor enabled [ 2] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.AuthorizationSchemes enabled [ 3] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.OAuth2AnnotationProcessor enabled [ 4] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.TokenHandlers enabled [ 5] [active ] [ 146] net.wapwag.authn.AuthenticationServiceImpl enabled [ 8] [active ] [ 147] net.wapwag.authn.dao.UserDaoImpl enabled [ 7] [active ] [ 149] net.wapwag.authn.h2.hibernate.H2TxAwareEntityManager enabled [ 6] [active ] [ 150] net.wapwag.authn.rest.AuthenticationResource enabled [ 9] [active ] [ 150] net.wapwag.authn.rest.AuthenticationResourceExceptionMapper enabled [ 10] [active ] [ 150] net.wapwag.authn.rest.authz.AnyAuthenticatedUserScheme enabled [ 11] [active ] [ 150] net.wapwag.authn.rest.filter.AuthorizationFilter enabled [ 12] [active ] [ 150] net.wapwag.authn.rest.oauth2.UsersTokenHandler enabled [ 13] [active ] karaf@root()> ^C karaf@root()> bundle bundle bundle:capabilities bundle:classes bundle:diag bundle:dynamic-import
bundle:find-class bundle:headers bundle:id bundle:info bundle:install
bundle:list bundle:load-test bundle:refresh bundle:requirements bundle:resolve
bundle:restart bundle:services bundle:start bundle:start-level bundle:status
bundle:stop bundle:tree-show bundle:uninstall bundle:update bundle:watch
karaf@root()> bundle:diag

Apache Aries Transaction Blueprint (89)

Status: Failure Blueprint 16-7-23 ??8:39 Exception: null java.util.concurrent.TimeoutException at org.apache.aries.blueprint.container.BlueprintContainerImpl$1.run(BlueprintContainerImpl.java:371) at org.apache.aries.blueprint.utils.threading.impl.DiscardableRunnable.run(DiscardableRunnable.java:48) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)

Missing dependencies: (objectClass=javax.transaction.TransactionManager)

Apache Aries Transaction Blueprint (90)

Status: Failure Blueprint 16-7-23 ??8:39 Exception: null java.util.concurrent.TimeoutException at org.apache.aries.blueprint.container.BlueprintContainerImpl$1.run(BlueprintContainerImpl.java:371) at org.apache.aries.blueprint.utils.threading.impl.DiscardableRunnable.run(DiscardableRunnable.java:48) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)

Missing dependencies: (objectClass=javax.transaction.TransactionManager)

alexlukichev commented 8 years ago

Well, given this output:

karaf@root()> scr:list 
BundleId Component Name Default State
Component Id State PIDs (Factory PID)
[ 99] ScrServiceMBean enabled
[ 0] [active ] 
[ 145] com.thingswise.appframework.jaxrs.utils.AppframeworkDynamicFeature enabled
[ 1] [active ] 
[ 145] com.thingswise.appframework.jaxrs.utils.AuthorizationAnnotationProcessor enabled
[ 2] [active ] 
[ 145] com.thingswise.appframework.jaxrs.utils.AuthorizationSchemes enabled
[ 3] [active ] 
[ 145] com.thingswise.appframework.jaxrs.utils.OAuth2AnnotationProcessor enabled
[ 4] [active ] 
[ 145] com.thingswise.appframework.jaxrs.utils.TokenHandlers enabled
[ 5] [active ] 
[ 146] net.wapwag.authn.AuthenticationServiceImpl enabled
[ 8] [active ] 
[ 147] net.wapwag.authn.dao.UserDaoImpl enabled
[ 7] [active ] 
[ 149] net.wapwag.authn.h2.hibernate.H2TxAwareEntityManager enabled
[ 6] [active ] 
[ 150] net.wapwag.authn.rest.AuthenticationResource enabled
[ 9] [active ] 
[ 150] net.wapwag.authn.rest.AuthenticationResourceExceptionMapper enabled
[ 10] [active ] 
[ 150] net.wapwag.authn.rest.authz.AnyAuthenticatedUserScheme enabled
[ 11] [active ] 
[ 150] net.wapwag.authn.rest.filter.AuthorizationFilter enabled
[ 12] [active ] 
[ 150] net.wapwag.authn.rest.oauth2.UsersTokenHandler enabled
[ 13] [active ] 

I come to the conclusion that your system is up and running OK.

asd1245dss commented 8 years ago

karaf@root()> scr:list BundleId Component Name Default State Component Id State PIDs (Factory PID) [ 99] ScrServiceMBean enabled [ 0] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.AppframeworkDynamicFeature enabled [ 4] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.AuthorizationAnnotationProcessor enabled [ 5] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.AuthorizationSchemes enabled [ 6] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.OAuth2AnnotationProcessor enabled [ 7] [active ] [ 145] com.thingswise.appframework.jaxrs.utils.TokenHandlers enabled [ 8] [active ] [ 146] net.wapwag.authn.AuthenticationServiceImpl enabled [ 3] [active ] [ 147] net.wapwag.authn.dao.UserDaoImpl enabled [ 2] [active ] [ 149] net.wapwag.authn.h2.hibernate.H2TxAwareEntityManager enabled [ 1] [active ] [ 150] net.wapwag.authn.rest.AuthenticationResource enabled [ 9] [active ] [ 150] net.wapwag.authn.rest.AuthenticationResourceExceptionMapper enabled [ 10] [active ] [ 150] net.wapwag.authn.rest.authz.AnyAuthenticatedUserScheme enabled [ 11] [active ] [ 150] net.wapwag.authn.rest.filter.AuthorizationFilter enabled [ 12] [active ] [ 150] net.wapwag.authn.rest.oauth2.UsersTokenHandler enabled [ 13] [active ]

asd1245dss commented 8 years ago

@alexlukichev Still confusing about this problems.The following error is the latest exception I met. image Moreover,I still need to delete the data folder and deploy folder every reboot my karaf in case of long time hot swap.

alexlukichev commented 8 years ago

Can you please elaborate more on "long time hot swap"? And why do you have to remove the data and deploy folders?

alexlukichev commented 8 years ago

Commit 8dd96a266542d1967cabfd5ceb5fdcc5b7fcacb4 should take care of the karaf restart issue. You'll need to overwrite the files in deploy directory and clear data directory.

asd1245dss commented 8 years ago

ok.The problem is solved.