Skip to content

Yet another logs server, that keeps logs in binary-packed format.

License

Notifications You must be signed in to change notification settings

bartossh/scribe

Repository files navigation

Scribe

Rust

Yet another logs server, that keeps logs in binary-packed format.

Why

  1. To store logs packed in binary format for fast writes.
  2. To save disc space.
  3. To save on indexing large dictionaries.

Service options

Scribe at this point can be run in three different repository versions:

  1. Permanent MongoDB. Pass mongodb connection string in url_db in default.yaml file.
  2. Permanent SQLite. Pass sqlite connection string (path to file) in url_db in default.yaml file.
  3. Ephemeral SQLite stored in RAM. Leave url_db in default.yaml file empty.

Development

Developed with rustc 1.77.2 and cargo 1.77.2.

Unit Tests

cargo test --profile test -- --nocapture --test-threads=1

Integration tests

Remember to run the server with default settings:

cargo run --release
cargo test --profile test --test integration_tests -v -- --nocapture --ignored --test-threads=1

Run dependencies

Project uses MongoDB as a data repository.

The your_user_name default is scribe. The your_password default is scribe.

  1. To run dockerized database for development:
MONGO_DB_USER=your_user_name MONGO_DB_PASSWORD=your_password docker compose -f dependencies/docker-compose.development.yaml up -d

You can vew database in the browser app at http://localhost:8081/.

  1. To run dockerized database for staging or/and prod:
MONGO_DB_USER=your_user_name MONGO_DB_PASSWORD=your_password docker compose -f dependencies/docker-compose.yaml up -d

Database is then not exposed to the outside word via browser app at localhost.

Run server

  1. Default on addr: 0.0.0.0:8000
cargo run --release 
  1. With setup.yaml file path as the argument. The file contains the setup parameters. Look in to default.yaml for a reference.
cargo run --release setup.yaml

About

Yet another logs server, that keeps logs in binary-packed format.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages