xxubai opened a new pull request, #11361:
URL: https://github.com/apache/gravitino/pull/11361

   ### What changes were proposed in this pull request?
   
   This PR hardens the parsing of `gravitino.server.webserver.customFilters`.
   
   The parsing now trims comma-separated entries and ignores invalid empty 
entries, including blank values, `""`, and `''`, before exposing the custom 
filter set to Jetty.
   
   It also extends `TestJettyServerConfig` to cover quote-only and mixed custom 
filter values.
   
   ### Why are the changes needed?
   
   If `gravitino.server.webserver.customFilters` is rendered or configured as 
`""`, Gravitino currently preserves that value as a filter class name. Jetty 
then attempts to load a class named `""`, causing the WebAppContext startup to 
fail with `ClassNotFoundException`.
   
   The server should tolerate this malformed empty configuration and treat it 
as no custom filter.
   
   Fix: #11360
   
   ### Does this PR introduce _any_ user-facing change?
   
   No new configuration keys or APIs are introduced.
   
   This only makes the existing `gravitino.server.webserver.customFilters` 
parsing more tolerant by ignoring quote-only empty values.
   
   ### How was this patch tested?
   
   ```text
   ./gradlew spotlessApply
   ./gradlew :server-common:test --tests 
org.apache.gravitino.server.web.TestJettyServerConfig -PskipITs 
-PskipDockerTests=false
   git diff --check
   ```
   


-- 
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