Skip to content

RoadRunner plugins interfaces

License

Notifications You must be signed in to change notification settings

roadrunner-server/api-plugins

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

API Plugins

GoDoc Go Report Card License: MIT Discord

This repository defines Go interface contracts for RoadRunner server plugins. Plugins implement these interfaces so that the Endure dependency injection framework can automatically discover and wire dependencies via its plugin graph. Endure inspects each plugin's Init() method parameters, matches them to registered plugins that implement the required interfaces, and topologically sorts the resulting DAG to determine initialization order.

Packages

Package Description
jobs Job queue interfaces — Driver, Constructor, Pipeline, Message, Job, Queue, and State for async job processing
kv Key-value storage — Storage, Item, and Constructor interfaces with TTL support
lock Lock queue — Item and Queue interfaces for priority-based lock management
logger Logging — Log and Named interfaces wrapping go.uber.org/zap
priority_queue Base priority queue — Item interface with ID, GroupID, Priority
status Status reporting — Status struct with Code field

Usage

A plugin declares its dependencies by accepting interfaces in its Init() method. Endure auto-resolves them from the plugin graph:

type Plugin struct{}

func (p *Plugin) Init(log logger.Log, kv kv.Storage) error {
    log.Info("plugin initialized")
    return nil
}

License

This project is licensed under the MIT License — see the LICENSE file for details.

About

RoadRunner plugins interfaces

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages