Skip to content

Instantly share code, notes, and snippets.

VERSION=rc3
AWS_BASE=s3://downloads.scylladb.com/downloads/scylla/relocatable/scylladb-4.0/
for f in `aws s3 ls ${AWS_BASE} | awk '{print $4}' | grep "${VERSION}" | grep 'scylla-tools\|scylla-package\|scylla-jmx'` ;
do
aws s3 cp ${AWS_BASE}${f} .
if [[ $f == *"scylla-package"* ]]; then
export SCYLLA_CORE_PACKAGE=./$f
fi
if [[ $f == *"scylla-tools"* ]]; then
diff --git a/alternator_tests.py b/alternator_tests.py
index c6353142..95be2417 100644
--- a/alternator_tests.py
+++ b/alternator_tests.py
@@ -1,5 +1,7 @@
import os
from pprint import pformat
+import tempfile
+import shutil
import requests
import pandas as pd
res = requests.get("https://data.gov.il/api/action/datastore_search?resource_id=9eedd26c-019b-433a-b28b-efcc98de378d")
data = res.json()
df = pd.DataFrame(data['result']['records'])
df['date'] = pd.to_datetime(df['date'], infer_datetime_format=True)
df.plot(figsize=(10,5), x ='date', y='isolated_today_contact_with_confirmed', kind='line')
import numpy as np
import pandas as pd
import csv
input = ""
for l in open('/home/fruch/Downloads/data_short.csv').readlines():
input += l.replace('"', '') + '\n'
with open('/home/fruch/Downloads/data_short_clean.csv', 'w') as f:
f.write(input)
import time
from subprocess import run
import boto3
from cassandra import ConsistencyLevel
from cassandra.query import SimpleStatement
from dtest import Tester, debug
from scylla_tools import insert_c1c2
import jenkins
import sys
server = jenkins.Jenkins('https://jenkins.scylladb.com', username='[your user]', password='[your token]')
user = server.get_whoami()
version = server.get_version()
print('Hello %s from Jenkins %s' % (user['fullName'], version))
LATEST_MASTER_JOB_ID=`aws s3 ls downloads.scylladb.com/relocatable/unstable/master/ | grep '2020-' | tr -s ' ' | cut -d ' ' -f 3 | tr -d '\/' | sort -g | tail -n 1`
BASE_VERSION=http://downloads.scylladb.com.s3.amazonaws.com/relocatable/unstable/master/${LATEST_MASTER_JOB_ID}
AWS_BASE=s3://downloads.scylladb.com/relocatable/unstable/master/${LATEST_MASTER_JOB_ID}
aws s3 cp ${AWS_BASE}/scylla-package.tar.gz .
aws s3 cp ${AWS_BASE}/scylla-tools-package.tar.gz .
aws s3 cp ${AWS_BASE}/scylla-jmx-package.tar.gz .
ccm create scylla-reloc-1-local-temp -n 1 --scylla --version unstable/master:$LATEST_MASTER_JOB_ID \
--scylla-core-package-uri=./scylla-package.tar.gz \
import sys
import time
import functools
import timeit
import logging
directions = [
(0, -1), # north
(0, 1), # south
(1, 0), # east
@fruch
fruch / Read.md
Last active January 19, 2017 20:38
Testing websequesnce

alt text