Skip to content
This repository has been archived by the owner on Nov 18, 2022. It is now read-only.

[STREAMPIPES-no-issue-#] Document steps which were required to install StreamPipes into a k8s cluster in a new Troubleshooting segment in the README. #15

Open
wants to merge 9 commits into
base: dev
Choose a base branch
from
2 changes: 1 addition & 1 deletion cli/.env
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# limitations under the License.

SP_DOCKER_REGISTRY=apachestreampipes/
SP_VERSION=0.67.0-SNAPSHOT
SP_VERSION=0.67.0
SP_SUBNET=172.31.0.0/16
SP_CONSUL_CONTAINER_IP=172.31.0.9
COMPOSE_PROJECT_NAME=streampipes
4 changes: 2 additions & 2 deletions cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ The StreamPipes command-line interface (CLI) is focused on developers in order t
* new core features for **backend** and **ui**.

<!-- BEGIN do not edit: set via ../upgrade_versions.sh -->
**Current version:** 0.67.0-SNAPSHOT
**Current version:** 0.67.0
<!-- END do not edit -->

## TL;DR
Expand All @@ -42,7 +42,7 @@ streampipes up -d
The CLI is basically a wrapper around multiple `docker` and `docker-compose` commands plus some additional sugar.

* Docker >= 17.06.0
* Docker-Compose >= 1.17.0 (Compose file format: 3.4)
* Docker-Compose >= 1.26.0 (Compose file format: 3.4)
* Google Chrome (recommended), Mozilla Firefox, Microsoft Edge
* For Windows Developer: GitBash only

Expand Down
5 changes: 4 additions & 1 deletion cli/bin/common
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,10 @@ deployment_notice() {
Check docs for help: https://streampipes.apache.org/docs

If your environment contains the StreamPipes UI, open your browser and follow
the instructions to get started: http://localhost/
the instructions to get started:

Local Docker for Mac/Windows, Linux: http://localhost/
Remote Docker host: http://HOST_IP/

EOF
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
version: "3.4"
services:
pipeline-elements-all-flink:
image: ${SP_DOCKER_REGISTRY}/pipeline-elements-all-flink:${SP_VERSION}
image: ${SP_DOCKER_REGISTRY}pipeline-elements-all-flink:${SP_VERSION}
depends_on:
- "consul"
- "jobmanager"
Expand Down
2 changes: 1 addition & 1 deletion compose/.env
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

SP_VERSION=0.67.0-SNAPSHOT
SP_VERSION=0.67.0
SP_DOCKER_REGISTRY=apachestreampipes
SP_SUBNET=172.31.0.0/16
SP_CONSUL_CONTAINER_IP=172.31.0.9
Expand Down
2 changes: 1 addition & 1 deletion compose/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
StreamPipes Compose is a simple collection of user-friendly `docker-compose` files that easily lets gain first-hand experience with Apache StreamPipes.

<!-- BEGIN do not edit: set via ../upgrade_versions.sh -->
**Current version:** 0.67.0-SNAPSHOT
**Current version:** 0.67.0
<!-- END do not edit -->

> **NOTE**: We recommend StreamPipes Compose to only use for initial try-out and testing. If you are a developer and want to develop new pipeline elements or core feature, use the [StreamPipes CLI](../cli).
Expand Down
4 changes: 2 additions & 2 deletions k8s/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@
# limitations under the License.

apiVersion: v1
appVersion: "0.67.0-SNAPSHOT"
appVersion: "0.67.0"
description: Self-Service Data Analytics for the Industrial IoT
name: streampipes-helm-chart
home: https://streampipes.apache.org
version: 0.67.0-SNAPSHOT
version: 0.67.0
icon: https://avatars1.githubusercontent.com/u/33908576
maintainers:
- name: Dominik Riemer
Expand Down
30 changes: 29 additions & 1 deletion k8s/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
StreamPipes k8s is a helm chart to deploy StreamPipes on Kubernetes.

<!-- BEGIN do not edit: set via ../upgrade_versions.sh -->
**Current version:** 0.67.0-SNAPSHOT
**Current version:** 0.67.0
<!-- END do not edit -->

## Prerequisite
Expand Down Expand Up @@ -108,3 +108,31 @@ We'd love to hear your feedback! Subscribe to [users@streampipes.apache.org](mai

## License
[Apache License 2.0](../LICENSE)

## Troubleshooting
### Some of the Deployments Never Reach 'Ready' State
#### ui
The UI Deployment specifies so-called init containers which wait for the following deployments:
* backend
* connect-master
* consul
* couchdb
* activemq

This means that when at least one of these deployments are not reachable the containers running the UI will not start up. Chances are when you fix the issues with the the others it will start up fine.
doemski marked this conversation as resolved.
Show resolved Hide resolved

#### backend
##### Multi-Attach Error
###### Problem
`kubectl describe pod <backend-pod-name>` shows the following message:

```Multi-Attach error for volume "pvc-xxx-xxx" Volume is already exclusively attached to one node and can't be attached to another```

The issue is that the 'backend' Deployment and the 'pipeline-elements-all-jvm' are specified to use the same PersistentVolume. For this to be possible without restrictions, the used StorageClass (which defaults to your cluster 'default') needs to create PersistentVolumes which are set to "ReadWriteMany". This means that the same volume can be accessed by multiple Nodes of the Kubernetes cluster.

If you see this error then your 'default' StorageClass does not fulfill those requirements.

###### Solution
The easiest way would be to switch to a StorageClass which allows for "ReadWriteMany" if possible.

If that is not possible assign the Pods of the two Deployments (backend and pipeline-elements-all-jvm) to be always deployed on the same Node. For one way to do so see the Kubernetes documentation (https://kubernetes.io/docs/tasks/configure-pod-container/assign-pods-nodes/)
doemski marked this conversation as resolved.
Show resolved Hide resolved
2 changes: 1 addition & 1 deletion k8s/templates/core/backend/backend-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ spec:
claimName: backend-pvc
- name: files-pv
persistentVolumeClaim:
claimName: files-pvc
claimName: files-pvc
containers:
- name: backend
image: {{ .Values.streampipes.registry }}/backend:{{ .Values.streampipes.version }}
Expand Down
2 changes: 1 addition & 1 deletion k8s/templates/extensions/pipeline-elements/files-pvc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ metadata:
name: files-pvc
spec:
accessModes:
- ReadWriteMany
- ReadWriteOnce
resources:
requests:
storage: 256Mi
44 changes: 0 additions & 44 deletions k8s/templates/external/iotdb/iotdb-deployment.yaml

This file was deleted.

27 changes: 0 additions & 27 deletions k8s/templates/external/iotdb/iotdb-pvc.yaml

This file was deleted.

29 changes: 0 additions & 29 deletions k8s/templates/external/iotdb/iotdb-service.yaml

This file was deleted.

50 changes: 0 additions & 50 deletions k8s/templates/external/redis/redis-deployment.yaml

This file was deleted.

27 changes: 0 additions & 27 deletions k8s/templates/external/redis/redis-pvc.yaml

This file was deleted.

29 changes: 0 additions & 29 deletions k8s/templates/external/redis/redis-service.yaml

This file was deleted.

2 changes: 1 addition & 1 deletion k8s/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ deployment: lite
pullPolicy: "Always"

streampipes:
version: "0.67.0-SNAPSHOT"
version: "0.67.0"
registry: "apachestreampipes"

external:
Expand Down