Skip to content

Commit

Permalink
Fix Cassandra testing on SLES. (#1763)
Browse files Browse the repository at this point in the history
  • Loading branch information
igorpeshansky authored Jul 29, 2024
1 parent 1bca17d commit e9bcbd0
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 50 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,31 +25,13 @@ logging:
type: cassandra_debug
cassandra_gc:
type: cassandra_gc
cassandra_sles_system:
type: cassandra_system
include_paths:
# This path is specific to SLES integration tests manual install
- /home/test_user/apache-cassandra/logs/system*.log
cassandra_sles_debug:
type: cassandra_debug
include_paths:
# This path is specific to SLES integration tests manual install
- /home/test_user/apache-cassandra/logs/debug*.log
cassandra_sles_gc:
type: cassandra_gc
include_paths:
# This path is specific to SLES integration tests manual install
- /home/test_user/apache-cassandra/logs/gc.log.*.current
service:
pipelines:
cassandra:
receivers:
- cassandra_system
- cassandra_debug
- cassandra_gc
- cassandra_sles_system
- cassandra_sles_debug
- cassandra_sles_gc
EOF

sudo service google-cloud-ops-agent restart
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,35 +21,11 @@ features:
module: logging
key: "[0].enabled"
value: true
- feature: receivers:cassandra_debug
module: logging
key: "[2].enabled"
value: true
- feature: receivers:cassandra_debug
module: logging
key: "[2].include_paths.__length"
value: 1
- feature: receivers:cassandra_gc
module: logging
key: "[1].enabled"
value: true
- feature: receivers:cassandra_gc
module: logging
key: "[3].enabled"
value: true
- feature: receivers:cassandra_gc
module: logging
key: "[3].include_paths.__length"
value: 1
- feature: receivers:cassandra_system
module: logging
key: "[4].enabled"
value: true
- feature: receivers:cassandra_system
module: logging
key: "[4].include_paths.__length"
value: 1
- feature: receivers:cassandra_system
module: logging
key: "[5].enabled"
key: "[2].enabled"
value: true
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,6 @@ minimum_supported_agent_version:
supported_operating_systems: linux
# TODO: Fix errors and enable tests on all platforms.
platforms_to_skip:
- suse-cloud:sles-12 # QueryLog() failed: cassandra_system not found, exhausted retries; QueryLog() failed: cassandra_debug not found, exhausted retries; QueryLog() failed: cassandra_gc not found, exhausted retries
- suse-cloud:sles-15 # QueryLog() failed: cassandra_system not found, exhausted retries; QueryLog() failed: cassandra_debug not found, exhausted retries; QueryLog() failed: cassandra_gc not found, exhausted retries
- suse-cloud:sles-15-arm64
- debian-cloud:debian-12 # QueryLog() failed: cassandra_system not found, exhausted retries; QueryLog() failed: cassandra_debug not found, exhausted retries; QueryLog() failed: cassandra_gc not found, exhausted retries
- debian-cloud:debian-12-arm64 # QueryLog() failed: cassandra_system not found, exhausted retries; QueryLog() failed: cassandra_debug not found, exhausted retries; QueryLog() failed: cassandra_gc not found, exhausted retries
- ubuntu-os-cloud:ubuntu-2004-lts # GPG error [...] the public key is not available: NO_PUBKEY AA8E81B4331F7F50 NO_PUBKEY 112695A0E562B32A
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ fi
sudo zypper -n refresh

# SLES 15 SP5 has moved Java 8 to a legacy module
if [[ "${SUSE_VERSION}" == 15 ]]; then
sudo SUSEConnect --product sle-module-legacy/15.5/$(uname -m)
if [[ "${ID}" == sles && "${SUSE_VERSION}" == 15 ]]; then
sudo SUSEConnect --product "sle-module-legacy/${VERSION_ID}/$(uname -m)"
fi

sudo zypper -n install java-1_8_0-openjdk java-1_8_0-openjdk-devel
Expand All @@ -26,5 +26,8 @@ curl -OL https://storage.googleapis.com/ops-agents-public-buckets-vendored-deps/
tar xzvf apache-cassandra-4.1.3-bin.tar.gz
mv apache-cassandra-4.1.3 apache-cassandra

apache-cassandra/bin/cassandra -f &
ps -f -p $!
# The default location for cassandra logs is /var/log/cassandra.
sudo mkdir -m 755 -p /var/log/cassandra
sudo chown $USER /var/log/cassandra
CASSANDRA_LOG_DIR=/var/log/cassandra apache-cassandra/bin/cassandra -R -p cassandra.pid
ps -f -p $(cat cassandra.pid)

0 comments on commit e9bcbd0

Please sign in to comment.