alibaba / cloud-native-app-initializer

Cloud Native App Initializer is committed to providing developers with a simpler and more efficient project construction experience in the current cloud-native era.
https://start.aliyun.com
Apache License 2.0
258 stars 90 forks source link

Support Spring Cloud Alibaba 2022.0.0.0 #38

Closed ralf0131 closed 1 year ago

ralf0131 commented 1 year ago

It looks like the initializr do not honor the version of latest Spring Cloud Alibaba

Caused by: io.spring.initializr.metadata.InvalidInitializrMetadataException: Invalid compatibility range '[2.0.0.RELEASE,2022.0.0.0-RC1] for dependency with id 'sca-nacos-discovery'
        at io.spring.initializr.metadata.Dependency.updateCompatibilityRange(Dependency.java:222)
        at io.spring.initializr.metadata.Dependency.resolve(Dependency.java:201)
        at io.spring.initializr.metadata.DependenciesCapability.lambda$null$3(DependenciesCapability.java:105)
        at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
        at io.spring.initializr.metadata.DependenciesCapability.lambda$index$4(DependenciesCapability.java:93)
        at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
        at io.spring.initializr.metadata.DependenciesCapability.index(DependenciesCapability.java:93)
        at io.spring.initializr.metadata.DependenciesCapability.merge(DependenciesCapability.java:88)
        at com.alibaba.initializer.metadata.InitializerMetadataBuilder$InitializerPropertiesCustomizer.customize(InitializerMetadataBuilder.java:109)
        at com.alibaba.initializer.metadata.InitializerMetadataBuilder.build(InitializerMetadataBuilder.java:68)
        at com.alibaba.initializer.configure.InitializerMetadataConfigure.initializrMetadataProvider(InitializerMetadataConfigure.java:58)
        at com.alibaba.initializer.configure.InitializerMetadataConfigure$$EnhancerBySpringCGLIB$$7b6cd2e2.CGLIB$initializrMetadataProvider$0(<generated>)
        at com.alibaba.initializer.configure.InitializerMetadataConfigure$$EnhancerBySpringCGLIB$$7b6cd2e2$$FastClassBySpringCGLIB$$55ee84e4.invoke(<generated>)
        at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:244)
        at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:331)
        at com.alibaba.initializer.configure.InitializerMetadataConfigure$$EnhancerBySpringCGLIB$$7b6cd2e2.initializrMetadataProvider(<generated>)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:568)
        at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154)
        ... 124 common frames omitted
Caused by: io.spring.initializr.generator.version.InvalidVersionException: Could not determine version based on '2022.0.0.0-RC1': version format is Major.Minor.Patch and an optional Qualifier (e.g. 1.0.5.RELEASE)
        at io.spring.initializr.generator.version.VersionParser.parse(VersionParser.java:73)
        at io.spring.initializr.generator.version.VersionParser.parseRange(VersionParser.java:139)
        at io.spring.initializr.metadata.Dependency.updateCompatibilityRange(Dependency.java:216)
        ... 144 common frames omitted
ralf0131 commented 1 year ago

It was my mis-configuration. The issue has been solved, please ignore it.

ralf0131 commented 1 year ago

commit deb9b3371a0a6034392a93e409b968de7cce753f has solved this issue.

ralf0131 commented 1 year ago

Now in the bootstrap page, we are able to choose Spring Cloud Alibaba components when selecting Spring boot 3.0