Skip to content

Commit

Permalink
Merge branch 'thelastpickle:master' into last_restore_file-variable
Browse files Browse the repository at this point in the history
  • Loading branch information
ericsmalling authored Jan 13, 2025
2 parents 9bd80bf + 97aa027 commit 6ef7921
Show file tree
Hide file tree
Showing 42 changed files with 1,514 additions and 923 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 0.22.0-dev
current_version = 0.23.0-dev
commit = True
tag = False
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(\-(?P<release>[a-z]+))?
Expand Down
116 changes: 68 additions & 48 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,15 @@ jobs:
build:
strategy:
matrix:
python-version: [3.8, 3.9, "3.10", "3.11"]
python-version: [3.9, "3.10", "3.11"]
include:
- python-version: 3.8
tox-py: py38
- python-version: 3.9
tox-py: py39
- python-version: "3.10"
tox-py: py310
- python-version: "3.11"
tox-py: py311
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -32,6 +30,8 @@ jobs:
python-version: ${{ matrix.python-version }}
- name: Set up Poetry
uses: snok/install-poetry@v1
with:
version: 1.8.5
- name: Install dependencies
run: |
poetry install
Expand All @@ -55,10 +55,10 @@ jobs:
# Build debian packages
strategy:
matrix:
suite: [focal]
suite: [jammy]
include:
- suite: focal
os-version: ubuntu-20.04
- suite: jammy
os-version: ubuntu-22.04
fail-fast: false
runs-on: ${{ matrix.os-version }}
steps:
Expand All @@ -71,12 +71,12 @@ jobs:
then
echo "Updating debian changelog..."
cd packaging/docker-build
docker-compose build release && docker-compose run release
docker compose build release && docker compose run release
cd ../..
fi
cd packaging/docker-build
docker-compose build "cassandra-medusa-builder-${{ matrix.suite }}" \
&& docker-compose run "cassandra-medusa-builder-${{ matrix.suite }}"
docker compose build "cassandra-medusa-builder-${{ matrix.suite }}" \
&& docker compose run "cassandra-medusa-builder-${{ matrix.suite }}"
cd ../../packages
if [ -f "cassandra-medusa_${version}-0~${{ matrix.suite }}0_amd64.deb" ]; then
Expand All @@ -94,59 +94,67 @@ jobs:
exit $?
integration-tests:
needs: build
continue-on-error: ${{ matrix.experimental }}
needs: build
strategy:
fail-fast: false
matrix:
python-version: [3.8, 3.9, "3.10", "3.11"]
python-version: [3.9, "3.10", "3.11"]
it-backend: [local, s3, gcs, minio, azure, azure-hierarchical]
# IBM not included by default due to lite plan quota being easily exceeded
#it-backend: [local, s3, gcs, minio, ibm, azure]
cassandra-version: [2.2.19, 3.11.11, 4.0.0, 'github:apache/trunk']
cassandra-version: [2.2.19, 3.11.17, 4.0.15, 'github:apache/trunk']
java-version: [8.0.252, 11.0.25]
include:
# tweak the experimental flag for cassandra versions
- cassandra-version: 2.2.19
experimental: false
- cassandra-version: 3.11.11
- cassandra-version: 3.11.17
experimental: false
- cassandra-version: 4.0.0
- cassandra-version: 4.0.15
experimental: false
# explicitly include tests against python 3.11 and one version of cassandra
- python-version: "3.11"
cassandra-version: 4.0.0
cassandra-version: 4.0.15
it-backend: gcs
experimental: false
java-version: 11.0.25
# explicitly include tests against python 3.10 and one version of cassandra
- python-version: "3.10"
cassandra-version: 4.0.0
it-backend: gcs
experimental: false
# explicitly include tests against python 3.8 and one version of cassandra
- python-version: 3.8
cassandra-version: 4.0.0
cassandra-version: 4.0.15
it-backend: gcs
experimental: false
java-version: 11.0.25
exclude:
# no tests against trunk
- cassandra-version: 'github:apache/trunk'
# fewer tests against cassandra 3.11.11 (exclude all but local storage backends)
- it-backend: s3
cassandra-version: "3.11.11"
# no tests for C* 2.2 with java 11
- cassandra-version: 2.2.19
java-version: 11.0.25
# no tests for C* 3.11 with java 11
- cassandra-version: 3.11.17
java-version: 11.0.25
# no tests for C* 4.0 with java 8
- cassandra-version: 4.0.15
java-version: 8.0.252
# fewer tests against cassandra 3.11.17 (exclude all but s3 storage backends)
# we are not doing the local because it would run a scenario with mgmt-api which no longer supports 3.11
# but we still want some tests against 3.11.17, so we use s3 for at least some coverage
- it-backend: local
cassandra-version: "3.11.17"
- it-backend: gcs
cassandra-version: "3.11.11"
cassandra-version: "3.11.17"
- it-backend: minio
cassandra-version: "3.11.11"
cassandra-version: "3.11.17"
- it-backend: azure
cassandra-version: "3.11.11"
cassandra-version: "3.11.17"
- it-backend: azure-hierarchical
cassandra-version: "3.11.11"
cassandra-version: "3.11.17"
# no tests against non-python3.9, except the explicitly allowed combinations
- python-version: 3.8
- python-version: "3.10"
- python-version: "3.11"

runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
services:
minio:
image: lazybit/minio
Expand All @@ -167,10 +175,12 @@ jobs:
- name: Setup Java Action
uses: actions/setup-java@v1
with:
java-version: '8.0.252'
java-version: ${{ matrix.java-version}}
architecture: x64
- name: Setup Poetry
uses: snok/install-poetry@v1
with:
version: 1.8.5
- name: Install dependencies
run: |
poetry install
Expand Down Expand Up @@ -211,14 +221,17 @@ jobs:
# Write GCS service account credentials to a file
mkdir ~/.aws
# This fake cluster needs to be created first so that the integration tests pass in GH actions. Don't ask me why...
ccm create test_cluster -v binary:3.11.4 -n 1 --vnodes
ccm create test_cluster -v binary:${{ matrix.cassandra-version }} -n 1 --vnodes
ccm node1 updateconf 'storage_port: 7011'
ccm node1 updateconf 'concurrent_reads: 4'
ccm node1 updateconf 'concurrent_writes: 4'
ccm node1 updateconf 'concurrent_counter_writes: 4'
ccm node1 updateconf 'num_tokens: 4'
sed -i 's/#MAX_HEAP_SIZE="4G"/MAX_HEAP_SIZE="256m"/' ~/.ccm/test_cluster/node1/conf/cassandra-env.sh
sed -i 's/#HEAP_NEWSIZE="800M"/HEAP_NEWSIZE="200M"/' ~/.ccm/test_cluster/node1/conf/cassandra-env.sh
# remove the ThreadPriorityPolicy option for cases where we run with java 11
sed -i 's/-XX:ThreadPriorityPolicy=42//' ~/.ccm/test_cluster/node1/conf/jvm.options || true
sed -i 's/-XX:ThreadPriorityPolicy=42//' ~/.ccm/test_cluster/node1/conf/jvm8-server.options || true
ccm start -v
ccm showlastlog|tail -100
ccm stop
Expand Down Expand Up @@ -315,8 +328,14 @@ jobs:
with:
username: ${{ secrets.K8SSANDRA_DOCKER_HUB_USERNAME }}
password: ${{ secrets.K8SSANDRA_DOCKER_HUB_PASSWORD }}
- name: Set up Python 3.11
uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Set up Poetry
uses: snok/install-poetry@v1
with:
version: 1.8.5
- uses: actions/checkout@v3
with:
path: cassandra-medusa
Expand Down Expand Up @@ -386,7 +405,7 @@ jobs:
publish-docker-master:
needs: [debian-build, build, integration-tests, k8ssandra-e2e-tests]
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Set up QEMU
Expand All @@ -407,6 +426,8 @@ jobs:
echo "sha_short=$(git rev-parse --short=8 ${{ github.sha }})" >> $GITHUB_OUTPUT
- name: Set up Poetry
uses: snok/install-poetry@v1
with:
version: 1.8.5
- name: Build Medusa
run: |
echo "Publishing release $(git rev-parse --short HEAD) in Docker Hub"
Expand All @@ -429,26 +450,21 @@ jobs:
if: github.event_name == 'release' && github.event.action == 'published'
strategy:
matrix:
suite: [focal]
suite: [jammy]
include:
- suite: focal
os-version: ubuntu-20.04
- suite: jammy
os-version: ubuntu-22.04
fail-fast: false
runs-on: ${{ matrix.os-version }}
steps:
- uses: actions/checkout@v3
- name: Install dependencies
run: |
sudo curl -L "https://github.com/docker/compose/releases/download/1.25.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose
- name: Build Debian
run: |
version=$(cat VERSION)
echo "VERSION=$version" >> $GITHUB_ENV
cd packaging/docker-build
docker-compose build "cassandra-medusa-builder-${{ matrix.suite }}" \
&& docker-compose run "cassandra-medusa-builder-${{ matrix.suite }}"
docker compose build "cassandra-medusa-builder-${{ matrix.suite }}" \
&& docker compose run "cassandra-medusa-builder-${{ matrix.suite }}"
- name: Push Debian to Cloudsmith
id: push-deb
Expand All @@ -467,7 +483,7 @@ jobs:
publish-docker:
needs: [publish-debian]
if: github.event_name == 'release' && github.event.action == 'published'
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Set up QEMU
Expand All @@ -488,6 +504,8 @@ jobs:
echo "version=$(cat VERSION)" >> $GITHUB_OUTPUT
- name: Set up Poetry
uses: snok/install-poetry@v1
with:
version: 1.8.5
- name: Build Medusa
run: |
echo "Publishing release ${{ steps.vars.outputs.version}} in Docker Hub"
Expand All @@ -508,14 +526,16 @@ jobs:
# We can only release if the build above succeeded first
needs: [publish-docker]
if: github.event_name == 'release' && github.event.action == 'published'
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.8
- name: Set up Python 3.10
uses: actions/setup-python@v1
with:
python-version: 3.8
python-version: 3.10
- name: Set up Poetry
with:
version: 1.8.5
uses: snok/install-poetry@v1
- name: Install dependencies
run: |
Expand Down
19 changes: 19 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,24 @@
## Change Log

### 0.22.3 (2024/10/02 16:00 +00:00)
- Propagate Medusa process exit code in k8s docker-entrypoint (#806) (@c3-clement)

### 0.22.2 (2024/08/16 16:00 +00:00)
- Do not install docker-compose in release-debian CI step (#801) (@rzvoncek)

### 0.22.1 (2024/08/15 16:00 +00:00)
- Do not set storage class for GCP (it's not supported anyway) (#800) (@rzvoncek)
- Fix backup man future registration and BackupStatus computation of the node backup state (#799) (@adejanovski)

### 0.22.0 (2024/07/19 16:00 +00:00)
- Bump urllib3 from 1.26.18 to 1.26.19 (#784) (@dependabot)
- Ignore blank likes in host_list file (#761) (@VenkataNaladala94)
- Allow specifying storage classes (#777) (@maburadeh, @adejanovski, @rzvoncek)
- Bump azure-identity from 1.14.0 to 1.16.1 (#776) (@dependabot)
- Adding support to build images for multiple architectures (#760) (@EmanuelSanchez, @adejanovski)
- Make object store read timeout configurable (#763) (@rzvoncek)
- Fix a bug where 'None' got into the path prefix we actually list with (#770) (@rzvoncek)

### 0.21.0 (2024/05/06 16:55 +00:00)
- Prevent gRRPC's BackupStatus from canceling pending futures (#745) (@rzvoncek)
- Fix to enable the creation of backups when a backup name is not provided (#758) (@VenkataNaladala94)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,6 @@ You can find the Docker images for Cassandra Medusa at [https://hub.docker.com/r
Dependencies
------------

Medusa requires Python 3.8 or newer.
Medusa requires Python 3.9 or newer.

For information on the packaged dependencies of Medusa for Apache Cassandra&reg; and their licenses, check out our [open source report](https://app.fossa.com/reports/cac72e73-1214-4e6d-8476-76567e08db21).
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.22.0-dev
0.23.0-dev
2 changes: 1 addition & 1 deletion debian/cassandra-medusa.install
Original file line number Diff line number Diff line change
@@ -1 +1 @@
medusa-example.ini /etc/medusa
medusa-example.ini /etc/medusa
24 changes: 24 additions & 0 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,3 +1,27 @@
cassandra-medusa (0.22.3) stable; urgency=medium

* Release 0.22.3 of Medusa - Backups for Apache Cassandra.

-- The Last Pickle <[email protected]> Wed, 02 Oct 2024 10:41:48 +0000

cassandra-medusa (0.22.2) stable; urgency=medium

* Release 0.22.2 of Medusa - Backups for Apache Cassandra.

-- The Last Pickle <[email protected]> Fri, 16 Aug 2024 11:32:50 +0000

cassandra-medusa (0.22.1) stable; urgency=medium

* Release 0.22.1 of Medusa - Backups for Apache Cassandra.

-- The Last Pickle <[email protected]> Thu, 15 Aug 2024 12:47:58 +0000

cassandra-medusa (0.22.0) stable; urgency=medium

* Release 0.22.0 of Medusa - Backups for Apache Cassandra.

-- The Last Pickle <[email protected]> Fri, 19 Jul 2024 13:01:34 +0000

cassandra-medusa (0.21.0) stable; urgency=medium

* Release 0.21.0 of Medusa - Backups for Apache Cassandra.
Expand Down
4 changes: 2 additions & 2 deletions debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Section: python
Priority: extra
Maintainer: The Last Pickle <[email protected]>
Build-Depends:
debhelper (>= 9),
debhelper (>= 12),
dh-python,
python3-all,
python3-all-dev,
Expand All @@ -17,6 +17,6 @@ Standards-Version: 3.9.5
Package: cassandra-medusa
Architecture: any
Pre-Depends: dpkg (>= 1.16.1), python3, python3-venv, ${misc:Pre-Depends}
Depends: ${python:Depends}, ${shlibs:Depends}, ${misc:Depends}
Depends: ${python3:Depends}, ${shlibs:Depends}, ${misc:Depends}
Description: Backup tool for Cassandra databases
Make immutable backups for Cassandra databases and extract them to an external storage.
6 changes: 3 additions & 3 deletions debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ export DH_VIRTUALENV_INSTALL_ROOT = /usr/share

override_dh_virtualenv:
dh_virtualenv \
--python /usr/bin/python3 --preinstall=setuptools==40.3.0 --preinstall=pip==21.3.1 --preinstall=wheel --builtin-venv \
--preinstall=poetry==1.6.1 --preinstall=dh-poetry==0.2.0 --pip-tool=dh-poetry
--python /usr/bin/python3.10 --preinstall=setuptools==40.3.0 --preinstall=pip==21.3.1 --preinstall=wheel --builtin-venv \
--preinstall=poetry==1.8.5 --preinstall=dh-poetry==0.2.0 --pip-tool=dh-poetry

override_dh_strip:
dh_strip --no-automatic-dbgsym -X libssh2 -X libssh -X libgssapi_krb5 -X libcrypto -X libkrb5 -X libk5crypto
Expand All @@ -44,4 +44,4 @@ override_dh_gencontrol:

override_dh_auto_configure:
# overriding with a no-op to avoid dh to look for setup.py
true
true
Loading

0 comments on commit 6ef7921

Please sign in to comment.