You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@streampipes.apache.org by "dominikriemer (via GitHub)" <gi...@apache.org> on 2023/01/29 15:12:32 UTC

[PR] Sp 1157 upgrade third party services (streampipes)

dominikriemer opened a new pull request, #1174:
URL: https://github.com/apache/streampipes/pull/1174

   <!--
     ~ Licensed to the Apache Software Foundation (ASF) under one or more
     ~ contributor license agreements.  See the NOTICE file distributed with
     ~ this work for additional information regarding copyright ownership.
     ~ The ASF licenses this file to You under the Apache License, Version 2.0
     ~ (the "License"); you may not use this file except in compliance with
     ~ the License.  You may obtain a copy of the License at
     ~
     ~    http://www.apache.org/licenses/LICENSE-2.0
     ~
     ~ Unless required by applicable law or agreed to in writing, software
     ~ distributed under the License is distributed on an "AS IS" BASIS,
     ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     ~ See the License for the specific language governing permissions and
     ~ limitations under the License.
     ~
     -->
     
     <!--
   Thanks for contributing! Here are some tips you can follow to help us incorporate your contribution quickly and easily:
   1. If this is your first time, please read our contributor guidelines:
       - https://streampipes.apache.org/getinvolved.html
       - https://cwiki.apache.org/confluence/display/STREAMPIPES/Getting+Started
   2. Make sure the PR title is formatted like: `[#<GitHub issue id>] PR title ...`
   3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., `[WIP][#<GitHub issue id>] PR title ...`.
   4. Please write your PR title to summarize what this PR proposes/fixes.
   5. Link the PR to the corresponding GitHub issue (if present) in the `Development` section in the right menu bar. 
   6. Be sure to keep the PR description updated to reflect all changes.
   7. If possible, provide a concise example to reproduce the issue for a faster review.
   8. Make sure tests pass via `mvn clean install`.
   9. (Optional) If the contribution is large, please file an Apache ICLA
       - http://apache.org/licenses/icla.pdf
   -->
   
   ### Purpose
   <!--
   Please clarify what changes you are proposing and describe how those changes will address the issue.
   Furthermore, describe potential consequences the changes might have.
   -->
   
   Bump Influx to version 2.6, refactor code and add migrations to update existing installations.
   
   ### Remarks
   <!--
   Is there anything left we need to pay attention on?
   Are there some references that might be important? E.g. links to Confluence, or discussions
   on the mailing list or GitHub.
   -->
   PR introduces (a) breaking change(s): no
   
   PR introduces (a) deprecation(s): no
   


-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Sp 1157 upgrade third party services (streampipes)

Posted by "dominikriemer (via GitHub)" <gi...@apache.org>.
dominikriemer commented on code in PR #1174:
URL: https://github.com/apache/streampipes/pull/1174#discussion_r1091089962


##########
docker-compose.yml:
##########
@@ -138,13 +141,20 @@ services:
       spnet:
 
   influxdb:
-    image: fogsyio/influxdb:1.7
+    image: influxdb:2.6
     environment:
       - INFLUXDB_DATA_ENGINE=tsm1
       - INFLUXDB_REPORTING_DISABLED=false
       - INFLUXDB_ADMIN_ENABLED=true
+      - DOCKER_INFLUXDB_INIT_USERNAME=admin

Review Comment:
   These are the env variables that are supported by the official image, so we can't change these unfortunately



-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Sp 1157 upgrade third party services (streampipes)

Posted by "dominikriemer (via GitHub)" <gi...@apache.org>.
dominikriemer commented on code in PR #1174:
URL: https://github.com/apache/streampipes/pull/1174#discussion_r1094596519


##########
installer/cli/.env:
##########
@@ -35,3 +35,8 @@ COMPOSE_PROJECT_NAME=streampipes
 # 
 # default: activemq
 #SP_MQTT_HOST=mosquitto
+
+
+# For database migration in v0.91.0 - set init mode to 'upgrade' to migrate an existing installation
+SP_INFLUX_INIT_MODE=setup
+#SP_INFLUX_INIT_MODE=upgrade

Review Comment:
   I created a ticket for this: #1206 



-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Sp 1157 upgrade third party services (streampipes)

Posted by "dominikriemer (via GitHub)" <gi...@apache.org>.
dominikriemer commented on code in PR #1174:
URL: https://github.com/apache/streampipes/pull/1174#discussion_r1091091317


##########
docker-compose.yml:
##########
@@ -138,13 +141,20 @@ services:
       spnet:
 
   influxdb:
-    image: fogsyio/influxdb:1.7
+    image: influxdb:2.6
     environment:
       - INFLUXDB_DATA_ENGINE=tsm1
       - INFLUXDB_REPORTING_DISABLED=false
       - INFLUXDB_ADMIN_ENABLED=true
+      - DOCKER_INFLUXDB_INIT_USERNAME=admin
+      - DOCKER_INFLUXDB_INIT_PASSWORD=sp-admin
+      - DOCKER_INFLUXDB_INIT_ADMIN_TOKEN=sp-admin
+      - DOCKER_INFLUXDB_INIT_ORG=sp
+      - DOCKER_INFLUXDB_INIT_BUCKET=sp
+      - DOCKER_INFLUXDB_INIT_MODE=setup
     volumes:
       - influxdb:/var/lib/influxdb

Review Comment:
   Yes, this is needed for automatic migration (we can't do a fully automated migration since the INIT_MODE must be set to either setup or upgrade).
   We can remove the additional volume after the release



-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Sp 1157 upgrade third party services (streampipes)

Posted by "bossenti (via GitHub)" <gi...@apache.org>.
bossenti commented on code in PR #1174:
URL: https://github.com/apache/streampipes/pull/1174#discussion_r1091070364


##########
docker-compose.yml:
##########
@@ -138,13 +141,20 @@ services:
       spnet:
 
   influxdb:
-    image: fogsyio/influxdb:1.7
+    image: influxdb:2.6
     environment:
       - INFLUXDB_DATA_ENGINE=tsm1
       - INFLUXDB_REPORTING_DISABLED=false
       - INFLUXDB_ADMIN_ENABLED=true
+      - DOCKER_INFLUXDB_INIT_USERNAME=admin
+      - DOCKER_INFLUXDB_INIT_PASSWORD=sp-admin
+      - DOCKER_INFLUXDB_INIT_ADMIN_TOKEN=sp-admin
+      - DOCKER_INFLUXDB_INIT_ORG=sp
+      - DOCKER_INFLUXDB_INIT_BUCKET=sp
+      - DOCKER_INFLUXDB_INIT_MODE=setup
     volumes:
       - influxdb:/var/lib/influxdb

Review Comment:
   Is the old one still required?
   Is it used to ensure backwards compatibility?



##########
installer/cli/deploy/standalone/couchdb/docker-compose.yml:
##########
@@ -16,9 +16,12 @@
 version: "3.4"
 services:
   couchdb:
-    image: couchdb:2.3.1
+    image: couchdb:3.3.1

Review Comment:
   please include this in the PR's description as well



##########
docker-compose.yml:
##########
@@ -138,13 +141,20 @@ services:
       spnet:
 
   influxdb:
-    image: fogsyio/influxdb:1.7
+    image: influxdb:2.6
     environment:
       - INFLUXDB_DATA_ENGINE=tsm1
       - INFLUXDB_REPORTING_DISABLED=false
       - INFLUXDB_ADMIN_ENABLED=true
+      - DOCKER_INFLUXDB_INIT_USERNAME=admin

Review Comment:
   Do we want to align the naming style here with the envs of couchdb? 



##########
installer/cli/.env:
##########
@@ -35,3 +35,8 @@ COMPOSE_PROJECT_NAME=streampipes
 # 
 # default: activemq
 #SP_MQTT_HOST=mosquitto
+
+
+# For database migration in v0.91.0 - set init mode to 'upgrade' to migrate an existing installation
+SP_INFLUX_INIT_MODE=setup
+#SP_INFLUX_INIT_MODE=upgrade

Review Comment:
   We should provide an upgrade guide somewhere and also shortly describe this change in the PR's description (for the release notes)



##########
streampipes-commons/src/main/java/org/apache/streampipes/commons/constants/Envs.java:
##########
@@ -23,9 +23,9 @@ public enum Envs {
   SP_PORT("SP_PORT", null),
 
   @Deprecated(since = "0.90.0", forRemoval = true)
-  SP_CONSUL_LOCATION("CONSUL_LOCATION", "consul"),
+  SP_CONSUL_LOCATION("CONSUL_LOCATION", "consul", "localhost"),

Review Comment:
   Is the deprecation here still valid?



-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Sp 1157 upgrade third party services (streampipes)

Posted by "dominikriemer (via GitHub)" <gi...@apache.org>.
dominikriemer commented on code in PR #1174:
URL: https://github.com/apache/streampipes/pull/1174#discussion_r1091089523


##########
streampipes-commons/src/main/java/org/apache/streampipes/commons/constants/Envs.java:
##########
@@ -23,9 +23,9 @@ public enum Envs {
   SP_PORT("SP_PORT", null),
 
   @Deprecated(since = "0.90.0", forRemoval = true)
-  SP_CONSUL_LOCATION("CONSUL_LOCATION", "consul"),
+  SP_CONSUL_LOCATION("CONSUL_LOCATION", "consul", "localhost"),

Review Comment:
   Yes, but we can remove this in the next version



-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Sp 1157 upgrade third party services (streampipes)

Posted by "bossenti (via GitHub)" <gi...@apache.org>.
bossenti commented on code in PR #1174:
URL: https://github.com/apache/streampipes/pull/1174#discussion_r1091125719


##########
docker-compose.yml:
##########
@@ -138,13 +141,20 @@ services:
       spnet:
 
   influxdb:
-    image: fogsyio/influxdb:1.7
+    image: influxdb:2.6
     environment:
       - INFLUXDB_DATA_ENGINE=tsm1
       - INFLUXDB_REPORTING_DISABLED=false
       - INFLUXDB_ADMIN_ENABLED=true
+      - DOCKER_INFLUXDB_INIT_USERNAME=admin

Review Comment:
   Makes sense 💡 



-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Sp 1157 upgrade third party services (streampipes)

Posted by "dominikriemer (via GitHub)" <gi...@apache.org>.
dominikriemer merged PR #1174:
URL: https://github.com/apache/streampipes/pull/1174


-- 
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: dev-unsubscribe@streampipes.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org