Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Node/dev aarzola musl test #217

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
35b93db
added support for `musl` dependency
ofirsnb Apr 10, 2024
0941f8b
Node: added `musl` compiling action
ofirsnb Apr 10, 2024
233eb4a
Musl test
alex-arzola-imp Apr 12, 2024
ce492b3
Java: Add `lindex` command. (List Command Group) (#1219)
SanHalacogluImproving Apr 10, 2024
8745f85
Clean up all warnings in Java client test (#1213)
acarbonetto Apr 10, 2024
e817fb6
Java: Refactor transaction UT (#1242)
Yury-Fridlyand Apr 10, 2024
100deb7
Java: Add `Zmscore` command. (Sorted Set Command Group) (#1234)
SanHalacogluImproving Apr 10, 2024
1fd9f43
Java/Node: Update docs for `xadd` and `xtrim` (#1246)
acarbonetto Apr 10, 2024
e2bda3d
Java: misc fixes (#1256)
Yury-Fridlyand Apr 10, 2024
9939f19
Java: Add `LINSERT` command. (#1236)
Yury-Fridlyand Apr 10, 2024
2031202
Java: Modularize wrapper (#1237)
jonathanl-bq Apr 11, 2024
ddb714a
Java: Fix transaction handling for cluster client. (#1229)
Yury-Fridlyand Apr 11, 2024
9e0c1c4
Java: Add `SETRANGE` command. (#1235)
Yury-Fridlyand Apr 11, 2024
f386a16
Java: Add `Zdiff` command. (Sorted Set Commands) (#1243)
SanHalacogluImproving Apr 11, 2024
43e7da6
Java: Add `Zdiffstore` command. (Sorted Set Group) (#1244)
SanHalacogluImproving Apr 11, 2024
51561c3
Python: add RPUSHX and LPUSHX commands (#1239)
aaron-congo Apr 11, 2024
652f0d1
Java: Add `Zcount` command. (Sorted Set Group) (#1245)
SanHalacogluImproving Apr 11, 2024
03b9217
Java: Add `Zremrangebyrank` command. (Sorted Set Group) (#189) (#1263)
SanHalacogluImproving Apr 11, 2024
91dcad9
Java: Add `Zremrangebylex` command. (Sorted Set Group) (#195) (#1264)
SanHalacogluImproving Apr 12, 2024
36a78ea
Java: Fix protoc version check. (#1272)
Yury-Fridlyand Apr 12, 2024
fba1fdf
C#: Strict rules (#1136)
Sa1Gur Apr 12, 2024
d294ece
Adding shell change
alex-arzola-imp Apr 12, 2024
c823521
Adding hardcoded shell change
alex-arzola-imp Apr 12, 2024
fd0f1f6
Reverted to bash
alex-arzola-imp Apr 12, 2024
fda1a7f
Trying sh shell as parameter
alex-arzola-imp Apr 12, 2024
a0368b8
Trying bash shell as parameter
alex-arzola-imp Apr 12, 2024
1906d32
Trying bash shell as parameter on the right job
alex-arzola-imp Apr 12, 2024
06e7c29
Adding bash and text tools
alex-arzola-imp Apr 12, 2024
0a6ec1a
Adding bash and text tools
alex-arzola-imp Apr 12, 2024
39068b3
Hard coding os and architecture
alex-arzola-imp Apr 12, 2024
5aa12f5
Testing architectures
alex-arzola-imp Apr 12, 2024
b67622e
Testing file names
alex-arzola-imp Apr 12, 2024
5360319
Setting original target architecture
alex-arzola-imp Apr 15, 2024
9e6c926
Added stable linux x64 dependency to napi
alex-arzola-imp Apr 15, 2024
1e203a7
Reverted name to sable linux musl target
alex-arzola-imp Apr 15, 2024
c78313c
Reverted architecture to arm64
alex-arzola-imp Apr 15, 2024
edfe411
Added the stable-x86_64-unknown-linux-musl to rust
alex-arzola-imp Apr 15, 2024
0ff7f50
Revieweing architecture
alex-arzola-imp Apr 15, 2024
ec1762a
checking full OS info
alex-arzola-imp Apr 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/build-node-wrapper/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,15 @@ inputs:
- amazon-linux
- macos-latest
- ubuntu-latest
- ubuntu-latest-musl
named_os:
description: "The name of the current operating system"
required: false
default: "linux"
type: string
options:
- linux
- linux-musl
- darwin
arch:
description: "The current architecture"
Expand Down Expand Up @@ -65,6 +67,7 @@ runs:
named_os: ${{ inputs.named_os }}
arch: ${{ inputs.arch }}
npm_scope: ${{ inputs.npm_scope }}
shell_os: ${{ inputs.shell_os }}

- name: npm install
shell: bash
Expand All @@ -78,7 +81,10 @@ runs:
shell: bash
working-directory: ./node
run: |
echo "---BEFORE BUILDING RUST---"
uname -a
source "$HOME/.cargo/env"
rustup target add stable-x86_64-unknown-linux-musl
TARGET_FLAG=`if [ "${{ inputs.target }}" != '' ]; then echo "--target ${{ inputs.target }}"; fi`
BUILD_FLAG=`if [ "${{ inputs.publish }}" == 'true' ]; then echo "build:release"; else echo "build"; fi`
npm run $BUILD_FLAG --build-flags="$TARGET_FLAG"
2 changes: 1 addition & 1 deletion .github/workflows/csharp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ concurrency:

jobs:
run-tests:
timeout-minutes: 15
timeout-minutes: 25
strategy:
fail-fast: false
matrix:
Expand Down
16 changes: 15 additions & 1 deletion .github/workflows/install-shared-dependencies/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ inputs:
- amazon-linux
- macos-latest
- ubuntu-latest
- ubuntu-latest-musl
target:
description: "Specified target for rust toolchain, ex. x86_64-apple-darwin"
type: string
Expand All @@ -17,6 +18,7 @@ inputs:
options:
- x86_64-unknown-linux-gnu
- aarch64-unknown-linux-gnu
- aarch64-unknown-linux-musl
- x86_64-apple-darwin
- aarch64-apple-darwin
github-token:
Expand All @@ -35,7 +37,7 @@ runs:
brew upgrade || true
brew install git gcc pkgconfig openssl redis coreutils

- name: Install software dependencies for Ubuntu
- name: Install software dependencies for Ubuntu GNU
shell: bash
if: "${{ inputs.os == 'ubuntu-latest' }}"
run: |
Expand All @@ -48,12 +50,24 @@ runs:
run: |
yum install -y gcc pkgconfig openssl openssl-devel which curl redis6 gettext --allowerasing

- name: Install software dependencies for Ubuntu MUSL
shell: sh
if: "${{ inputs.os == 'ubuntu-latest-musl' }}"
run: |
apk update
wget -O - https://sh.rustup.rs | sh -s -- -y
source "$HOME/.cargo/env"
apk add protobuf-dev musl-dev make gcc


- name: Install Rust toolchain
if: "${{ inputs.os != 'ubuntu-latest-musl' }}"
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ inputs.target }}

- name: Install protoc (protobuf)
if: "${{ inputs.os != 'ubuntu-latest-musl' }}"
uses: arduino/setup-protoc@v3
with:
version: "25.1"
Expand Down
12 changes: 12 additions & 0 deletions .github/workflows/java.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,12 @@ jobs:
target: ${{ matrix.os == 'ubuntu-latest' && 'x86_64-unknown-linux-gnu' || 'x86_64-apple-darwin' }}
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Install protoc (protobuf)
uses: arduino/setup-protoc@v3
with:
version: "26.1"
repo-token: ${{ secrets.GITHUB_TOKEN }}

- name: Install redis
# TODO: make this step macos compatible: https://github.com/aws/glide-for-redis/issues/781
if: ${{ matrix.os == 'ubuntu-latest' }}
Expand Down Expand Up @@ -131,6 +137,12 @@ jobs:
target: "x86_64-unknown-linux-gnu"
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Install protoc (protobuf)
uses: arduino/setup-protoc@v3
with:
version: "26.1"
repo-token: ${{ secrets.GITHUB_TOKEN }}

- name: Create a symbolic Link for redis6 binaries
run: |
ln -s /usr/bin/redis6-server /usr/bin/redis-server
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/node-create-package-file/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,15 @@ inputs:
- amazon-linux
- macos-latest
- ubuntu-latest
- ubuntu-latest-musl
named_os:
description: "The name of the current operating system"
required: false
default: "linux"
type: string
options:
- linux
- linux-musl
- darwin
arch:
description: "The current architecture"
Expand All @@ -35,6 +37,7 @@ inputs:
type: string
default: "@aws"


runs:
using: "composite"
steps:
Expand Down
52 changes: 47 additions & 5 deletions .github/workflows/node.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ jobs:
- name: Install Redis Modules
uses: ./.github/workflows/install-redis-modules
with:
redis-version: ${{ matrix.redis }}
redis-version: ${{ matrix.redis }}

- name: test
run: npm test
Expand All @@ -73,17 +73,17 @@ jobs:
- name: test hybrid node modules - commonjs
run: |
npm install --package-lock-only
npm ci
npm ci
npm run build-and-test
working-directory: ./node/hybrid-node-tests/commonjs-test

- name: test hybrid node modules - ecma
run: |
npm install --package-lock-only
npm ci
npm run build-and-test
working-directory: ./node/hybrid-node-tests/ecmascript-test

- name: test redis modules
run: npm run test-modules -- --load-module=$GITHUB_WORKSPACE/redisjson.so
working-directory: ./node
Expand Down Expand Up @@ -147,7 +147,7 @@ jobs:
yum -y remove git
yum -y remove git-*
yum -y install https://packages.endpointdev.com/rhel/7/os/x86_64/endpoint-repo.x86_64.rpm
yum install -y git
yum install -y git
git --version

- uses: actions/checkout@v4
Expand Down Expand Up @@ -177,3 +177,45 @@ jobs:
- name: Test compatibility
run: npm test -- -t "set and get flow works"
working-directory: ./node


build-linux-musl-latest:
runs-on: ubuntu-latest
container:
image: node:18.19.0-alpine
timeout-minutes: 15
steps:
- name: Install bash
run: |
apk add bash
apk add gettext

- name: Install git
run: apk add git

- uses: actions/checkout@v4

- name: Checkout submodules
run: |
git config --global --add safe.directory "$GITHUB_WORKSPACE"
git submodule update --init --recursive

- name: Build Node wrapper
uses: ./.github/workflows/build-node-wrapper
with:
os: "ubuntu-latest-musl"
target: "stable-x86_64-unknown-linux-musl"
# target: "aarch64-unknown-linux-musl"
github-token: ${{ secrets.GITHUB_TOKEN }}
arch: "x64"
named_os: "linux"

- name: Create a symbolic Link for redis6 binaries
working-directory: ./node
run: |
ln -s /usr/bin/redis6-server /usr/bin/redis-server
ln -s /usr/bin/redis6-cli /usr/bin/redis-cli

- name: Test compatibility
run: npm test -- -t "set and get flow works"
working-directory: ./node
15 changes: 13 additions & 2 deletions .github/workflows/npm-cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ jobs:
if: github.repository_owner == 'aws'
name: Publish packages to NPM
runs-on: ${{ matrix.build.RUNNER }}
container:
image: ${{ matrix.build.IMAGE }}
strategy:
fail-fast: false
matrix:
Expand All @@ -54,6 +56,14 @@ jobs:
TARGET: aarch64-unknown-linux-gnu,
CONTAINER: "2_28",
}
- {
OS: ubuntu-latest-musl,
NAMED_OS: linux-musl,
RUNNER: ubuntu-latest,
ARCH: arm64,
TARGET: aarch64-unknown-linux-musl,
IMAGE: "node:18.19.0-alpine",
}
- {
OS: macos-latest,
NAMED_OS: darwin,
Expand Down Expand Up @@ -85,6 +95,7 @@ jobs:
echo "RELEASE_VERSION=${version}" >> $GITHUB_ENV

- name: Setup node
if: "${{ matrix.build.OS != 'ubuntu-latest-musl' }}"
uses: actions/setup-node@v3
with:
node-version: "16"
Expand All @@ -93,13 +104,13 @@ jobs:
scope: "${{ vars.NPM_SCOPE }}"
always-auth: true
token: ${{ secrets.NPM_AUTH_TOKEN }}

- name: Update package version in config.toml
uses: ./.github/workflows/update-glide-version
with:
folder_path: "${{ github.workspace }}/node/rust-client/.cargo"
named_os: ${{ matrix.build.NAMED_OS }}

- name: Build Node wrapper
uses: ./.github/workflows/build-node-wrapper
with:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/update-glide-version/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ inputs:
type: string
options:
- linux
- linux-musl
- darwin
runs:
using: "composite"
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
* Python: Added JSON.DEL JSON.FORGET commands ([#1146](https://github.com/aws/glide-for-redis/pull/1146))
* Python: Added STRLEN command ([#1230](https://github.com/aws/glide-for-redis/pull/1230))
* Python: Added HKEYS command ([#1228](https://github.com/aws/glide-for-redis/pull/1228))
* Python: Added RPUSHX and LPUSHX commands ([#1239](https://github.com/aws/glide-for-redis/pull/1239))
* Python: Added ZREMRANGEBYSCORE command ([#1151](https://github.com/aws/glide-for-redis/pull/1151))
* Node: Added SPOP, SPOPCOUNT commands. ([#1117](https://github.com/aws/glide-for-redis/pull/1117))
* Node: Added ZRANGE command ([#1115](https://github.com/aws/glide-for-redis/pull/1115))
Expand Down
Loading
Loading