Giter Club home page Giter Club logo

parallel's Introduction

protobuf schemas

Modeling magnetic events as protobuf schemas.

Each event is composed of two parts - data and meta-data. The data is the minimal viable information that this event contains for its consumers. For example, a pixel event may have advertiser id and either a revenue value for a conversion event or a product id for a product event. The meta data contains the event id itself, the time it was produced, its source and the actor (event generator). This is shown in the diagram below :

Events Format: Alt Text

The two parts are making the event global message, simply called event.proto

The meta-data contains the the source and the actor messages defined in corresponding proto files. The actor defines the generaor of the message whereas the source the method it was delivered (such as HTTP) and the machine it took place on. The data events correspond to the service that generated them such as pixels / impressions / clicks .

Note : the schemas are defined using proto3 syntax.

python - compile protos

First you need to install protobuf with protoc and make sure that protobuf is installed. Make sure that all are version 3.x When writing this, the google protobuf version version 3.0.0a4 did not link some of the extra google messages. Therefoe, two of the ones that are used (Any and Timestamp) are copied manually into google_messages directory.

When calling the protoc compiler, you will need to provide the path to the source files, and the path to the output files. For example, assuming that you are on the protobuf directory of this project, and you would like your output files to be in , the command will look like : protoc --python_out=<dest> --proto_path=protobuf protobuf/messages/event.proto

parallel's People

Watchers

James Cloos avatar Offer Sharabi avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.