rsyslog-module
Provides standards and boilerplate for developing rsyslog plugins while ensuring concurrency and state safety.
Install
mkdir -p .claude/skills/rsyslog-module && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/5905" && unzip -o skill.zip -d .claude/skills/rsyslog-module && rm skill.zipInstalls to .claude/skills/rsyslog-module
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Encodes technical requirements for rsyslog modules, including concurrency, metadata, and initialization.Key capabilities
- →Enforces concurrency and locking patterns
- →Initializes module lifecycle entry points
- →Verifies metadata consistency
- →Applies state management rules
How it works
It injects standard C boilerplates and enforces concurrency checks by applying lifecycle macro definitions and mutex requirements.
Inputs & outputs
When to use rsyslog-module
- →Authoring new rsyslog output modules
- →Implementing mutex protection for shared state
- →Synchronizing module metadata with rsyslog build systems
- →Defining module lifecycle entry points
About this skill
rsyslog_module
This skill captures the essential technical patterns for authoring and maintaining rsyslog modules (plugins/contrib).
Quick Start
- Locking: Follow the "Belt and Suspenders" rule (
assert()+if). - State:
pData(shared) vsWID(per-worker). - Boilerplate: Use
BEGINmodInit,CODESTARTmodInit, etc.- Resource: See Common Snippets for boilerplate code.
Detailed Instructions
1. Concurrency & Locking
Rsyslog v8 has a high-concurrency worker model.
- Shared State (
pData): Mutable state shared across workers MUST be protected by a mutex inpData. - Per-Worker State (
WID): Never sharewrkrInstanceData_t. - Belt and Suspenders:
assert(pData != NULL); if (pData == NULL) { // Handle error gracefully } - Headers: Every output module should have a "Concurrency & Locking" header block.
2. Module Lifecycle
Every module must implement and register standard entry points:
modInit(): Initialize static data and registry interfaces.modExit(): Finalize and cleanup.beginTransaction()/commitTransaction(): For efficient batch-based output.
3. Metadata Consistency
- Location:
MODULE_METADATA.yamlin the module directory. - Synchronization: Keep
doc/ai/module_map.yamlin sync with locking and concurrency changes.
4. Build Configuration
- Update
plugins/Makefile.amandconfigure.acwhen adding new modules. - Test Registration: Follow the "Define at Top, Distribute Unconditionally, Register Conditionally" pattern in
tests/Makefile.am. See thersyslog_testskill for details. This is critical formake distcheckvalidity. - Use
MODULE_TYPE(eMOD_OUT)and other macros fromruntime/module-template.h.
Related Skills
rsyslog_build: For compiling the module.rsyslog_test: For creating module-specific smoke tests.rsyslog_doc: For documentation requirements.
When not to use it
- →High-level application logic development
- →Non-C rsyslog module projects
Prerequisites
Limitations
- →Specific to C-based rsyslog modules
- →Requires manual state definition
How it compares
It mandates architectural constraints (e.g., locking) specific to the rsyslog runtime worker model.
Compared to similar skills
rsyslog-module side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| rsyslog-module (this skill) | 1 | 6mo | No flags | Advanced |
| unity-developer | 142 | 4mo | No flags | Advanced |
| code-coverage-with-gcov | 15 | 4mo | Review | Intermediate |
| unity-mcp-orchestrator | 17 | 4mo | No flags | Intermediate |
Try saying
Example prompts that trigger this skill in your AI assistant.
More by rsyslog
View all by rsyslog →You might also like
unity-developer
sickn33
Build Unity games with optimized C# scripts, efficient rendering, and proper asset management. Masters Unity 6 LTS, URP/HDRP pipelines, and cross-platform deployment. Handles gameplay systems, UI implementation, and platform optimization. Use PROACTIVELY for Unity performance issues, game mechanics, or cross-platform builds.
code-coverage-with-gcov
gadievron
Add gcov code coverage instrumentation to C/C++ projects
unity-mcp-orchestrator
CoplayDev
Orchestrate Unity Editor via MCP (Model Context Protocol) tools and resources. Use when working with Unity projects through MCP for Unity - creating/modifying GameObjects, editing scripts, managing scenes, running tests, or any Unity Editor automation. Provides best practices, tool schemas, and workflow patterns for effective Unity-MCP integration.
arm-cortex-expert
sickn33
Senior embedded software engineer specializing in firmware and driver development for ARM Cortex-M microcontrollers (Teensy, STM32, nRF52, SAMD). Decades of experience writing reliable, optimized, and maintainable embedded code with deep expertise in memory barriers, DMA/cache coherency, interrupt-driven I/O, and peripheral drivers.
at-dispatch-v2
pytorch
Convert PyTorch AT_DISPATCH macros to AT_DISPATCH_V2 format in ATen C++ code. Use when porting AT_DISPATCH_ALL_TYPES_AND*, AT_DISPATCH_FLOATING_TYPES*, or other dispatch macros to the new v2 API. For ATen kernel files, CUDA kernels, and native operator implementations.
static-analysis
gmh5225
Expertise in LLVM-based static analysis including dataflow analysis, pointer analysis, taint tracking, and program verification. Use this skill when implementing security scanners, bug finders, code quality tools, or performing program analysis research.