A Golang SDK for creating plugins for Synse Server
Synse Server provides an HTTP API for monitoring and controlling physical and virtual devices; Synse Plugins provide the backend support for all the devices Synse Server exposes. This repo contains the official Synse Plugin SDK (written in Go) which can be used to create plugin backends for Synse Server.
The SDK handles most of the common functionality needed for plugins, such as configuration parsing, background read/write, transaction generation and tracking, meta-info caching, and more. This means the plugin author should only need to worry about the plugin-specific device support. See the SDK Documentation for more info.
The Synse SDK is one component of the greater Synse Ecosystem.
-
vapor-ware/synse-server: An HTTP server providing a uniform API to interact with physical and virtual devices via plugin backends. This can be thought of as a 'front end' for Synse Plugins.
-
vapor-ware/synse-server-grpc: The internal gRPC API that connects Synse Server and the Synse Plugins.
-
vapor-ware/synse-emulator-plugin: A simple plugin with no hardware dependencies that can serve as a plugin backend for Synse Server for development, testing, and just getting familiar with how Synse Server works or how plugins can be written.
-
vapor-ware/synse-cli: A CLI that allows you to easily interact with Synse Server (via HTTP) and Plugins (via gRPC) directly from the command line.
The Synse SDK can be installed with modules enabled
go get github.com/vapor-ware/synse-sdk/v2
It is recommended that you use a release version of the SDK. You can pin to use the top-of-trunk version by:
go get -u github.com/vapor-ware/synse-sdk/v2@master
Similarly versions can also be declared by import:
import "github.com/vapor-ware/synse-sdk/v2/sdk"
From there, it is easy to start building your own plugin. The SDK Documentation provides useful information on writing plugins. You can also check out the examples directory, which contains various example plugins built using the SDK. The examples, in conjunction with the documentation, should get you well on your way to start writing your own plugin(s).
If you wish to develop the SDK, see the "Developer Guide" section in the SDK Documentation.