配置了configuration.xml之后提示找不到映射关系

在启动类里面单独增加一个Bean即可解决

@Bean
public DatabaseIdProvider getDatabaseIdProvider(){
  DatabaseIdProvider databaseIdProvider = new VendorDatabaseIdProvider();
  Properties properties = new Properties();
  properties.setProperty("Oracle1","oracle");
  properties.setProperty("MySQL","mysql");
  databaseIdProvider.setProperties(properties);
  return databaseIdProvider;
}

 

posted @ 2019-06-06 15:49  Liu66~  阅读(297)  评论(0编辑  收藏  举报