package kinetic-client

All checked builds pass
  1. Overview
  2. Docs
Client API for Seagate's Kinetic drives

Install

dune-project
 Dependency

Authors

Maintainers

Sources

0.0.11.tar.gz
md5=acc775dbd08f7cdbdd7955f2a284b2f0
sha512=d7374b38a9cfee05b6b820c72d88a2626fb9af6ab972a4596aaa2cdc708042b4003b1c5f525121791bfe9140c65b49c9f3a5e8e50f70d432f0e979cfd8a7d5a4

Description

Added to opam-repository:

README

Kinetic OCaml Client

This is an OCaml client for Seagate's Kinetic drives. Currently, it uses protocol version 4.0.0.

Installation

In order to build the client, you need to have some OCaml libraries present. In concreto, you need:

  • lwt
  • lwt_ssl
  • lwt_log
  • cryptokit
  • ocaml-protoc
  • cmdliner (for tests)
  • dune

If you have these, you can compile everything with:

$> make

You can install the library with:

$> make install

Once you have the library installed, you just add `true:package(kinetic-client) to your ocamlbuild _tags file.

Usage

The API is defined in kinetic.mli

typically you'd do something like:

    ...
    Kinetic.wrap_socket socket
    >>=? fun client ->
    Kinetic.put client
      "the_key" (Some "the value")
      ~db_version:None ~new_version:None
      ~forced:true
      ~synchronization:(Some Kinetic.WRITEBACK)
    >>=? fun () ->
    ...

take a look at test_it.ml

Remarks

Protocol?

There is a rather stable protocol defined in Seagate's kinetic-protocol which defines the serialization for valid messages. The protocol itself is rather implicitly defined by the Kinetic drive, and the interpretation of what comprises an acceptable client/server conversation varies between different firmware releases. All this to say that even if both client and server state they support protocol version X, they still might not be able to talk to each other. YMMV

Todo

  • We only catered for our own needs, so feature support is rather limited. (we welcome pull requests ;) )
  • the API feels heavy, because it's a direct translation of the messages into RPC. Once the protocol stabilizes, we should move into something more elegant.

Have fun,

The OpenVStorage team

Dependencies (8)

  1. ppx_deriving
  2. cryptokit
  3. lwt_ssl
  4. lwt_log
  5. lwt >= "3.2.0"
  6. ocaml-protoc >= "1.2.0" & < "3.0.0"
  7. dune >= "1.1.0"
  8. ocaml >= "4.04"

Dev Dependencies (1)

  1. cmdliner with-test & < "2.0.0"

Optional Dependencies

None

Used by

None

Conflicts

None

Build status

Results of building kinetic-client with each compiler on check.ci.ocaml.org, run of against opam-repository 7cdc698. All results for this package.

Each result links to its build log. To keep crawlers from overloading the site, build logs require a GitHub sign-in (see ocurrent/opam-health-check). On your first log, GitHub asks you to “Authorize opam-health-check”, the OCurrent app that runs these checks; it sees only your public profile, not your repositories. The sign-in lasts 30 days.

Version OCaml 4.11 OCaml 4.14 OCaml 5.2 OCaml 5.4 OCaml 5.5
0.0.11 (this version) good good good good good
  • good Package successfully built
  • partial One of the dependencies failed to build
  • bad Package failed to build
  • n/a Package is not available in this environment
  • internal Internal failure