chainray01 opened a new issue, #2114:
URL: https://github.com/apache/shiro/issues/2114

   ### Search before asking
   
   - [x] I had searched in the 
[issues](https://github.com/apache/shiro/issues?q=is%3Aissue) and found no 
similar issues.
   
   
   ### Environment
   
   ```
   openjdk version "19.0.2" 2023-01-17
   springboot 3.4.3
   ```
   
   ### Shiro version
   
   ```xml
           <dependency>
               <groupId>org.apache.shiro</groupId>
               <artifactId>shiro-spring-boot-web-starter</artifactId>
               <version>2.0.4</version>
               <classifier>jakarta</classifier>
           </dependency>
   ```
   
   ### What was the actual outcome?
   
   ```
   Error starting ApplicationContext. To display the condition evaluation 
report re-run your application with 'debug' enabled.
   2025-05-26 16:17:57.308 [dev.demo6] [TID: N/A] ERROR 75373 --- [main] 
o.s.boot.SpringApplication               : Application run failed
   java.lang.IllegalStateException: Error processing condition on 
org.apache.shiro.spring.config.web.autoconfigure.ShiroWebFilterConfiguration.globalFilters
        at 
org.springframework.boot.autoconfigure.condition.SpringBootCondition.matches(SpringBootCondition.java:60)
        at 
org.springframework.context.annotation.ConditionEvaluator.shouldSkip(ConditionEvaluator.java:99)
        at 
org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForBeanMethod(ConfigurationClassBeanDefinitionReader.java:184)
        at 
org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitionsForConfigurationClass(ConfigurationClassBeanDefinitionReader.java:145)
        at 
org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader.loadBeanDefinitions(ConfigurationClassBeanDefinitionReader.java:121)
        at 
org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:430)
        at 
org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:290)
        at 
org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:349)
        at 
org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:118)
        at 
org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:791)
        at 
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:609)
        at 
org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:146)
        at 
org.springframework.boot.SpringApplication.refresh(SpringApplication.java:752)
        at 
org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:439)
        at 
org.springframework.boot.SpringApplication.run(SpringApplication.java:318)
        at 
org.springframework.boot.SpringApplication.run(SpringApplication.java:1361)
        at 
org.springframework.boot.SpringApplication.run(SpringApplication.java:1350)
        at com.raytech.cloud.Demo6.main(Demo6.java:12)
   Caused by: java.lang.IllegalStateException: Failed to introspect Class 
[org.apache.shiro.spring.config.web.autoconfigure.ShiroWebFilterConfiguration] 
from ClassLoader [jdk.internal.loader.ClassLoaders$AppClassLoader@7b1d7fff]
        at 
org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:483)
        at 
org.springframework.util.ReflectionUtils.doWithMethods(ReflectionUtils.java:360)
        at 
org.springframework.util.ReflectionUtils.getUniqueDeclaredMethods(ReflectionUtils.java:417)
        at 
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.lambda$getTypeForFactoryMethod$1(AbstractAutowireCapableBeanFactory.java:751)
        at 
java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1740)
        at 
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.getTypeForFactoryMethod(AbstractAutowireCapableBeanFactory.java:750)
        at 
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineTargetType(AbstractAutowireCapableBeanFactory.java:683)
        at 
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.predictBeanType(AbstractAutowireCapableBeanFactory.java:654)
        at 
org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1704)
        at 
org.springframework.beans.factory.support.DefaultListableBeanFactory.doGetBeanNamesForType(DefaultListableBeanFactory.java:618)
        at 
org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType(DefaultListableBeanFactory.java:590)
        at 
org.springframework.boot.autoconfigure.condition.OnBeanCondition.collectBeanDefinitionsForType(OnBeanCondition.java:332)
        at 
org.springframework.boot.autoconfigure.condition.OnBeanCondition.getBeanDefinitionsForType(OnBeanCondition.java:324)
        at 
org.springframework.boot.autoconfigure.condition.OnBeanCondition.getBeanDefinitionsForType(OnBeanCondition.java:314)
        at 
org.springframework.boot.autoconfigure.condition.OnBeanCondition.getMatchingBeans(OnBeanCondition.java:213)
        at 
org.springframework.boot.autoconfigure.condition.OnBeanCondition.evaluateConditionalOnMissingBean(OnBeanCondition.java:196)
        at 
org.springframework.boot.autoconfigure.condition.OnBeanCondition.getMatchOutcome(OnBeanCondition.java:143)
        at 
org.springframework.boot.autoconfigure.condition.SpringBootCondition.matches(SpringBootCondition.java:47)
        ... 17 common frames omitted
   Caused by: java.lang.NoClassDefFoundError: javax/servlet/Filter
        at java.base/java.lang.Class.getDeclaredMethods0(Native Method)
        at java.base/java.lang.Class.privateGetDeclaredMethods(Class.java:3458)
        at java.base/java.lang.Class.getDeclaredMethods(Class.java:2557)
        at 
org.springframework.util.ReflectionUtils.getDeclaredMethods(ReflectionUtils.java:465)
        ... 34 common frames omitted
   Caused by: java.lang.ClassNotFoundException: javax.servlet.Filter
        at 
java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)
        at 
java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188)
        at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
        ... 38 common frames omitted
   
   ```
   
   ### What was the expected outcome?
   
   
   <img width="656" alt="Image" 
src="https://github.com/user-attachments/assets/3fd2d8a1-c8d5-4303-97e0-8726b795fa92";
 />
   AbstractShiroWebFilterConfiguration is still import **javax.servlet.Filter**;
   
   ### How to reproduce
   
   1.AbstractShiroWebFilterConfiguration code
   
   ### Debug logs
   
   _No response_


-- 
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: issues-unsubscr...@shiro.apache.org.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@shiro.apache.org
For additional commands, e-mail: issues-h...@shiro.apache.org

Reply via email to