---
icon: octicons/package-24
---

Modules package configuration, JavaScript and resource files to form reusable building blocks
for compiling and running 10x [apps](https://doc.log10x.com/apps).

This approach is similar to other software runtimes (e.g., JVM, Node.js) which support packaging
code and config files into reusable libraries.

### :material-cogs: Compile 

The [Compile](https://doc.log10x.com/compile/) pipeline uses extensible modules to generate [symbol libraries](https://doc.log10x.com/compile/link/#symbol-library) from an array of text and binary formats:

[:material-code-tags: ANTLR](https://doc.log10x.com/compile/scanner/antlr/) parses source code from 50+ programming languages.

[:material-code-json: Jackson](https://doc.log10x.com/compile/scanner/text/) parses text/binary files in a wide array of configuration and serialization formats.

[:material-launch: Executable](https://doc.log10x.com/compile/scanner/executable/) import symbols from external sources such as OS commands (e.g., `strings`) and custom scripts (e.g., `.py`).

To learn more see the [Compile API](https://doc.log10x.com/api/compile/).

### :material-play-outline: Run

The [Run](https://doc.log10x.com/run/) pipeline uses extensible modules to process typed [TenXObjects](https://doc.log10x.com/api/js/#TenXObject) to a variety of sources:

[:material-set-merge: Input](https://doc.log10x.com/run/input/) modules read log/trace events from log forwarders, analyzers and object storage.

[:material-pipe-valve: Receiver](https://doc.log10x.com/run/output/receive/) modules filter 'noisy' telemetry using local/central policies.

[:material-set-split: Output](https://doc.log10x.com/run/output/#output-modules) modules write TenXObjects and aggregated summaries to event and metric destinations.

To learn more see the [Input](https://doc.log10x.com/api/input/) and [Output](https://doc.log10x.com/api/output/) API.

### :material-file-tree: Files

Modules comprise the following file types:

| Type                                                                                                     | Description                                                                           | Format            | Example                                                                                                                                                                                                                                                               |
|----------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------|-------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [:octicons-package-16: Module](https://doc.log10x.com/config/module/)                                     | Defines the options a module can receive via config files and cli arguments           | .yaml             | [elastic/module.yaml](https://github.com/log-10x/config/blob/main/pipelines/run/modules/input/analyzer/elasticsearch/module.yaml)                                                                                                                                      |
| [:simple-yaml: Config](https://doc.log10x.com/config/yaml/)                                               | Config files specifying arguments defined by anf other this modules                   | .yaml             | [executable/strings.yaml](https://github.com/log-10x/config/blob/main/pipelines/compile/modules/scanner/executable/config/strings.yaml), [elastic/stream.yaml](https://github.com/log-10x/config/blob/main/pipelines/run/modules/input/analyzer/elasticsearch/stream.yaml) |
| [:material-language-javascript: JavaScript](https://doc.log10x.com/run/transform/script/)                 | Control aspects of the module's behavior at run time                                  | .js               |  [rate-object-global.js](https://github.com/log-10x/config/blob/main/pipelines/run/modules/receive/rate/rate-object-global.js)                                                                                                                                                              |
| [:material-table-eye: Lookup](https://doc.log10x.com/api/js/#tenxlookup)                                   | Lookup tables for enriching TenXObjects                                                | .tsv, .csv, .mmdb | [lookup/http.csv](https://github.com/log-10x/config/blob/main/sample/lookup/http.csv)                                                                                                                                                                                  |
| [:camel: Camel Route](https://doc.log10x.com/run/input/analyzer/#extensibility)[^1]                       | Apache Camel route definitions and classes to connect to remote data sources          | .yaml, .jar       | [elastic/route.yaml](https://github.com/log-10x/config/blob/main/pipelines/run/modules/input/analyzer/elasticsearch/route.yaml)                                                                                                                                        |
| [:material-math-log: Log4j2 Appender](https://doc.log10x.com/run/output/event/)[^1]              | Log4j2.yaml and appender classes for writing TenXObjects to local/remote destinations           | .yaml, .jar       | [forward/log4j2.yaml](https://github.com/log-10x/config/blob/main/pipelines/run/modules/output/event/forward/log4j2.yaml)                                                                                                                                     |
| [:material-chart-multiple: MicroMeter Registry](https://doc.log10x.com/run/output/metric/#extensions)[^1] | Config and registry classes for publishing TenXSummaries to metric outputs             | .yaml, .jar.      | [datadog/stream.yaml](https://github.com/log-10x/config/blob/main/pipelines/run/modules/output/metric/datadog/stream.yaml)                                                                                                                                             |

[^1]: * Code extensions (.jar) are only supported in the [Compiler](https://doc.log10x.com/engine/flavors/#compiler) flavor.

## :material-wrench-cog-outline: Configuration

The 10x Engine loads module files from [local](https://doc.log10x.com/config/folder/), [GitHub](https://doc.log10x.com/config/github/) or [Kubernetes ConfigMap](https://doc.log10x.com/config/k8s/) folders (the ConfigMap path reloads on change, without a sidecar or pod restart). 

GitHub provides a centralized mechanism for publishing, managing and accessing module files. 

Modules can specify a default YAML [config](https://doc.log10x.com/config/yaml/)
file to provide example values for any of the options defined by the module.

For example, the [elastic/config.yaml](https://github.com/log-10x/config/blob/main/pipelines/run/config/input/analyzer/elastic/config.yaml)
config loads the [Elastic](https://doc.log10x.com/run/input/analyzer/elasticsearch/) input module and outlines its option values to specify.

``` yaml

# 🔟❎ 'run' ElasticSearch input configuration

# This configuration defines an ElasticSearch input from
# which events are read and transformed into TenXObjects for aggregation and reporting.

# Set the 10x pipeline to 'run'
tenx: run

# =============================== Dependencies ================================

include: modules/input/analyzer/elasticsearch

# =============================== Elastic Options ==============================

# Multiple Elastic inputs can be defined below:
elastic:

  - name: myElastic

....

```


