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

ulyssesyou pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-kyuubi.git


The following commit(s) were added to refs/heads/master by this push:
     new 1f87aec  [KYUUBI #1325] [KYUUBI#1324] Add resource limit for kyuubi 
server on kubernetes
1f87aec is described below

commit 1f87aec04ea6b26ed18eda65d58cfcda08e4c2d7
Author: hongdongdong <[email protected]>
AuthorDate: Wed Nov 3 15:01:23 2021 +0800

    [KYUUBI #1325] [KYUUBI#1324] Add resource limit for kyuubi server on 
kubernetes
    
    <!--
    Thanks for sending a pull request!
    
    Here are some tips for you:
      1. If this is your first time, please read our contributor guidelines: 
https://kyuubi.readthedocs.io/en/latest/community/contributions.html
      2. If the PR is related to an issue in 
https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your 
PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
      3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., 
'[WIP][KYUUBI #XXXX] Your PR title ...'.
    -->
    
    ### _Why are the changes needed?_
    <!--
    Please clarify why the changes are needed. For instance,
      1. If you add a feature, you can talk about the use case of it.
      2. If you fix a bug, you can clarify why it is a bug.
    -->
    Add resource limit config for kyuubi server on kubernetes.
    
    ### _How was this patch tested?_
    - [ ] Add some test cases that check the changes thoroughly including 
negative and positive cases if possible
    
    - [ ] Add screenshots for manual tests if appropriate
    
    - [X] [Run 
test](https://kyuubi.readthedocs.io/en/latest/develop_tools/testing.html#running-tests)
 locally before make a pull request
    
    Closes #1325 from hddong/add-resource-limit.
    
    Closes #1325
    
    8ec3d987 [hongdongdong] fix
    51f5fbeb [hongdongdong] [KYUUBI#1324] Add resource limit for kyuubi server 
on kubernetes
    
    Authored-by: hongdongdong <[email protected]>
    Signed-off-by: ulysses-you <[email protected]>
---
 docker/helm/templates/kyuubi-deployment.yaml |  2 ++
 docker/helm/values.yaml                      | 14 +++++++++++++-
 2 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/docker/helm/templates/kyuubi-deployment.yaml 
b/docker/helm/templates/kyuubi-deployment.yaml
index f3f715d..2482113 100644
--- a/docker/helm/templates/kyuubi-deployment.yaml
+++ b/docker/helm/templates/kyuubi-deployment.yaml
@@ -46,6 +46,8 @@ spec:
             - name: frontend-port
               containerPort: {{ .Values.server.bind.port }}
               protocol: TCP
+          resources:
+            {{- toYaml .Values.resources | nindent 12 }}
           volumeMounts:
             - name: kyuubi-defaults
               mountPath: {{ .Values.server.conf.mountPath }}
diff --git a/docker/helm/values.yaml b/docker/helm/values.yaml
index d203177..93df2a4 100644
--- a/docker/helm/values.yaml
+++ b/docker/helm/values.yaml
@@ -41,4 +41,16 @@ service:
   # to change:
   #   vim kube-apiserver.yaml (usually under path: /etc/kubernetes/manifests/)
   #   add or change line 'service-node-port-range=1-32767' under kube-apiserver
-  port: 30009
\ No newline at end of file
+  port: 30009
+
+resources: {}
+  # Used to specify resource, default unlimited.
+  # If you do want to specify resources:
+  #   1. remove the curly braces after 'resources:'
+  #   2. uncomment the following lines
+  # limits:
+  #   cpu: 4
+  #   memory: 10Gi
+  # requests:
+  #   cpu: 2
+  #   memory: 4Gi

Reply via email to