Merge branch 'main' into update-solana-1-16-anchor-28
This commit is contained in:
commit
c4c13a3e0d
|
@ -1,63 +0,0 @@
|
||||||
on:
|
|
||||||
push:
|
|
||||||
tags:
|
|
||||||
- 'v*'
|
|
||||||
pull_request:
|
|
||||||
paths:
|
|
||||||
- '.github/workflows/release.yml'
|
|
||||||
|
|
||||||
env:
|
|
||||||
CARGO_TERM_COLOR: always
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
release:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
|
|
||||||
- name: Set rust version
|
|
||||||
run: |
|
|
||||||
source ci/rust-version.sh
|
|
||||||
echo "RUST_STABLE=$rust_stable" | tee -a $GITHUB_ENV
|
|
||||||
|
|
||||||
- name: Set env vars
|
|
||||||
run: |
|
|
||||||
source ci/env.sh
|
|
||||||
echo "GEYSER_PLUGIN_NAME=$plugin_name" | tee -a $GITHUB_ENV
|
|
||||||
echo "GEYSER_PLUGIN_LIB=lib${plugin_lib_name}" | tee -a $GITHUB_ENV
|
|
||||||
|
|
||||||
- if: runner.os == 'Linux'
|
|
||||||
run: |
|
|
||||||
sudo apt-get update
|
|
||||||
sudo apt-get install -y libudev-dev libssl-dev libsasl2-dev libzstd-dev
|
|
||||||
|
|
||||||
- uses: actions-rs/toolchain@v1
|
|
||||||
with:
|
|
||||||
toolchain: ${{ env.RUST_STABLE }}
|
|
||||||
override: true
|
|
||||||
profile: minimal
|
|
||||||
components: rustfmt
|
|
||||||
|
|
||||||
- name: Check Solana version
|
|
||||||
run: |
|
|
||||||
echo "CI_TAG=${GITHUB_REF#refs/*/}" >> "$GITHUB_ENV"
|
|
||||||
echo "CI_OS_NAME=linux" >> "$GITHUB_ENV"
|
|
||||||
|
|
||||||
SOLANA_VERSION="$(./ci/solana-version.sh)"
|
|
||||||
SOLANA_VERSION="v${SOLANA_VERSION#=}"
|
|
||||||
echo "SOLANA_VERSION=$SOLANA_VERSION" >> "$GITHUB_ENV"
|
|
||||||
|
|
||||||
- name: Build release tarball
|
|
||||||
run: ./ci/create-tarball.sh
|
|
||||||
|
|
||||||
- name: Release
|
|
||||||
uses: softprops/action-gh-release@v1
|
|
||||||
if: startsWith(github.ref, 'refs/tags/')
|
|
||||||
with:
|
|
||||||
body: |
|
|
||||||
${{ env.GEYSER_PLUGIN_NAME }} ${{ env.CI_TAG }}
|
|
||||||
solana ${{ env.SOLANA_VERSION }}
|
|
||||||
rust ${{ env.RUST_STABLE }}
|
|
||||||
files: |
|
|
||||||
${{ env.GEYSER_PLUGIN_NAME }}-release-*
|
|
||||||
|
|
|
@ -3,8 +3,6 @@
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
env:
|
env:
|
||||||
|
@ -14,7 +12,7 @@ jobs:
|
||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Set rust version
|
- name: Set rust version
|
||||||
run: |
|
run: |
|
||||||
|
@ -32,31 +30,32 @@ jobs:
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install -y libudev-dev libssl-dev libsasl2-dev libzstd-dev
|
sudo apt-get install -y libudev-dev libssl-dev libsasl2-dev libzstd-dev
|
||||||
|
|
||||||
- uses: actions-rs/toolchain@v1
|
# The toolchain action should definitely be run before the cache action
|
||||||
|
- uses: actions-rust-lang/setup-rust-toolchain@v1
|
||||||
with:
|
with:
|
||||||
toolchain: ${{ env.RUST_STABLE }}
|
toolchain: ${{ env.RUST_STABLE }}
|
||||||
override: true
|
|
||||||
profile: minimal
|
|
||||||
components: rustfmt, clippy
|
components: rustfmt, clippy
|
||||||
|
# fresh install is faster than using the cache (11 secs vs 1 minute)
|
||||||
|
cache: false
|
||||||
|
# avoid the default "-D warnings" which thrashes cache
|
||||||
|
rustflags: ""
|
||||||
|
|
||||||
- uses: actions/cache@v2
|
# https://github.com/actions/cache/blob/main/examples.md#rust---cargo
|
||||||
|
- uses: actions/cache@v3
|
||||||
with:
|
with:
|
||||||
path: |
|
path: |
|
||||||
~/.cargo/registry
|
~/.cargo/bin/
|
||||||
~/.cargo/git
|
~/.cargo/registry/index/
|
||||||
key: cargo-build-${{ hashFiles('**/Cargo.lock') }}-${{ env.RUST_STABLE}}
|
~/.cargo/registry/cache/
|
||||||
|
~/.cargo/git/db/
|
||||||
|
target/
|
||||||
|
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
||||||
|
|
||||||
- name: cargo fmt
|
- name: Run fmt+clippy
|
||||||
uses: actions-rs/cargo@v1
|
run: |
|
||||||
with:
|
cargo fmt --all --check
|
||||||
command: fmt
|
cargo clippy --workspace --all-targets
|
||||||
args: --all -- --check
|
|
||||||
|
|
||||||
- name: cargo clippy
|
|
||||||
uses: actions-rs/cargo@v1
|
|
||||||
with:
|
|
||||||
command: clippy
|
|
||||||
args: --workspace --all-targets #-- --deny=warnings
|
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: ./ci/cargo-build-test.sh
|
run: |
|
||||||
|
cargo build --all-targets
|
||||||
|
|
34
Cargo.toml
34
Cargo.toml
|
@ -8,18 +8,27 @@ members = [
|
||||||
jsonrpc-core-client = { git = "https://github.com/ckamm/jsonrpc.git", branch = "ckamm/http-with-gzip-default-v18.0.0" }
|
jsonrpc-core-client = { git = "https://github.com/ckamm/jsonrpc.git", branch = "ckamm/http-with-gzip-default-v18.0.0" }
|
||||||
|
|
||||||
[workspace.dependencies]
|
[workspace.dependencies]
|
||||||
solana-rpc = "~1.16.7"
|
solana-rpc = "~1.14.9"
|
||||||
solana-client = "~1.16.7"
|
solana-client = "~1.14.9"
|
||||||
solana-account-decoder = "~1.16.7"
|
solana-account-decoder = "~1.14.9"
|
||||||
solana-sdk = "~1.16.7"
|
solana-sdk = "~1.14.9"
|
||||||
solana-logger = "~1.16.7"
|
solana-logger = "~1.14.9"
|
||||||
|
|
||||||
yellowstone-grpc-client = "1.9.0"
|
anchor-spl = "0.27.0"
|
||||||
yellowstone-grpc-proto = "1.9.0"
|
anchor-lang = "0.27.0"
|
||||||
|
anchor-client = "0.27.0"
|
||||||
|
|
||||||
|
mango-v4 = { tag = "program-v0.16.0", git = "https://github.com/blockworks-foundation/mango-v4.git"}
|
||||||
|
mango-v4-client = { tag = "program-v0.16.0", git = "https://github.com/blockworks-foundation/mango-v4.git" }
|
||||||
|
|
||||||
|
serum_dex = { git = "https://github.com/jup-ag/openbook-program", branch = "feat/expose-things", features = ["no-entrypoint"] }
|
||||||
|
# this works in solana-rpc-client-simple; solves anchor 0.28.0 issue
|
||||||
|
#serum_dex = { git = "https://github.com/openbook-dex/program.git", tag = "v0.5.10", default-features=false, features = ["no-entrypoint", "program"] }
|
||||||
|
|
||||||
jsonrpc-core = "18.0.0"
|
jsonrpc-core = "18.0.0"
|
||||||
jsonrpc-core-client = { version = "18.0.0", features = ["ws", "http"] }
|
jsonrpc-core-client = { version = "18.0.0", features = ["ws", "http"] }
|
||||||
|
|
||||||
|
fixed = { tag = "program-v0.16.0", git = "https://github.com/blockworks-foundation/mango-v4.git" }
|
||||||
bs58 = "0.5"
|
bs58 = "0.5"
|
||||||
base64 = "0.21.0"
|
base64 = "0.21.0"
|
||||||
log = "0.4"
|
log = "0.4"
|
||||||
|
@ -42,13 +51,16 @@ async-trait = "0.1"
|
||||||
bytemuck = "1.7.2"
|
bytemuck = "1.7.2"
|
||||||
jemallocator = "0.3.2"
|
jemallocator = "0.3.2"
|
||||||
chrono = "0.4.23"
|
chrono = "0.4.23"
|
||||||
clap = { version = "3.1.8", features = ["derive", "env"] }
|
|
||||||
|
|
||||||
tokio = { version = "1", features = ["full"] }
|
tokio = { version = "1", features = ["full"] }
|
||||||
tokio-tungstenite = "0.17"
|
tokio-tungstenite = "0.17"
|
||||||
|
tokio-postgres = { version = "0.7", features = ["with-chrono-0_4"] }
|
||||||
|
tokio-postgres-rustls = "0.9.0"
|
||||||
|
postgres-types = { version = "0.2", features = ["array-impls", "derive", "with-chrono-0_4"] }
|
||||||
|
postgres-native-tls = "0.5"
|
||||||
|
native-tls = "0.2"
|
||||||
rustls = "0.20.8"
|
rustls = "0.20.8"
|
||||||
|
# postgres_query hasn't updated its crate in a while
|
||||||
warp = "0.3"
|
postgres_query = { git = "https://github.com/nolanderc/rust-postgres-query", rev = "b4422051c8a31fbba4a35f88004c1cefb1878dd5" }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -12,30 +12,29 @@ description = "Listen to Solana account updates via geyser or websockets"
|
||||||
default = []
|
default = []
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
jsonrpc-core = { workspace = true }
|
jsonrpc-core = "18.0.0"
|
||||||
jsonrpc-core-client = { workspace = true }
|
jsonrpc-core-client = { version = "18.0.0", features = ["ws", "http"] }
|
||||||
|
|
||||||
solana-rpc = { workspace = true }
|
solana-rpc = "1.14.9"
|
||||||
solana-client = { workspace = true }
|
solana-client = "1.14.9"
|
||||||
solana-account-decoder = { workspace = true }
|
solana-account-decoder = "1.14.9"
|
||||||
solana-sdk = { workspace = true }
|
solana-sdk = "1.14.9"
|
||||||
solana-logger = { workspace = true }
|
|
||||||
|
|
||||||
tokio = { workspace = true }
|
tokio = { version = "1", features = ["full"] }
|
||||||
rustls = { workspace = true }
|
rustls = "0.20.8"
|
||||||
|
|
||||||
serde = { workspace = true }
|
serde = "1.0.130"
|
||||||
serde_derive = { workspace = true }
|
serde_derive = "1.0.130"
|
||||||
|
|
||||||
log = { workspace = true }
|
log = "0.4"
|
||||||
anyhow = { workspace = true }
|
anyhow = "1.0"
|
||||||
|
|
||||||
itertools = { workspace = true }
|
itertools = { workspace = true }
|
||||||
|
|
||||||
futures = { workspace = true }
|
futures = "0.3.17"
|
||||||
|
|
||||||
async-channel = { workspace = true }
|
async-channel = "1.6"
|
||||||
async-trait = { workspace = true }
|
async-trait = "0.1"
|
||||||
|
|
||||||
warp = { workspace = true }
|
warp = { workspace = true }
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
pub mod account_write_filter;
|
pub mod account_write_filter;
|
||||||
pub mod chain_data;
|
pub mod chain_data;
|
||||||
pub mod grpc_plugin_source;
|
pub mod grpc_plugin_source;
|
||||||
pub mod memory_target;
|
|
||||||
pub mod metrics;
|
pub mod metrics;
|
||||||
pub mod snapshot;
|
pub mod snapshot;
|
||||||
pub mod websocket_source;
|
pub mod websocket_source;
|
||||||
|
|
|
@ -5,7 +5,6 @@ use solana_client::{
|
||||||
rpc_config::{RpcAccountInfoConfig, RpcProgramAccountsConfig},
|
rpc_config::{RpcAccountInfoConfig, RpcProgramAccountsConfig},
|
||||||
rpc_response::{OptionalContext, RpcKeyedAccount},
|
rpc_response::{OptionalContext, RpcKeyedAccount},
|
||||||
};
|
};
|
||||||
|
|
||||||
use solana_rpc::rpc::rpc_accounts::AccountsDataClient;
|
use solana_rpc::rpc::rpc_accounts::AccountsDataClient;
|
||||||
use solana_sdk::{commitment_config::CommitmentConfig, slot_history::Slot};
|
use solana_sdk::{commitment_config::CommitmentConfig, slot_history::Slot};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue