Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#103 thrift server chart #121

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Baseline Helm chart for deploying the Spark History Server. Chart is built and m
# Basic usage with Helm CLI
To use the module, perform [extension-helm setup](../README.md#leveraging-extensions-helm) and override the chart version with the desired aiSSEMBLE version. For example:
```bash
helm install spark-operator ghcr.io/boozallen/aissemble-spark-history-chart --version <AISSEMBLE-VERSION>
helm install spark-history ghcr.io/boozallen/aissemble-spark-history-chart --version <AISSEMBLE-VERSION>
```
_**NOTE:**_ *the version should match the aiSSEMBLE project version.*

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,6 @@
<plugin>
<groupId>${group.helm.plugin}</groupId>
<artifactId>helm-maven-plugin</artifactId>
<configuration>
Copy link
Contributor Author

@peter-mcclonski peter-mcclonski May 31, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I: Unused relic from a previous copy-paste

<values>
<!-- sets the spark-operator chart to make use of the current project version for our image -->
<overrides>
<spark-operator.image.tag>${project.version}</spark-operator.image.tag>
</overrides>
</values>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
Expand All @@ -38,4 +30,4 @@
</plugins>
</build>

</project>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ .Release.Name }}-spark-conf
name: {{ .Release.Name }}-shs-spark-conf
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I: There are several changes like this-- In a downstream project, merely using .Release.Name resulted in both subcharts generating their k8s resources with the same names, causing conflicts.

data:
sparkConf:
{{- toYaml .Values.sparkConf | nindent 8 }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .Release.Name }}
name: {{ .Release.Name }}-shs
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Q: Wouldn't the release name already mention that it's a spark history server? So it'd be something like my-spark-history-shs which feels odd.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The problem here is how it works when unified in a single chart in a downstream project. When you generate out spark-infrastructure downstream, with a dependency on both the shs chart and sts chart, when the chart is deployed, .Release.Name is identical for both (specifically, spark-infrastructure)

{{- if .Values.deployment.annotations }}
annotations:
{{ toYaml .Values.deployment.annotations | default "" }}
Expand Down Expand Up @@ -112,7 +112,7 @@ spec:
{{- if not (eq .Values.sparkConf "") }}
- name: spark-config
configMap:
name: {{ .Release.Name }}-spark-conf
name: {{ .Release.Name }}-shs-spark-conf
items:
- key: sparkConf
path: spark-defaults.conf
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ .Release.Name }}-ingress
name: {{ .Release.Name }}-shs-ingress
{{- with .Values.ingress.metadata.annotations }}
annotations:
{{- toYaml . | nindent 8 }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
apiVersion: v1
kind: Service
metadata:
name: {{ .Release.Name }}-service
name: {{ .Release.Name }}-shs-service
{{- if .Values.service.annotations }}
annotations: {{ .Values.service.annotations }}
{{- end }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ tests:
asserts:
- equal:
path: metadata.name
value: RELEASE-NAME-ingress
value: RELEASE-NAME-shs-ingress
- notExists:
path: metadata.annotations

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ tests:
count: 1
- equal:
path: metadata.name
value: RELEASE-NAME-service
value: RELEASE-NAME-shs-service
- notExists:
path: metadata.annotations
- equal:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ tests:
- notFailedTemplate: {}
- equal:
path: metadata.name
value: "RELEASE-NAME-spark-conf"
value: "RELEASE-NAME-shs-spark-conf"
- equal:
path: data.sparkConf
value: "spark.executor.instances: 2"
Expand All @@ -41,7 +41,7 @@ tests:
content:
name: spark-config
configMap:
name: RELEASE-NAME-spark-conf
name: RELEASE-NAME-shs-spark-conf
items:
- key: sparkConf
path: spark-defaults.conf
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
target
pom.xml
examples/*
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
name: aissemble-thrift-server-chart
# Version is automatically set by the plugin so this is only a placeholder
version: 1.0.0
apiVersion: v2
description: Baseline Spark History chart -- see the extensions-helm directory in aiSSEMBLE for more details.
# App Version is automatically set by the plugin so this is only a placeholder
appVersion: 1.0.0
sources:
- https://github.com/boozallen/aissemble
dependencies: []
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
Booz Allen Public License v1.0
------------------------------

INTRODUCTION
The Booz Allen Public License allows government, non-profit academic, other non-profit, and commercial entities access to distinctive, disruptive, and robust code with the goal of Empowering People to Change the World(SM). Products licensed under the Booz Allen Public License are founded on the basis that collective ingenuity can make the largest impact in the community.

DEFINITIONS
* **Commercial Entity.** “Commercial Entity” means any individual or entity other than a government, non-profit academic, or other non-profit entity.
* **Derivative.** “Derivative” means any work of authorship in Source Code or Object Code form that results from an addition to, deletion from, or modification of the Source Code of the Product.
* **License.** “License” means this Booz Allen Public License.
* **Object Code.** “Object Code” means the form resulting from transformation or translation of Source Code into machine readable code, including but not limited to, compiled object code.
* **Originator.** “Originator” means each individual or legal entity that creates, contributes to the creation of, or owns the Product.
* **Patent Claims.** “Patent Claims” means any patent claim(s) in any patent to which Originator has a right to grant a license that would be infringed by Your making, using, selling, offering for sale, having made, or importing of the Product, but for the grant of this License.
* **Product.** “Product” means the Source Code of the software which the initial Originator made available under this License, and any Derivative of such Source Code.
* **Source Code.** “Source Code” means software in human-readable form.
* **You.** “You” means either an individual or an entity (if you are taking this license on behalf of an entity) that exercises the rights granted under this License.

LICENSE
**Government/Non-Profit Academic/Other Non-Profit.**
This Section applies if You are not a Commercial Entity.

* **License.** Subject to the terms and conditions of this License, each Originator hereby grants You a perpetual, worldwide, non-exclusive, royalty-free license to reproduce, display, perform, modify, distribute and otherwise use the Product and Derivatives, in Source Code and Object Code form, in accordance with the terms and conditions of this License in order to support the general public good and for your internal business purposes.
* **Distribution.** You may distribute to third parties copies of the Product, including any Derivative that You create, in Source Code or Object Code form. If You distribute copies of the Product, including any Derivative that You create, in Source Code form, such distribution must be under the terms of this License and You must inform recipients of the Source Code that the Product is governed under this License and how they can obtain a copy of this License. You may distribute to third parties copies of the Product, including any Derivative that You create, in Object Code form, or allow third parties to access or use the Product, including any Derivative that You create, under a license of Your choice.
* **Commercial Sales.** You may not distribute, or allow third parties to access or use, the Product or any Derivative for a fee, unless You first obtain permission from the Originator. If Booz Allen Hamilton is the Originator, please contact Booz Allen Hamilton at <[email protected]>.

**Commercial Entities**.
This Section applies if You are a Commercial Entity.

* **License.** Subject to the terms and conditions of this License, each Originator hereby grants You a perpetual, worldwide, non-exclusive, royalty-free license to reproduce, display, perform, modify, distribute and otherwise use the Product and Derivatives, in Source Code and Object Code form, in accordance with the terms and conditions of this License for the sole purpose of Your internal business purposes and the provision of services to government, non-profit academic, and other non-profit entities.
* **Distribution and Derivatives.** You may distribute to third parties copies of the Product, including any Derivative that You create, in Source Code or Object Code form. If You distribute copies of the Product, including any Derivative that You create, in Source Code form, such distribution must be under the terms of this License and You must inform recipients of the Source Code that the Product is governed under this License and how they can obtain a copy of this License. You may distribute to third parties copies of the Product, including any Derivative that You create, in Object Code form, or allow third parties to access or use the Product, including any Derivative that You create, under a license of Your choice, provided that You make available, and inform the recipient of such distribution how they can obtain, a copy of the Source Code thereof, at no charge, and inform the recipient of the Source Code that the Product is governed under this License and how they can obtain a copy of this License.
* **Commercial Sales.** You may not distribute, or allow third parties to access or use, the Product or any Derivative for a fee, unless You first obtain permission from the Originator. If Booz Allen Hamilton, please contact Booz Allen Hamilton at <[email protected]>.


**Patent Claim(s)**.
This Section applies regardless of whether You are a government, non-profit academic, or other non-profit entity or a Commercial Entity.

* **Patent License.** Subject to the limitations in the Sections above, each Originator hereby grants You a perpetual, worldwide, non-exclusive, royalty-free license under Patent Claims of such Originator to make, use, sell, offer for sale, have made, and import the Product. The foregoing patent license does not apply (a) to any code that an Originator has removed from the Product, or (b) for infringement caused by Your modifications of the Product or the combination of any Derivative created by You or on Your behalf with other software.

GENERAL TERMS
This Section applies regardless of whether You are a government, non-profit academic, or other non-profit entity or a Commercial Entity.

* **Required Notices.** If You distribute the Product or a Derivative, in Object Code or Source Code form, You shall not remove or otherwise modify any proprietary markings or notices contained within or placed upon the Product or any Derivative. Any distribution of the Product or a Derivative, in Object Code or Source Code form, shall contain a clear and conspicuous Originator copyright and license reference in accordance with the below:
* *Unmodified Product Notice*: “This software package is licensed under the Booz Allen Public License. Copyright © 20__ [Copyright Holder Name]. All Rights Reserved.”
* *Derivative Notice*: “This software package is licensed under the Booz Allen Public License. Portions of this code are Copyright © 20__ [Copyright Holder Name]. All Rights Reserved.”
* **Compliance with Laws.** You agree that You shall not reproduce, display, perform, modify, distribute and otherwise use the Product in any way that violates applicable law or regulation or infringes or violates the rights of others, including, but not limited to, third party intellectual property, privacy, and publicity rights.
* **Disclaimer.** You understand that the Product is licensed to You, and not sold. The Product is provided on an “As Is” basis, without any warranties, representations, and guarantees, whether oral or written, express, implied or statutory, with regard to the Product, including without limitation, warranties of merchantability, fitness for a particular purpose, title, non-infringement, non-interference, and warranties arising from course of dealing or usage of trade, to the maximum extent permitted by applicable law. Originator does not warrant that (i) the Product will meet your needs; (ii) the Product will be error-free or accessible at all times; or (iii) the use or the results of the use of the Product will be correct, accurate, timely, or otherwise reliable. You acknowledge that the Product has not been prepared to meet Your individual requirements, whether or not such requirements have been communicated to Originator. You assume all responsibility for use of the Product.
* **Limitation of Liability.** Under no circumstances and under no legal theory, whether tort (including negligence), contract, or otherwise, shall any Originator, or anyone who distributes the Product in accordance with this License, be liable to You for any direct, indirect, special, incidental, or consequential damages of any character including, without limitation, damages for lost profits, loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses, even if informed of the possibility of such damages.
* **Export Control.** The Product is subject to U.S. export control laws and may be subject to export or import regulations in other countries. You agree to strictly comply with all such laws and regulations and acknowledges that You are responsible for obtaining such licenses to export, re-export, or import as may be required.
* **Severability.** If the application of any provision of this License to any particular facts or circumstances shall be held to be invalid or unenforceable, then the validity and enforceability of other provisions of this License shall not in any way be affected or impaired thereby.
Loading