codex

module
v0.10.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 2, 2019 License: Apache-2.0

README

codex

Codex provides a historical context about devices connected to XMiDT.

Build Status codecov.io Code Climate Issue Count Go Report Card Apache V2 License GitHub release

Summary

Codex accepts incoming events, stores them in a postgres database, and provides event information by device id. This repo is a library of packages used to implement codex.

The Pieces

  • Database: Any postgres database will work. In deploy/, cockroachdb is used.
  • Svalinn: Registers to an endpoint to receive events (Optional). Has an endpoint that receives events as WRP Messages, parses them, and inserts them into the database.
  • Gungnir: Has endpoints that provide device information from the database.
  • Fenrir: Deletes old records from the database at an interval.

Install

This repo is a library of packages used for the codex project. There is no installation. To install each service, go to their respective READMEs.

Deploy

for deploying the project in Docker, refer to the deploy README.

Contributing

Refer to CONTRIBUTING.md.

Directories

Path Synopsis
cipher package is a helper package for encrypting and decrypting messages
cipher package is a helper package for encrypting and decrypting messages
db
package db provides some overarching variables, structs, and interfaces that different database implementations can use and implement and consumers can expect.
package db provides some overarching variables, structs, and interfaces that different database implementations can use and implement and consumers can expect.
batchDeleter
package batchDeleter provides a wrapper around the db.Pruner to provide a way to get expired records at a given interval and delete them at a separate given interval.
package batchDeleter provides a wrapper around the db.Pruner to provide a way to get expired records at a given interval and delete them at a separate given interval.
batchInserter
package batchInserter provides a wrapper around the db.Inserter to provide a way to group records together before inserting, in order to decrease database requests needed for inserting.
package batchInserter provides a wrapper around the db.Inserter to provide a way to group records together before inserting, in order to decrease database requests needed for inserting.
postgresql
package postgresql provides a way to connect to a postgresql database to keep track of device events.
package postgresql provides a way to connect to a postgresql database to keep track of device events.
retry
package dbretry contains structs that implement various db interfaces as well as consume them.
package dbretry contains structs that implement various db interfaces as well as consume them.
tests

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL