Skip to content

Support configuration property for 'default-scope' provided by mybatis-spring #469

Closed
@kazuki43zoo

Description

@kazuki43zoo

See mybatis/spring#484

Support following property. This property is available that use together with mybatis-spring 2.0.6+.

  • application.properties
mybatis.mapper-default-scope=refresh

Note:

If you want to use the refresh scope provided by Spring Cloud for the SqlSessionFactory that create by auto-configure, you can specified using following property provided by Spring Cloud.

  • application.properties
spring.cloud.refresh.refreshable=org.apache.ibatis.session.SqlSessionFactory

P.S:

Until before mybatis-spring-boot 2.1.3 (mybatis-spring 2.0.5), it can be realize same behavior as follow:

  • application.properties
spring.cloud.refresh.refreshable=org.apache.ibatis.session.SqlSessionFactory,org.mybatis.spring.mapper.MapperFactoryBean

Of course this method is also available on mybatis-spring-boot 2.1.4+ (mybatis-spring 2.0.6+).

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions