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

Make the elastic sink a linked transport. #715

Merged
merged 7 commits into from
Jan 28, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion .github/checks/safety.sh
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ while getopts hauiprebldxcft opt; do
do
if sed -e '/mod test.*/,$d' -e '/ALLOW: /{N;d;}' "$file" | grep 'expect(' > /dev/null
then
echo "##[error] expect found in $file try hygenic errors, this panics!"
echo "##[error] expect found in $file try hygienic errors, this panics!"
count=$((count + 1))
fi
done
Expand Down
13 changes: 9 additions & 4 deletions .github/workflows/integration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ jobs:
- ubuntu-latest
#- windows-latest
- macOS-latest
include:
- os: "macOS-latest"
exclude_tests: "--excludes docker"
- os: "ubuntu-latest"
exclude_tests: ""
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v1
Expand All @@ -27,13 +32,13 @@ jobs:
- name: Build test runner
run: cargo build -p tremor-cli
- name: Run Integration Tests
run: TREMOR_PATH="$GITHUB_WORKSPACE/tremor-script/lib" cargo run -p tremor-cli -- test integration tremor-cli/tests
run: TREMOR_PATH="$GITHUB_WORKSPACE/tremor-script/lib" cargo run -p tremor-cli -- test integration tremor-cli/tests ${{ matrix.exclude_tests }}
- name: Run API Tests
run: TREMOR_PATH="$GITHUB_WORKSPACE/tremor-script/lib" cargo run -p tremor-cli -- test api tremor-cli/tests
run: TREMOR_PATH="$GITHUB_WORKSPACE/tremor-script/lib" cargo run -p tremor-cli -- test api tremor-cli/tests ${{ matrix.exclude_tests }}
- name: Run Unit Tests
run: TREMOR_PATH="$GITHUB_WORKSPACE/tremor-script/lib" cargo run -p tremor-cli -- test unit tremor-cli/tests
run: TREMOR_PATH="$GITHUB_WORKSPACE/tremor-script/lib" cargo run -p tremor-cli -- test unit tremor-cli/tests ${{ matrix.exclude_tests }}
- name: Run Command Tests
run: TREMOR_PATH="$GITHUB_WORKSPACE/tremor-script/lib" cargo run -p tremor-cli -- test command tremor-cli/tests
run: TREMOR_PATH="$GITHUB_WORKSPACE/tremor-script/lib" cargo run -p tremor-cli -- test command tremor-cli/tests ${{ matrix.exclude_tests }}
- name: Upload error logs
uses: actions/upload-artifact@v2
if: failure()
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
* Update rust to 1.49.0
* Build deb packages
* Statically link openssl
* elastic sink now supports linked transports [#715](https://github.com/tremor-rs/tremor-runtime/pull/715)

## 0.9.4

Expand Down
7 changes: 5 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ grok = "1"

# not used directly in tremor codebase, but present here so that we can turn
# on features for these (see static-ssl feature here)
openssl = { version = "0.10", features = ["vendored"] }
openssl = {version = "0.10", features = ["vendored"]}

# rest onramp
tide = "0.15"
Expand All @@ -119,8 +119,11 @@ regex = "1"
[features]
default = []

# arm suopport
# support for 128bit numbers in tremor-value
128bit = ["tremor-value/128bit"]
bert = ["tremor-pipeline/bert"]

# arm support
neon = ["simd-json/neon"]

[patch.crates-io]
Expand Down
10 changes: 7 additions & 3 deletions src/codec/json.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,13 @@ impl Codec for JSON {
let new_len = max(self.string_buffer.capacity(), data.len()) * 2;
self.string_buffer.reserve(new_len);
}
tremor_value::to_value_with_buffers(data, &mut self.input_buffer, &mut self.string_buffer)
.map(Some)
.map_err(|e| e.into())
tremor_value::parse_to_value_with_buffers(
data,
&mut self.input_buffer,
&mut self.string_buffer,
)
.map(Some)
.map_err(|e| e.into())
}
fn encode(&self, data: &Value) -> Result<Vec<u8>> {
let mut v = Vec::with_capacity(1024);
Expand Down
Loading