@dcos/mesos-client

--- šŸ‘©ā€šŸ”¬ Please be aware that this package is still experimental ā€” changes to the interface and underlying implementation are likely, and future development or maintenance is not guaranteed.

Stats

StarsIssuesVersionUpdatedCreatedSize
@dcos/mesos-client
5211.0.03 years ago4 years agoMinified + gzip package size for @dcos/mesos-client in KB

Readme

Apache Mesos Client Build Status


šŸ‘©ā€šŸ”¬ Please be aware that this package is still experimental ā€” changes to the interface and underlying implementation are likely, and future development or maintenance is not guaranteed.


This package provides a nice way of connecting to the Mesos Event Stream API. It is a wrapper that uses @dcos/http-service to establish a connection and @dcos/recordio package to parse the incoming data and deliver it as a Rx.Observable.

Example

import { stream, request } from "@dcos/mesos-client";

stream({ type: "SUBSCRIBE" }).subscribe(
  value => console.log(value),
  error => console.log(error),
  () => console.log("complete")
);

request({ type: "GET_FLAGS" }).subscribe(
  value => console.log(value),
  error => console.log(error),
  () => console.log("complete")
);

stream opens a persistent connection to Mesos HTTP Operator Api Event Stream and returns rxjs Observable.

request makes a call to the Mesos HTTP Operator Api and returns response as an rxjs Observable.

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.