Skip to content

Conversation

carter-ya
Copy link

When autowire the interceptors, not respect the Spring sorting style (using @Order or implements the Ordered interface). Some scenarios will depend on the execution order of the Interceptor, such as expecting to obtain the rewritten SQL and parameters after the PaginationInterceptor is executed.

@carter-ya carter-ya changed the title \Support interceptor sorting during auto config SqlSessionFactory Support interceptor sorting during auto config SqlSessionFactory Mar 10, 2021
@kazuki43zoo
Copy link
Member

@carter-ya In my understand, auto-wired interceptor already was sorted using spring ordered feature(Ordered interface, @Order annotation, etc...). My understand is incorrect?

kazuki43zoo added a commit to kazuki43zoo/spring-boot-starter that referenced this pull request Dec 31, 2021
kazuki43zoo added a commit that referenced this pull request Dec 31, 2021
…eptors

Add test for ordering interceptor
@carter-ya
Copy link
Author

Thank you for your reply! I have tested the injected behavior and it is indeed sorted automatically.

@carter-ya carter-ya closed this Dec 31, 2021
@carter-ya carter-ya deleted the feat/plugin-order branch December 31, 2021 13:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants