This is an automated email from the ASF dual-hosted git repository.

dongjoon pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/spark-kubernetes-operator.git


The following commit(s) were added to refs/heads/main by this push:
     new a950e51  [SPARK-55567] Remove `HttpServletRequest` usage
a950e51 is described below

commit a950e510562d8220730c342f92494ce4e6624981
Author: Dongjoon Hyun <[email protected]>
AuthorDate: Mon Feb 16 20:57:14 2026 -0800

    [SPARK-55567] Remove `HttpServletRequest` usage
    
    ### What changes were proposed in this pull request?
    
    This PR aims to remove `HttpServletRequest` usage.
    
    ### Why are the changes needed?
    
    To remove unnecessary package reference which was added.
    - #23
    
    **BEFORE**
    
    ```
    $ git grep HttpServletRequest | wc -l
           2
    ```
    
    **AFTER**
    
    ```
    $ git grep HttpServletRequest | wc -l
           0
    ```
    
    ### Does this PR introduce _any_ user-facing change?
    
    No.
    
    ### How was this patch tested?
    
    Pass the CIs.
    
    ### Was this patch authored or co-authored using generative AI tooling?
    
    Generated-by: `Opus 4.5` on `Claude Code`
    
    Closes #509 from dongjoon-hyun/SPARK-55567.
    
    Authored-by: Dongjoon Hyun <[email protected]>
    Signed-off-by: Dongjoon Hyun <[email protected]>
---
 .../apache/spark/k8s/operator/metrics/PrometheusPullModelHandler.java | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git 
a/spark-operator/src/main/java/org/apache/spark/k8s/operator/metrics/PrometheusPullModelHandler.java
 
b/spark-operator/src/main/java/org/apache/spark/k8s/operator/metrics/PrometheusPullModelHandler.java
index 6442d7f..5ae9f67 100644
--- 
a/spark-operator/src/main/java/org/apache/spark/k8s/operator/metrics/PrometheusPullModelHandler.java
+++ 
b/spark-operator/src/main/java/org/apache/spark/k8s/operator/metrics/PrometheusPullModelHandler.java
@@ -37,7 +37,6 @@ import com.codahale.metrics.Snapshot;
 import com.codahale.metrics.Timer;
 import com.sun.net.httpserver.HttpExchange;
 import com.sun.net.httpserver.HttpHandler;
-import jakarta.servlet.http.HttpServletRequest;
 import lombok.Getter;
 import lombok.extern.slf4j.Slf4j;
 
@@ -95,8 +94,7 @@ public class PrometheusPullModelHandler extends 
PrometheusServlet implements Htt
           formatMetricsSnapshot(),
           Map.of("Content-Type", List.of("text/plain; charset=utf-8; 
version=0.0.4")));
     } else {
-      HttpServletRequest httpServletRequest = null;
-      String value = getMetricsSnapshot(httpServletRequest);
+      String value = getMetricsSnapshot(null);
       sendMessage(
           exchange,
           HTTP_OK,


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to