yangjj-iso opened a new pull request, #7598:
URL: https://github.com/apache/shenyu/pull/7598

   Fixes #7591.
   
   Persistent AI proxy key-resolution failures can repeatedly enqueue work in 
an unbounded executor and retain selector cache entries indefinitely. Limit the 
executor to 10 workers and 1,024 queued tasks, and return an empty resolution 
when task submission is rejected.
   
   Cap successful and negative caches at 10,000 entries each. Failed or missing 
resolutions have a five-second cooldown shared by single and batch lookups, and 
selector invalidation clears both caches. Register each shared future before 
task submission and ignore completions from invalidated flights to prevent 
leaked in-flight entries and stale key writes.
   
   Validation:
   - 32 tests passed: `AiProxyRealKeyResolverTest` (20) and 
`AiProxyApiKeyServiceImplTest` (12).
   - Checkstyle passed across the 34-module admin dependency reactor.
   - `shenyu-admin` Apache RAT check passed.
   
   ```bash
   ./mvnw -pl shenyu-admin -am test 
-Dtest=AiProxyRealKeyResolverTest,AiProxyApiKeyServiceImplTest 
-Dsurefire.failIfNoSpecifiedTests=false -Dmaven.javadoc.skip=true 
-Djacoco.skip=true -Drat.skip=true
   ./mvnw -pl shenyu-admin apache-rat:check
   ```
   
   - [x] I have read the contribution guidelines.
   - [x] Test cases back the changes.
   - [ ] Full repository `./mvnw clean install -Dmaven.javadoc.skip=true` 
(targeted validation above).
   
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to