Skip to content

Conversation

kazuki43zoo
Copy link
Member

@kazuki43zoo kazuki43zoo commented Mar 16, 2020

Related with gh-440

By this change, we can customize a default enum type handler as follow:

@Bean
SqlSessionFactoryBean sqlSessionFactory(DataSource dataSource) {
  SqlSessionFactoryBean factoryBean = new SqlSessionFactoryBean();
  factoryBean.setDataSource(dataSource);
  factoryBean.setDefaultEnumTypeHandler(EnumOrdinalTypeHandler.class); // new property
  return factoryBean;
}

@kazuki43zoo kazuki43zoo added the enhancement Improve a feature or add a new feature label Mar 16, 2020
@kazuki43zoo kazuki43zoo added this to the 2.0.5 milestone Mar 16, 2020
@kazuki43zoo kazuki43zoo self-assigned this Mar 16, 2020
@kazuki43zoo kazuki43zoo merged commit 0871770 into mybatis:master Mar 16, 2020
@kazuki43zoo kazuki43zoo deleted the defaultEnumTypeHandler branch March 16, 2020 18:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improve a feature or add a new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant