Fluvio - secret sauce for scalability #463
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
By @AlexMikhalev, replaces #461
Getting Started - warm up and machine to machine communications
Code quality "Hello World", for discussion and not merge - large change and it's combined "Hello World" for Fluvio Rust library and examples/basic.rs
First modify basic example to emit new article on successful save:
record()
Second add consume_record, where we are:
Start with
cargo run --example async_std_consumer --all-features -- produce_record
fluvio consume atomic-data -B
cargo run --example async_std_consumer --all-features -- consume_record
That closes Machine 2 Machine communication discussion: #425 . Obviously we can now extend commit hook to produce record into fluvio topic in the same way as you added tantivy indexing.
Now cool stuff
We have: JSON_AD importer
#390
Atomizer
#434
Wasm plugins
#73
discussions and roadmap items. As it happens Fluvio supports HTTP (and other) connectors, which allow us to run Smartmodule (WASM plugins) on "the edge" - before data arrives into fluvio topic.
So we can build a highly scalable Atomizer with an option to pre-process data "on-fetch" and "on-save". If it sounds like dream come true, this is because it is ;-)
Lets start by building fetcher for JSON-AD from reference-architecture.ai
Follow:
https://www.fluvio.io/smartmodules/transform/array-map/
I created
array-map-ref-arch-ad
don't use underscores in name of connector or topic - fluvio doesn't like it in many places.cd array-map-ref-arch-ad cargo build --release fluvio smart-module list (should be empty) fluvio smart-module create array-map-ref-arch-ad --wasm-file ./target/wasm32-unknown-unknown/release/array_map_ref_arch_ad.wasm fluvio smart-module list NAME STATUS SIZE array-map-ref-arch-ad SmartModuleStatus 156905
Now start http connector locally:
Http connector can be deployed into Infinyon cloud or run locally, since I use minikube it can't fetch externally so it fails. #FIXME
Connector parameters can be specified reference_architecture.yml and registered on cloud with
fluvio connector create --config=./reference_architecture.yml