Paranoia

module
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2025 License: BSD-2-Clause

README

Paranoia framework - golang microservice engine

pipeline status coverage report Go Reference

Use GO helper library

GUI Helper project tool

Getting Started

To install in the project, use the command

go get gitlab.com/devpro_studio/Paranoia

A minimal application includes the initialization of the framework:

s := paranoia.New("minimal paranoia app", "cfg.yaml")

The first parameter is the application name, the second is the configuration system, and the third is the logging system. In this example, stub objects are used as the configuration and logging systems.

Next, the framework is populated with modules that will be used in this service, for example, add an in-memory cache at the application level:

s.PushPkg(memory.New("secondary"))

In all engine modules, the module name and its type are used, the name must be unique within the type, and it can be used later in the code to get this module. More details about available modules and possible settings are described later in the documentation.

Next, you need to initialize the framework and start it:

err := s.Init()

if (err != nil) {
    panic(err)
    return
}

defer s.Stop()

The minimal application is ready.

Documentation

Supported:

Database
  • Postgres
  • SQLite
  • MySQL
  • Clickhouse
  • MongoDB
  • Aerospike
  • Elasticsearch
Cache
  • Memory
  • Redis
  • Memcached
  • etcd
Servers
  • http
  • Kafka
  • RabbitMQ
  • GRPC
Server middlewares
  • Restore from panic
  • Register timing middleware (default use)
  • Timeout request
  • Authorize (JWT)
  • CORS
Clients
  • http
  • Kafka
  • RabbitMQ
  • GRPC
Storage
  • File
  • S3
Other
  • Initialize base engine module from yaml config file
  • Regulatory task system
  • Sentry log
  • JWT native support (module and middleware)
  • Concurrency patterns in template

Generating RSA keys for JWT:

openssl genrsa -out private.key 2048

openssl rsa -in private.key -pubout -out public.key

Jump to

Keyboard shortcuts

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