ignite集群和kubernetes集成
我是新点燃的 测试1:(没有Kubernetes) 步骤1:我在两个虚拟机(ubuntu)中安装了Ignite2.6.0,在一个虚拟机中启动了节点。下面是comand。 bin/ignite.sh examples/config/example-ignite.xml 步骤2:我所有的配置都在example-default.xml中 步骤3:在其他VM中执行client.jar,其中包含datagrid逻辑(此VM既是客户机也是节点) 步骤4:能够在缓存中存储数据 测试2:(Kubernetes安装在云中) 步骤1:遵循url中提到的步骤ignite集群和kubernetes集成,ignite,Ignite,我是新点燃的 测试1:(没有Kubernetes) 步骤1:我在两个虚拟机(ubuntu)中安装了Ignite2.6.0,在一个虚拟机中启动了节点。下面是comand。 bin/ignite.sh examples/config/example-ignite.xml 步骤2:我所有的配置都在example-default.xml中 步骤3:在其他VM中执行client.jar,其中包含datagrid逻辑(此VM既是客户机也是节点) 步骤4:能够在缓存中存储数据 测试2:(Kubernetes安
Exception in thread "main" class org.apache.ignite.IgniteException: Failed to instantiate Spring XML application context (make sure all classes used in Spring configuration are present at CLASSPATH) [springUrl=file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-ignite.xml]
at org.apache.ignite.internal.util.IgniteUtils.convertException(IgniteUtils.java:990)
at org.apache.ignite.Ignition.start(Ignition.java:355)
Caused by: class org.apache.ignite.IgniteCheckedException: Failed to instantiate Spring XML application context (make sure all classes used in Spring configuration are present at CLASSPATH) [springUrl=file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-ignite.xml]
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ignite.cfg$child#0' defined in URL [file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-ignite.xml]: Cannot create inner bean 'org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi#c038203' of type [org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi] while setting bean property 'discoverySpi'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi#c038203' defined in URL
[file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-default.xml]; nested exception is java.lang.ClassNotFoundException: org.apache.ignite.spi.discovery.tcp.ipfinder.kubernetes.TcpDiscoveryKubernetesIpFinder
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:313)
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi#c038203' defined in URL [file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-default.xml]: Cannot create inner bean
[file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-default.xml]; nested exception is java.lang.ClassNotFoundException: org.apache.ignite.spi.discovery.tcp.ipfinder.kubernetes.TcpDiscoveryKubernetesIpFinder
问题的其他形式…
一旦Kubernetes按照上面提到的步骤启动,比如说2个pod,如何以及在何处部署ignite data grid logic client.jar文件以在其中执行java文件
@澄清
**下面的文件
- 名称:selfLink 价值:file:///opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-default.xml
<bean class="org.apache.ignite.spi.discovery.tcp.ipfinder.kubernetes.TcpDiscoveryKubernetesIpFinder">
<property name="namespace" value="ignite"/>
</bean>
**归档
try(Ignite-Ignite=Ignition.start(“/opt/apache-Ignite-fabric-2.6.0-bin/examples/config/example-Ignite.xml”))
包含我的自定义配置,如下所示
<bean class="org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder">
<property name="namespace" value="ignite"/>
<property name="serviceName" value="ignite"/>
<bean
<property name="addresses">
<list>
<value>xxx.xxx.xxx.xxx:47500</value>
<value>xxx.xxx.xxx.xxx:47500</value>
</list>
</property>
</bean>
对于TcpDiscoveryKubernetesIpFinder
,您不能有地址。因此,系统无法从XML创建它。删除地址
部分。Stanislav Lukyanov-我在我的问题中添加了@澄清部分。请让我知道这是否是TcpDiscoveryKubernetesIpFinder的正确地址。进行了问题澄清部分所述的配置更改。并按照问题“客户端运行”一节所述启动客户端。获取错误-原因:org.springframework.beans.NotWritablePropertyException:bean类的属性“namespace”无效[org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder您需要使用TcpDiscoveryVmIpFinder
或TcpDiscoveryKubernetesIpFinder
。请注意,前者没有命名空间
和服务名
属性,后者也没有地址
。请在注意你的问题的格式。确保所有的代码都在代码部分。现在很难理解它。
Exception in thread "main" class org.apache.ignite.IgniteException: Failed to instantiate Spring XML application context (make sure all classes used in Spring configuration are present at CLASSPATH) [springUrl=file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-ignite.xml]
at org.apache.ignite.internal.util.IgniteUtils.convertException(IgniteUtils.java:990)
at org.apache.ignite.Ignition.start(Ignition.java:355)
Caused by: class org.apache.ignite.IgniteCheckedException: Failed to instantiate Spring XML application context (make sure all classes used in Spring configuration are present at CLASSPATH) [springUrl=file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-ignite.xml]
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ignite.cfg$child#0' defined in URL [file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-ignite.xml]: Cannot create inner bean 'org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi#c038203' of type [org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi] while setting bean property 'discoverySpi'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi#c038203' defined in URL
[file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-default.xml]; nested exception is java.lang.ClassNotFoundException: org.apache.ignite.spi.discovery.tcp.ipfinder.kubernetes.TcpDiscoveryKubernetesIpFinder
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:313)
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi#c038203' defined in URL [file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-default.xml]: Cannot create inner bean
[file:/opt/apache-ignite-fabric-2.6.0-bin/examples/config/example-default.xml]; nested exception is java.lang.ClassNotFoundException: org.apache.ignite.spi.discovery.tcp.ipfinder.kubernetes.TcpDiscoveryKubernetesIpFinder
<bean class="org.apache.ignite.spi.discovery.tcp.ipfinder.kubernetes.TcpDiscoveryKubernetesIpFinder">
<property name="namespace" value="ignite"/>
</bean>
<bean class="org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder">
<property name="namespace" value="ignite"/>
<property name="serviceName" value="ignite"/>
<bean
<property name="addresses">
<list>
<value>xxx.xxx.xxx.xxx:47500</value>
<value>xxx.xxx.xxx.xxx:47500</value>
</list>
</property>
</bean>