oasis-amqp-macros

Crates.iooasis-amqp-macros
lib.rsoasis-amqp-macros
version0.2.0
sourcesrc
created_at2020-03-09 11:52:30.385232
updated_at2021-06-17 18:55:22.501283
descriptionHelper macros for AMQP 1.0 type definitions
homepage
repositoryhttps://github.com/djc/corda-rpc
max_upload_size
id216850
size13,267
Dirkjan Ochtman (djc)

documentation

https://docs.rs/oasis-amqp-derive

README

corda-rpc: Rust libraries for doing Corda RPC

Build status Coverage status License: Apache 2.0

Because I no longer work at ING or on any Corda-related projects, this crate is unlikely to see further development unless funding appears -- I am available on a freelance basis. I'm happy to answer questions about the code and its current state, and I intend to provide (passive) maintenance (like PR code reviews) of this code going forward.

Corda is an open source blockchain platform. To work with a Corda node, your code needs to communicate over AMQP 1.0 with the broker run by the node. This project targets stable Rust and uses asynchronous network I/O built on Tokio. This might be useful for code running in constrained environments (IoT) or interfacing with other native code.

This project was written within ING Bank, while working on the ValueX project to create a digital securities distribution platform for institutional investors. The provided functionality is separated into three crates, as explained below.

The current state of the project can be described as pre-alpha. So far I have worked to get a simple RPC call to the Corda node to work, and everything provided is only complete insofar as needed for that purpose. The example code in network-map-snapshot will trigger an RPC call on the Corda node as desired and return the proper response. However, this only works against a Corda node which has some changes applied to it.

corda-rpc: abstractions specific to Corda RPC

Documentation Crates.io

While the Corda RPC protocol builds on top of the AMQP 1.0 standard, it defines its own encoding schema serialization to protocol to make protocol messages self-describing. This crate contains implementations of the required serialization and deserialization primitives, and will contain other code specific to Corda going forward. The ideal end goal would be an implementation matching Corda's CordaRPCOps interface.

oasis-amqp: generic implementation of the AMQP 1.0 protocol

Documentation Crates.io

The name "AMQP" is often used to refer to version 0.9.1 of the protocol, as implemented by RabbitMQ and many other software components. Despite the shared name, AMQP 1.0 as standardized by OASIS deviates substantially from the 0.9.1 protocol. This crate aims to provide a generally usable (not specific to Corda) implementation of a protocol client.

As mentioned above, the library currently falls short of that goal. While it provides a robust version of the parts of the protocol that are strictly needed to start exchanging messages with a broker, many parts are missing or incomplete. Nevertheless, the building blocks provided (in particular, the serialization and deserialization based on Rust's powerful serde framework) should in many cases make it straightforward to fill in the missing bits.

oasis-amqp-macros: helper macro(s)

Documentation Crates.io

The implementation of the oasis-amqp crate is supported by a single procedural macro which derives required implementations of serde::Deserialize and oasis_amqp::Described for any type definitions.

Commit count: 187

cargo fmt