Blyx Nest Blyx language
Registry / Library
library · v0.1.0

StatusRetry

Check a conservative retry policy for selected gRPC status codes.

Source repository · Package JSON

Use StatusRetry

use vendor::statusretry::statusretry;

Run the example

nest demo statusretry@0.1.0
blyxc native-run statusretry-demo/main.blyx
Example source and expected output
use vendor::statusretry::statusretry;

fn main() {
    let status = 14.0;
    let idempotent = 1.0;
    let attempts = 1.0;
    let max_attempts = 3.0;
    let result = statusretry_classify(status, idempotent, attempts, max_attempts);
    if len(result) == 0 { println!("invalid"); return; }
    let mut i = 0;
    while i < len(result) {
        println!(at(result, i));
        i += 1;
    }
}

Expected output

1
2

Published versions

VersionPackageSource commitSHA-256
0.1.0Download ZIP3236a4811ffd4744c4ca9dc0929b16c45d9c64ae6be362c6b566dcf5233f609d8d0f828ffb