#automation #redis #automaat #command #processor #execute #url

automaat-processor-redis-command

Redis Command processor for the Automaat automation utility

1 unstable release

0.1.0 Jun 10, 2019

#9 in #automaat


Used in automaat-server

MIT/Apache

22KB
258 lines

Automaat Processor: Redis Command

🚧 Work In Progress 🚧


lib.rs:

An Automaat processor to execute Redis commands.

Execute Redis commands in an Automaat-based workflow. The return value of the Redis command is returned as the output of the processor.

Examples

Execute the Redis PING command, with the "hello world" argument, and receive the response back as the output of the run.

See the official documentation on PING.

use automaat_core::{Context, Processor};
use automaat_processor_redis_command::RedisCommand;
use url::Url;

let context = Context::new()?;
let redis_url = Url::parse("redis://127.0.0.1")?;

let processor = RedisCommand {
    command: "PING".to_owned(),
    arguments: Some(vec!["hello world".to_owned()]),
    url: redis_url
};

let output = processor.run(&context)?;

assert_eq!(output, Some("hello world".to_owned()));

Package Features

  • juniper – creates a set of objects to be used in GraphQL-based requests/responses.

Dependencies

~7–18MB
~281K SLoC