I am new to Apache sling,downloaded the org.apache.sling.launchpad-7.war from here,deployed in tomcat7. when i try to add new node,it is giving below exception.
*ERROR* **[Apache Sling JCR Resource Event Queue Processor] org.apache.sling.discovery.impl [org.apache.sling.discovery.impl.DiscoveryServiceImpl(49)] The activate method has thrown an exception (java.lang.RuntimeException: Exception while talking to repository (org.apache.sling.api.resource.PersistenceException: Unable to create node at /var/discovery))**
java.lang.RuntimeException: Exception while talking to repository (org.apache.sling.api.resource.PersistenceException: Unable to create node at /var/discovery)
at org.apache.sling.discovery.impl.topology.announcement.AnnouncementRegistryImpl.listAnnouncementsInSameCluster(AnnouncementRegistryImpl.java:204)
at org.apache.sling.discovery.impl.topology.announcement.AnnouncementRegistryImpl.listInstances(AnnouncementRegistryImpl.java:487)
at org.apache.sling.discovery.impl.DiscoveryServiceImpl.getTopology(DiscoveryServiceImpl.java:423)
at org.apache.sling.discovery.impl.DiscoveryServiceImpl.activate(DiscoveryServiceImpl.java:145)
at sun.reflect.GeneratedMethodAccessor52.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.felix.scr.impl.helper.BaseMethod.invokeMethod(BaseMethod.java:231)
at org.apache.felix.scr.impl.helper.BaseMethod.access$500(BaseMethod.java:39)
at org.apache.felix.scr.impl.helper.BaseMethod$Resolved.invoke(BaseMethod.java:624)
at org.apache.felix.scr.impl.helper.BaseMethod.invoke(BaseMethod.java:508)
at org.apache.felix.scr.impl.helper.ActivateMethod.invoke(ActivateMethod.java:149)
at org.apache.felix.scr.impl.manager.SingleComponentManager.createImplementationObject(SingleComponentManager.java:315)
at org.apache.felix.scr.impl.manager.SingleComponentManager.createComponent(SingleComponentManager.java:127)
at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:871)
at org.apache.felix.scr.impl.manager.SingleComponentManager.getServiceInternal(SingleComponentManager.java:838)
at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:777)
at org.apache.felix.framework.ServiceRegistrationImpl.getFactoryUnchecked(ServiceRegistrationImpl.java:320)
at org.apache.felix.framework.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:231)
at org.apache.felix.framework.ServiceRegistry.getService(ServiceRegistry.java:327)
at org.apache.felix.framework.Felix.getService(Felix.java:3576)
at org.apache.felix.framework.BundleContextImpl.getService(BundleContextImpl.java:468)
at org.apache.felix.scr.impl.helper.BindMethod.getServiceObject(BindMethod.java:572)
at org.apache.felix.scr.impl.manager.DependencyManager.getServiceObject(DependencyManager.java:2012)
at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.prebind(DependencyManager.java:1005)
at org.apache.felix.scr.impl.manager.DependencyManager.prebind(DependencyManager.java:1439)
at org.apache.felix.scr.impl.manager.AbstractComponentManager.collectDependencies(AbstractComponentManager.java:1119)
at org.apache.felix.scr.impl.manager.SingleComponentManager.getServiceInternal(SingleComponentManager.java:807)
at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:777)
at org.apache.felix.framework.ServiceRegistrationImpl.getFactoryUnchecked(ServiceRegistrationImpl.java:320)
at org.apache.felix.framework.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:231)
at org.apache.felix.framework.ServiceRegistry.getService(ServiceRegistry.java:327)
at org.apache.felix.framework.Felix.getService(Felix.java:3576)
at org.apache.felix.framework.BundleContextImpl.getService(BundleContextImpl.java:468)
at org.apache.felix.eventadmin.impl.handler.EventHandlerProxy.obtain(EventHandlerProxy.java:286)
at org.apache.felix.eventadmin.impl.handler.EventHandlerProxy.sendEvent(EventHandlerProxy.java:407)
at org.apache.felix.eventadmin.impl.tasks.SyncDeliverTasks.execute(SyncDeliverTasks.java:118)
at org.apache.felix.eventadmin.impl.handler.EventAdminImpl.sendEvent(EventAdminImpl.java:147)
at org.apache.felix.eventadmin.impl.security.EventAdminSecurityDecorator.sendEvent(EventAdminSecurityDecorator.java:96)
at org.apache.sling.jcr.resource.internal.JcrResourceListener.processOsgiEventQueue(JcrResourceListener.java:375)
at org.apache.sling.jcr.resource.internal.JcrResourceListener$1.run(JcrResourceListener.java:101)
at java.lang.Thread.run(Thread.java:662)
Caused by: org.apache.sling.api.resource.PersistenceException: Unable to create node at /var/discovery
at org.apache.sling.jcr.resource.internal.helper.jcr.JcrResourceProvider.create(JcrResourceProvider.java:486)
at org.apache.sling.resourceresolver.impl.tree.ResourceProviderEntry.create(ResourceProviderEntry.java:479)
at org.apache.sling.resourceresolver.impl.ResourceResolverImpl.create(ResourceResolverImpl.java:1096)
at org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:565)
at org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:525)
at org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:555)
at org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:525)
at org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:555)
at org.apache.sling.api.resource.ResourceUtil.getOrCreateResource(ResourceUtil.java:525)
at org.apache.sling.discovery.impl.common.resource.ResourceHelper.getOrCreateResource(ResourceHelper.java:43)
at org.apache.sling.discovery.impl.topology.announcement.AnnouncementRegistryImpl.listAnnouncementsInSameCluster(AnnouncementRegistryImpl.java:150)
... 41 common frames omitted
Caused by: javax.jcr.nodetype.ConstraintViolationException: No child node definition for discovery found in node /var
at org.apache.jackrabbit.core.NodeImpl.addNode(NodeImpl.java:1276)
at org.apache.jackrabbit.core.session.AddNodeOperation.perform(AddNodeOperation.java:111)
at org.apache.jackrabbit.core.session.AddNodeOperation.perform(AddNodeOperation.java:37)
at org.apache.jackrabbit.core.session.SessionState.perform(SessionState.java:216)
at org.apache.jackrabbit.core.ItemImpl.perform(ItemImpl.java:91)
at org.apache.jackrabbit.core.NodeImpl.addNodeWithUuid(NodeImpl.java:1814)
at org.apache.jackrabbit.core.NodeImpl.addNode(NodeImpl.java:1766)
at org.apache.sling.jcr.resource.internal.helper.jcr.JcrResourceProvider.create(JcrResourceProvider.java:457)
... 51 common frames omitted
**Caused by: javax.jcr.nodetype.ConstraintViolationException: no matching child node definition found for {}discovery**
at org.apache.jackrabbit.core.nodetype.EffectiveNodeType.getApplicableChildNodeDef(EffectiveNodeType.java:744)
at org.apache.jackrabbit.core.NodeImpl.getApplicableChildNodeDefinition(NodeImpl.java:817)
at org.apache.jackrabbit.core.NodeImpl.addNode(NodeImpl.java:1274)
This was a bug in the version of the {{org.apache.sling.discovery.impl}} bundle shipped with Sling Launchpad 7 : SLING-3618.
You can deploy an updated version of the affected bundle in your instance: