无法在 Windows 上正确安装 Spring-XD

Can't install Spring-XD properly on Windows

为了使用批处理和一些分析,我正在尝试启动一些 Spring-XD 项目。我以前使用过 Spring-Boot。对不起我的无知。我已经按照官方指南做了。

作为 Windows 用户,我没有使用 xd/bin>$ ./xd-singlenode 命令,而是输入了:E:\software\spring-xd-1.3.1.RELEASE\xd\bin>xd-singlenode。他们是一样的吧?我已经定义了他们指示设置的所有路径。

但是我收到了这个错误:

1.3.1.RELEASE eXtreme Data

Started : SingleNodeApplication Documentation: http://docs.spring.io/spring-xd/docs/current/reference/html/

WARNING: An illegal reflective access operation has occurred WARNING: Illegal reflective access by org.codehaus.groovy.reflection.CachedClass (file:/E:/software/spring-xd-1.3.1.RELEASE/xd/lib/groovy-all-2.4.4.jar) to method java.lang.Object.finalize() WARNING: Please consider reporting this to the maintainers of org.codehaus.groovy.reflection.CachedClass WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations WARNING: All illegal access operations will be denied in a future release 2020-09-23T19:48:33+0600 1.3.1.RELEASE INFO main singlenode.SingleNodeApplication - Starting SingleNodeApplication v1.3.1.RELEASE on MUA with PID 12216 (E:\software\spring-xd-1.3.1.RELEASE\xd\lib\spring-xd-dirt-1.3.1.RELEASE.jar started by MUA in E:\software\spring-xd-1.3.1.RELEASE\xd\bin) 2020-09-23T19:48:34+0600 1.3.1.RELEASE INFO main singlenode.SingleNodeApplication - Started SingleNodeApplication in 4.615 seconds (JVM running for 32.452) 2020-09-23T19:48:35+0600 1.3.1.RELEASE INFO main singlenode.SingleNodeApplication - Starting SingleNodeApplication v1.3.1.RELEASE on MUA with PID 12216 (E:\software\spring-xd-1.3.1.RELEASE\xd\lib\spring-xd-dirt-1.3.1.RELEASE.jar started by MUA in E:\software\spring-xd-1.3.1.RELEASE\xd\bin) 2020-09-23T19:48:35+0600 1.3.1.RELEASE INFO main singlenode.SingleNodeApplication - Started SingleNodeApplication in 0.972 seconds (JVM running for 33.47) 2020-09-23T19:48:41+0600 1.3.1.RELEASE WARN main annotation.AnnotationConfigApplicationContext - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor': Invocation of init method failed; nested exception is javax.validation.ValidationException: Unable to instantiate Configuration. 2020-09-23T19:48:41+0600 1.3.1.RELEASE ERROR main boot.SpringApplication - Application startup failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor': Invocation of init method failed; nested exception is javax.validation.ValidationException: Unable to instantiate Configuration. at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1578) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:545) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.getObject(AbstractBeanFactory.java:306) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.context.support.PostProcessorRegistrationDelegate.registerBeanPostProcessors(PostProcessorRegistrationDelegate.java:207) ~[spring-context-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:687) ~[spring-context-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:523) ~[spring-context-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:686) ~[spring-boot-1.2.3.RELEASE.jar:1.2.3.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:320) ~[spring-boot-1.2.3.RELEASE.jar:1.2.3.RELEASE] at org.springframework.boot.builder.SpringApplicationBuilder.run(SpringApplicationBuilder.java:139) ~[spring-boot-1.2.3.RELEASE.jar:1.2.3.RELEASE] at org.springframework.boot.builder.SpringApplicationBuilder.run(SpringApplicationBuilder.java:129) ~[spring-boot-1.2.3.RELEASE.jar:1.2.3.RELEASE] at org.springframework.boot.builder.SpringApplicationBuilder.run(SpringApplicationBuilder.java:129) ~[spring-boot-1.2.3.RELEASE.jar:1.2.3.RELEASE] at org.springframework.xd.dirt.server.singlenode.SingleNodeApplication.run(SingleNodeApplication.java:83) ~[spring-xd-dirt-1.3.1.RELEASE.jar:1.3.1.RELEASE] at org.springframework.xd.dirt.server.singlenode.SingleNodeApplication.main(SingleNodeApplication.java:52) ~[spring-xd-dirt-1.3.1.RELEASE.jar:1.3.1.RELEASE] Caused by: javax.validation.ValidationException: Unable to instantiate Configuration. at javax.validation.Validation$GenericBootstrapImpl.configure(Validation.java:279) ~[validation-api-1.1.0.Final.jar:na] at org.springframework.validation.beanvalidation.LocalValidatorFactoryBean.afterPropertiesSet(LocalValidatorFactoryBean.java:223) ~[spring-context-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor$Jsr303ValidatorFactory.run(ConfigurationPropertiesBindingPostProcessor.java:381) ~[spring-boot-1.2.3.RELEASE.jar:1.2.3.RELEASE] at org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor.afterPropertiesSet(ConfigurationPropertiesBindingPostProcessor.java:174) ~[spring-boot-1.2.3.RELEASE.jar:1.2.3.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1637) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1574) ~[spring-beans-4.2.4.RELEASE.jar:4.2.4.RELEASE] ... 16 common frames omitted Caused by: java.lang.ArrayIndexOutOfBoundsException: Index 1 out of bounds for length 1 at org.hibernate.validator.internal.util.Version.getJavaRelease(Version.java:36) ~[hibernate-validator-5.2.1.Final.jar:5.2.1.Final] at org.hibernate.validator.internal.engine.ConfigurationImpl.(ConfigurationImpl.java:119) ~[hibernate-validator-5.2.1.Final.jar:5.2.1.Final] at org.hibernate.validator.internal.engine.ConfigurationImpl.(ConfigurationImpl.java:95) ~[hibernate-validator-5.2.1.Final.jar:5.2.1.Final] at org.hibernate.validator.HibernateValidator.createGenericConfiguration(HibernateValidator.java:31) ~[hibernate-validator-5.2.1.Final.jar:5.2.1.Final] at javax.validation.Validation$GenericBootstrapImpl.configure(Validation.java:276) ~[validation-api-1.1.0.Final.jar:na] ... 21 common frames omitted Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor': Invocation of init method failed; nested exception is javax.validation.ValidationException: Unable to instantiate Configuration. at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1578) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:545) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:482) at org.springframework.beans.factory.support.AbstractBeanFactory.getObject(AbstractBeanFactory.java:306) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202) at org.springframework.context.support.PostProcessorRegistrationDelegate.registerBeanPostProcessors(PostProcessorRegistrationDelegate.java:207) at org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:687) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:523) at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:686) at org.springframework.boot.SpringApplication.run(SpringApplication.java:320) at org.springframework.boot.builder.SpringApplicationBuilder.run(SpringApplicationBuilder.java:139) at org.springframework.boot.builder.SpringApplicationBuilder.run(SpringApplicationBuilder.java:129) at org.springframework.boot.builder.SpringApplicationBuilder.run(SpringApplicationBuilder.java:129) at org.springframework.xd.dirt.server.singlenode.SingleNodeApplication.run(SingleNodeApplication.java:83) at org.springframework.xd.dirt.server.singlenode.SingleNodeApplication.main(SingleNodeApplication.java:52) Caused by: javax.validation.ValidationException: Unable to instantiate Configuration. at javax.validation.Validation$GenericBootstrapImpl.configure(Validation.java:279) at org.springframework.validation.beanvalidation.LocalValidatorFactoryBean.afterPropertiesSet(LocalValidatorFactoryBean.java:223) at org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor$Jsr303ValidatorFactory.run(ConfigurationPropertiesBindingPostProcessor.java:381) at org.springframework.boot.context.properties.ConfigurationPropertiesBindingPostProcessor.afterPropertiesSet(ConfigurationPropertiesBindingPostProcessor.java:174) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1637) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1574) ... 16 more Caused by: java.lang.ArrayIndexOutOfBoundsException: Index 1 out of bounds for length 1 at org.hibernate.validator.internal.util.Version.getJavaRelease(Version.java:36) at org.hibernate.validator.internal.engine.ConfigurationImpl.(ConfigurationImpl.java:119) at org.hibernate.validator.internal.engine.ConfigurationImpl.(ConfigurationImpl.java:95) at org.hibernate.validator.HibernateValidator.createGenericConfiguration(HibernateValidator.java:31) at javax.validation.Validation$GenericBootstrapImpl.configure(Validation.java:276) ... 21 more

E:\software\spring-xd-1.3.1.RELEASE\xd\bin>

看起来 Spring XD 与您的 java 版本不兼容。 您使用的是 Java 11 吗?

SpringXD最初是为Java7写的,从2017年开始End-Of-Life

新项目应改用 Spring Cloud Data Flow:https://spring.io/projects/spring-cloud-dataflow