2017-09-13 71 views
0

我想有两个代理,而在第二个节点我得到以下错误启动单节点集群正在搬运工集群上安装Apache Nifi工作Nifi群集未启动,只在一个节点

我的堆栈跟踪

2017-09-13 06:00:52,640 INFO [main] o.a.n.admin.AuditDataSourceFactoryBean Database not built for repository: jdbc:h2:./database_repository/nifi-flow-audit;AUTOCOMMIT=OFF;DB_CLOSE_ON_EXIT=FALSE;LOCK_MODE=3;LOCK_TIMEOUT=25000;WRITE_DELAY=0;AUTO_SERVER=FALSE. Building now... 
2017-09-13 06:00:52,794 WARN [main] org.eclipse.jetty.webapp.WebAppContext Failed startup of context [email protected]{/nifi-api,file:///opt/nifi/work/jetty/nifi-web-api-1.3.0.war/webapp/,UNAVAILABLE}{./work/nar/framework/nifi-framework-nar-1.3.0.nar-unpacked/META-INF/bundled-dependencies/nifi-web-api-1.3.0.war} 
org.apache.nifi.web.NiFiCoreException: Unable to start Flow Controller. 
     at org.apache.nifi.web.contextlistener.ApplicationStartupContextListener.contextInitialized(ApplicationStartupContextListener.java:88) 
     at org.eclipse.jetty.server.handler.ContextHandler.callContextInitialized(ContextHandler.java:876) 
     at org.eclipse.jetty.servlet.ServletContextHandler.callContextInitialized(ServletContextHandler.java:532) 
     at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:839) 
     at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:344) 
     at org.eclipse.jetty.webapp.WebAppContext.startWebapp(WebAppContext.java:1480) 
     at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1442) 
     at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:799) 
     at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:261) 
     at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:540) 
     at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) 
     at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:131) 
     at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:113) 
     at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:113) 
     at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) 
     at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:131) 
     at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:105) 
     at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:113) 
     at org.eclipse.jetty.server.handler.gzip.GzipHandler.doStart(GzipHandler.java:290) 
     at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) 
     at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:131) 
     at org.eclipse.jetty.server.Server.start(Server.java:452) 
     at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:105) 
     at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:113) 
     at org.eclipse.jetty.server.Server.doStart(Server.java:419) 
     at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68) 
     at org.apache.nifi.web.server.JettyServer.start(JettyServer.java:705) 
     at org.apache.nifi.NiFi.<init>(NiFi.java:160) 
     at org.apache.nifi.NiFi.main(NiFi.java:267) 
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'flowService': FactoryBean threw exception on object creation; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'flowController' defined in class path resource [nifi-context.xml]: Cannot resolve reference to bean 'clusterCoordinator' while setting bean property 'clusterCoordinator'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'clusterCoordinator': FactoryBean threw exception on object creation; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'clusterCoordinationProtocolSenderListener' defined in class path resource [nifi-cluster-protocol-context.xml]: Cannot resolve reference to bean 'protocolListener' while setting constructor argument; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'protocolListener' defined in class path resource [nifi-cluster-protocol-context.xml]: Unsatisfied dependency expressed through constructor argument with index 1 of type [int]: Could not convert constructor argument value of type [null] to required type [int]: Failed to convert value of type [null] to required type [int]; nested exception is java.lang.IllegalArgumentException: Cannot convert value of type [null] to required type [int]: PropertyEditor [org.springframework.beans.propertyeditors.CustomNumberEditor] returned inappropriate value of type [null] 
     at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:175) 
     at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.getObjectFromFactoryBean(FactoryBeanRegistrySupport.java:103) 
+0

发布有关如何运行群集的详细信息 –

回答

0

你所得到的误差被示出,它不能实例化一个弹簧豆“protocolListener”类路径资源定义[nifi簇 - 协议 - context.xml中]。

该bean定义是这样的:

<!-- protocol listener --> 
    <bean id="protocolListener" class="org.apache.nifi.cluster.protocol.impl.SocketProtocolListener"> 
     <constructor-arg index="0"> 
      <bean factory-bean="nifiProperties" factory-method="getClusterNodeProtocolThreads"/> 
     </constructor-arg> 
     <constructor-arg index="1"> 
      <bean factory-bean="nifiProperties" factory-method="getClusterNodeProtocolPort"/> 
     </constructor-arg> 
     <constructor-arg ref="protocolServerSocketConfiguration" index="2"/> 
     <constructor-arg ref="protocolContext" index="3"/> 
    </bean> 

错误消息也说,问题是指数1这是getClusterNodeProtocolPort。

您很可能没有在nifi.properties中为此节点设置nifi.cluster.node.protocol.port。