Getting Oracle 11.2 Unsupported Error when using Spring Cloud Data Flow 2.0.1

匆匆过客 提交于 2019-12-11 08:59:33

问题


I am trying to set up SCDF 2.x (Spring Cloud Data Flow) server, to register Spring Boot applications (e.g. Tasks type) , to leverage out of box administration and other capabilities.

In setting up SCDF 2.x, was trying to connect to new 'dataflow' schema on Oracle 11.2 (for job registry), but upon starting the dataflow server from command line (with Oracle JDBC in classpath), getting below error. Any suggestions will be helpful to resolve (as we are tied to Oracle as enterprise supported.

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'flywayInitializer' defined in class path resource [org/springframework/boot/autoconfigure/flyway/FlywayAutoConfiguration$FlywayConfiguration.class]: Invocation of init method failed; nested exception is org.flywaydb.core.internal.license.FlywayEnterpriseUpgradeRequiredException: Flyway Enterprise Edition or Oracle upgrade required: Oracle 11.2 is past regular support by Oracle and no longer supported by Flyway Community Edition, but still supported by Flyway Enterprise Edition. at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1762) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:593) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318) ~[spring-beans-5.1.5.RELEASE.jar:5.1.5.RELEASE]

our oracle version is 11.2

Tried overriding the flyway dependency in project pom, but less than 5.x is giving NoMethodFoundError


回答1:


finally I've made an advance with this problem, in my case was enough with removing the flyway autoconfiguration and loading a bean called FluentConfiguration. I've made a project with the dependencies of spring cloud dataflow and then an SpringBootApplication class with this configuration:

import org.flywaydb.core.api.configuration.FluentConfiguration;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.flyway.FlywayAutoConfiguration;
import org.springframework.cloud.dataflow.server.EnableDataFlowServer;
import org.springframework.context.annotation.Import;

@SpringBootApplication(exclude = FlywayAutoConfiguration.class)
@EnableDataFlowServer
@Import(FluentConfiguration.class)
public class MyCompanySpringCloudDataflowApplication {

    public static void main(String[] args) {
        SpringApplication.run(MyCompanySpringCloudDataflowApplication .class, args);
    }

}

I know is not a neat solution, but is what I need to advance.

Of course, the database schema isn't automatically created, you must create it before running the application.

Hope this helps you.



来源:https://stackoverflow.com/questions/55399872/getting-oracle-11-2-unsupported-error-when-using-spring-cloud-data-flow-2-0-1

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!