You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@shiro.apache.org by GitBox <gi...@apache.org> on 2022/10/07 04:12:20 UTC

[GitHub] [shiro] georgecao opened a new pull request, #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

georgecao opened a new pull request, #472:
URL: https://github.com/apache/shiro/pull/472

   See #268  for the previous fix.  But when `@EnableAspectJAutoProxy` enabled, spring actually creates an instance of  `AnnotationAwareAspectJAutoProxyCreator` but not `DefaultAdvisorAutoProxyCreator`.  In this situation, there will be two proxy creators in the same context, which leads to methods be proxied twice also .
   
   The fix may just remove the type value of the `@ConditionalOnMissingBean`.
   `   @Bean
       @DependsOn("lifecycleBeanPostProcessor")
       @ConditionalOnMissingBean(name = AopConfigUtils.AUTO_PROXY_CREATOR_BEAN_NAME)
       @Override
       public DefaultAdvisorAutoProxyCreator defaultAdvisorAutoProxyCreator() {
           return super.defaultAdvisorAutoProxyCreator();
       }`


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] fpapon commented on pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
fpapon commented on PR #472:
URL: https://github.com/apache/shiro/pull/472#issuecomment-1273034719

   > Looks like CI builds are not stable, `logInAndRememberMe` fails occasionally. @fpapon @bdemers
   
   Yes it's a know issue, don't worry it's not related to your PR.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] bdemers commented on a diff in pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
bdemers commented on code in PR #472:
URL: https://github.com/apache/shiro/pull/472#discussion_r989942727


##########
support/spring-boot/spring-boot-starter/pom.xml:
##########
@@ -18,7 +18,8 @@
   ~ under the License.
   -->
 <!--suppress osmorcNonOsgiMavenDependency -->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/maven-v4_0_0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/maven-v4_0_0.xsd">

Review Comment:
   ```suggestion
   <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/maven-v4_0_0.xsd">
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] fpapon commented on pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
fpapon commented on PR #472:
URL: https://github.com/apache/shiro/pull/472#issuecomment-1271138671

   @georgecao thanks for the PR! Is there a way to add a unit test to validate the fix?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] bdemers commented on pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
bdemers commented on PR #472:
URL: https://github.com/apache/shiro/pull/472#issuecomment-1271637721

   @georgecao nope, I was just removing the white space to help reduce the diff to the lines needed. It helps when backporting too


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] fpapon merged pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
fpapon merged PR #472:
URL: https://github.com/apache/shiro/pull/472


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] georgecao commented on pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
georgecao commented on PR #472:
URL: https://github.com/apache/shiro/pull/472#issuecomment-1271255378

   >
   Sure. Will come back when unit test is ready.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] fpapon commented on pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
fpapon commented on PR #472:
URL: https://github.com/apache/shiro/pull/472#issuecomment-1271576999

   @georgecao thanks for the unit tests! 
   Can you squash the commit please?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] bdemers commented on a diff in pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
bdemers commented on code in PR #472:
URL: https://github.com/apache/shiro/pull/472#discussion_r989941557


##########
support/spring-boot/spring-boot-starter/pom.xml:
##########
@@ -32,12 +33,10 @@
     <name>Apache Shiro :: Support :: Spring Boot</name>
 
     <dependencies>

Review Comment:
   ```suggestion
       <dependencies>
   
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] bdemers commented on a diff in pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
bdemers commented on code in PR #472:
URL: https://github.com/apache/shiro/pull/472#discussion_r989941940


##########
support/spring-boot/spring-boot-starter/pom.xml:
##########
@@ -69,20 +67,22 @@
             <artifactId>spring-test</artifactId>
             <scope>test</scope>
         </dependency>

Review Comment:
   ```suggestion
           </dependency>
   
   ```



##########
support/spring-boot/spring-boot-starter/pom.xml:
##########
@@ -69,20 +67,22 @@
             <artifactId>spring-test</artifactId>
             <scope>test</scope>
         </dependency>
-
         <dependency>
             <groupId>org.mockito</groupId>
             <artifactId>mockito-core</artifactId>
             <scope>test</scope>
         </dependency>

Review Comment:
   ```suggestion
           </dependency>
   
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] georgecao commented on pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
georgecao commented on PR #472:
URL: https://github.com/apache/shiro/pull/472#issuecomment-1272277930

   Looks like CI builds are not stable, `logInAndRememberMe` fails occasionally.  @fpapon @bdemers 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] bdemers commented on a diff in pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
bdemers commented on code in PR #472:
URL: https://github.com/apache/shiro/pull/472#discussion_r989941749


##########
support/spring-boot/spring-boot-starter/pom.xml:
##########
@@ -32,12 +33,10 @@
     <name>Apache Shiro :: Support :: Spring Boot</name>
 
     <dependencies>
-
         <dependency>
             <groupId>org.apache.shiro</groupId>
             <artifactId>shiro-spring</artifactId>
         </dependency>

Review Comment:
   ```suggestion
           </dependency>
   
   ```



##########
support/spring-boot/spring-boot-starter/pom.xml:
##########
@@ -58,7 +57,6 @@
             <artifactId>spring-boot-configuration-processor</artifactId>
             <optional>true</optional>
         </dependency>

Review Comment:
   ```suggestion
           </dependency>
   
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] georgecao commented on pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
georgecao commented on PR #472:
URL: https://github.com/apache/shiro/pull/472#issuecomment-1271430426

   @bdemers  I formats the pom.xml by IntellIJ's project code style. Is there a code style guide that I missed?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shiro] georgecao commented on pull request #472: [SHIRO-890] Avoid another proxy creator when @EnableAspectJAutoProxy enabled

Posted by GitBox <gi...@apache.org>.
georgecao commented on PR #472:
URL: https://github.com/apache/shiro/pull/472#issuecomment-1271842984

   > @georgecao thanks for the unit tests! 
   > 
   > Can you squash the commit please?
   
   Done. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@shiro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org