Skip to content

The core micro services of UrbanOS as an umbrella project with component documentation

License

Notifications You must be signed in to change notification settings

UrbanOS-Public/smartcitiesdata

Repository files navigation

Smart Cities Data Platform

Project Description

The platform is a combination of Elixir micro services custom built to ingest, normalize, transform, persist, and stream data from numerous sources, orchestrated via Kubernetes in any cloud provider or on-prem Kubernetes deployment. The loosely coupled services pass data across the pipeline via Kafka message queues and persist data to any hyper-scalable object store providing the S3 standard. They coordinate and communicate via a single event bus, also running on top of Kafka. The distributed data files are persisted and retrieved via SQL queries processed by the PrestoDB engine. Finally, user access, discovery, and analysis is facilitated by a ReactJS web application user interface, a RESTful API, or a web socket API for streaming data feeds.

scdp architecture diagram

Microservices

Application Short Description Build Status
Andi Admin Interface for creating/editing datasets to be ingested
Discovery API API to search for and query datasets
Discovery Streams Websocket connection to listen to streaming data
Estuary Microservice to persist event stream events
Forklift Microservice for saving data to Presto DB
Reaper Microservice to retrieve data
Valkyrie Microservice to validate data structure during ingestion
Alchemist Microservice to alter data from its original format

Prerequisites

General Prerequisites

  • Elixir - The primary language that all of the microservices are written in
  • Docker - All microservices are built as docker images
  • Apache Kafka - Communication mechanism between microservices
  • Redis - General purpose storage and caching
  • Elasticsearch - Used by Discovery API for search
  • PostgreSQL - General purpoase storage
  • Presto - Big Data storage of ingested data
  • Vault - Secure storage of secrets

Development Enviornment Setup

Setup guide available on our wiki

Usage

The microservices written in Elixir use Mix as the build tool.

Building

Each microservice under the apps/ directory has a Dockerfile that can be used to build that microservice individually by running the following command:

docker build .

Additional app specific build steps will be in the relative readme at apps/{app}/readme.md.

Testing

  • Unit tests can be executed from the root of this repository or a specific application under the apps/ directory
mix test
  • Integration tests can be executed from the root of this repository or a specific application under the apps/ directory
mix test.integration
  • End to End (E2E) Tests can be executed from the root of this repository.
mix test.e2e

Execution

How to run and use the code

Additional Notes

Version History and Retention

Each microservice is released independently and can be found here in the Releases section. All releases will be kept indefinitely.

Versioning conforms to the standard versioning pattern of .., for example 3.0.1. 3 being major, 0 being minor, and 1 being patch.

Patch version increments should introduce no breaking changes to the existing public chart. Docker images/Elixir apps are able to be updated in-place with no changes needed. Minor version increments may require chart changes to function properly. These changes should be reviewed and charts should be adjusted accordingly before updating. Major version increments likely introduce wide-spread or structural changes that require many configuration changes.

License

Released under Apache 2 license.

Contributions

How to contribute

Contact Information

Acknowledgements