PHPackages                             michallkanak/symfony-open-system-monitor - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Logging &amp; Monitoring](/categories/logging)
4. /
5. michallkanak/symfony-open-system-monitor

ActiveSymfony-bundle[Logging &amp; Monitoring](/categories/logging)

michallkanak/symfony-open-system-monitor
========================================

Flexible monitoring bundle for Symfony applications with multi-channel notifications

0.1.0(1mo ago)20proprietaryPHPPHP ^8.2CI passing

Since Apr 14Pushed 1mo agoCompare

[ Source](https://github.com/michallkanak/symfony-open-system-monitor)[ Packagist](https://packagist.org/packages/michallkanak/symfony-open-system-monitor)[ RSS](/packages/michallkanak-symfony-open-system-monitor/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (1)Dependencies (23)Versions (2)Used By (0)

Symfony Open System Monitor
===========================

[](#symfony-open-system-monitor)

[![Tests](https://github.com/michallkanak/symfony-open-system-monitor/actions/workflows/tests.yml/badge.svg)](https://github.com/michallkanak/symfony-open-system-monitor/actions/workflows/tests.yml)[![PHPStan](https://camo.githubusercontent.com/d117944b58da8146f96b4ef7403807610a20eeb3fbcaaaf95157bbcdad1686eb/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048505374616e2d6c6576656c253230382d627269676874677265656e2e737667)](https://phpstan.org/)[![Code Style](https://camo.githubusercontent.com/5a98380c0a85158f60cd6883d1378aa12f15e3e232ed808a610f275de029096b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f636f64652532307374796c652d5048502d2d43532d2d46697865722d6f72616e67652e737667)](https://cs.symfony.com/)[![Packagist Version](https://camo.githubusercontent.com/18e970954e859f3c908889fac875d9d205db28c22158217872c2b33f8fbd7754/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d696368616c6c6b616e616b2f73796d666f6e792d6f70656e2d73797374656d2d6d6f6e69746f722e737667)](https://packagist.org/packages/michallkanak/symfony-open-system-monitor)[![Symfony Version](https://camo.githubusercontent.com/fa34c4c37075051a62d6a1cdb45f03b1de84e457b1be4640f53c96b47ba88d6f/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f53796d666f6e792d362e34253230253743253230372e782d626c75652e737667)](https://symfony.com/)[![PHP Version](https://camo.githubusercontent.com/789befc8d88593153c7b6252f5256360c9532b26eb84fcb39b1ab842cc239e9d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e322532422d707572706c652e737667)](https://www.php.net/)[![License](https://camo.githubusercontent.com/9871fd9c01a4ba9a083a495c58bd29f568017a7c435732679734b4da565158be/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d437573746f6d2d626c75652e737667)](LICENSE)

*A flexible, extensible monitoring bundle for Symfony applications. Monitor URLs, routes, database entities, and custom metrics with configurable rules and multi-channel notifications.*

Symfony Open System Monitor is a tool that **watches over your website or application around the clock** and instantly alerts you the moment something goes wrong — whether it's a page that stopped loading, a service that went down, or an unusual spike in errors or orders.

> **It goes far beyond simple URL checks.** Unlike basic uptime monitors, this tool can look *inside* your system — monitoring database records, business processes, background services, and specific application behaviors. If payments stop being processed, invoices stop being sent, or a queue starts backing up, you'll know immediately — not hours later.

### What Does It Do for You?

[](#what-does-it-do-for-you)

ProblemHow This Tool HelpsYour website goes down at nightYou get an instant alert via email, SMS, Telegram, or SlackA critical page returns an errorAutomatic notification before customers noticeOrders stop being placed (but the site looks fine)Monitor your database — alert when no new orders arrive in X minutesPayment processing silently failsDetect failed payment records and notify your team immediatelyEmails or invoices stop being sentTrack queue activity and catch issues before they pile upA background job (cron) stops runningDetect missing activity and alert before data gets staleInventory or stock data stops updatingMonitor specific fields or record counts in your databaseYou want a status overviewA secure, real-time dashboard shows everything at a glance> 💬 **Got questions or need help getting started?**Reach out — we're happy to discuss your needs, provide a custom setup, or simply answer any questions. **Contact: [kanakmichal\[at\]gmail.com](mailto:kanakmichal@gmail.com)**

---

Status Dashboard
----------------

[](#status-dashboard)

*Compact table view with expandable activity logs:*

Light mode: [![Light mode](docs/images/lightmode.png)](docs/images/lightmode.png)

Dark mode: [![Dark mode](docs/images/darkmode.png)](docs/images/darkmode.png)

Features
--------

[](#features)

- 🔍 **Multiple Monitor Types**: URL, routing, entity monitoring, custom query and extensible
- 📊 **Flexible Storage**: Database, filesystem, or Redis for logs and alert states
- 📧 **Multi-Channel Notifications**: Email, SMS, Telegram, Slack, Discord, webhooks, and extensible
- 🔔 **Notification Profiles**: Define channels once and reuse them across rules — no repetition
- ⏰ **Cron-Based Scheduling**: Single cron entry with built-in frequency management
- ⏰ **Request-Based Scheduling**: Execute monitoring every X requests
- 🔧 **Highly Extensible**: Interface-based design for custom monitor types, conditions, and channels
- 📈 **Status Dashboard**: Optional password-protected monitoring overview
- 🎯 **Smart Alerting**: Prevent duplicate notifications, recovery alerts, and reminders
- 🚀 **Framework Support**: Symfony 6.4-7.x (PHP &gt;= 8.2)

Quick Start
-----------

[](#quick-start)

### Installation

[](#installation)

```
composer require michallkanak/symfony-open-system-monitor
```

The bundle will be automatically registered via Symfony Flex.

### Basic Configuration

[](#basic-configuration)

Create `config/packages/symfony_open_system_monitor.yaml`:

```
symfony_open_system_monitor:
  storage:
    log_storage: database
    alert_state_storage: database

  status_page:
    enabled: true
    password: "%env(MONITOR_STATUS_PASSWORD)%"

  # Define notification profiles once — reuse across all rules
  notification_profiles:
    admin_email:
      channel: email
      config:
        to: "%env(MONITOR_EMAIL_TO)%"

  rules:
    - name: "Website Health Check"
      type: url
      config:
        url: "https://example.com/health"
        expected_status: 200
      schedule:
        cron: "*/5 * * * *"
      notifications:
        - use: admin_email # ← profile reference (or use inline: channel: email)
```

### Environment Variables

[](#environment-variables)

Copy keys from `.env.example` to `.env.local` and configure:

```
# .env.local
MONITOR_STATUS_PASSWORD=your-secret-password-change-it
MONITOR_EMAIL_TO=admin@example.com
```

See [`.env.example`](.env.example) for all available options (Telegram, Slack, Discord, SMS, webhooks).

### Cron Setup

[](#cron-setup)

```
* * * * * php /path/to/project/bin/console monitor:run >> /dev/null 2>&1
```

### Database Migration (Database Storage Only)

[](#database-migration-database-storage-only)

```
php bin/console doctrine:migrations:migrate
```

### Access Status Page

[](#access-status-page)

Navigate to: `https://your-domain.com/monitoring/status`

### Maintenance

[](#maintenance)

#### Log Cleanup

[](#log-cleanup)

Clean up old monitoring logs to prevent database/storage growth:

```
# Delete logs older than 30 days (default)
php bin/console monitor:logs:cleanup

# Delete logs older than 7 days
php bin/console monitor:logs:cleanup --days=7

# Preview what would be deleted (dry-run)
php bin/console monitor:logs:cleanup --dry-run
```

**Recommended**: Add to cron for automatic cleanup:

```
0 2 * * * php /path/to/project/bin/console monitor:logs:cleanup --days=30
```

#### Availability Statistics

[](#availability-statistics)

Availability percentages are cached in `AlertState` and updated incrementally with each check run. This ensures optimal performance on the status page without recalculating stats on every request.

Documentation
-------------

[](#documentation)

- [Installation Guide](docs/installation.md)
- [Configuration Reference](docs/configuration.md)
- [Usage Examples](docs/usage-examples.md)
- [Extending the Bundle](docs/extending.md)
- [Rate Limiting &amp; Request-Based Monitoring](docs/rate-limiting-and-request-based.md)
- [Notification Template Variables](docs/template-variables.md)
- [API Reference](docs/api-reference.md)

Translations
------------

[](#translations)

The status dashboard supports multiple languages out of the box:

LanguageCodeFileEnglish`en``messages.en.yaml`Polish`pl``messages.pl.yaml`German`de``messages.de.yaml`Spanish`es``messages.es.yaml`French`fr``messages.fr.yaml`Italian`it``messages.it.yaml`Czech`cs``messages.cs.yaml`Slovak`sk``messages.sk.yaml`Configure in `config/packages/translation.yaml`:

```
framework:
  default_locale: en # or pl, de, es, fr, it, cs, sk
```

Monitor Types
-------------

[](#monitor-types)

### URL Monitoring

[](#url-monitoring)

```
type: url
config:
  url: "https://api.example.com/status"
  method: GET
  expected_status: 200
  timeout: 10
```

### Entity Monitoring

[](#entity-monitoring)

```
type: entity
config:
  entity_class: "App\\Entity\\Order"
  field: "createdAt"
  conditions:
    - type: "count_new"
      time_period: "1 hour"
      operator: ">"
      threshold: 100
```

Available condition types: `count_new`, `count_modified`, `avg_value`, `sum_value`, `min_max_value`, `distinct_count`, `exists`, `percentage_change`, `custom_query`.

### Routing Monitoring

[](#routing-monitoring)

```
type: routing
config:
  route: "app_api_health"
  expected_status: 200
```

### Custom Query Monitoring

[](#custom-query-monitoring)

```
type: entity
config:
  entity_class: "App\\Entity\\Order"
  conditions:
    - type: "custom_query"
      dql: "SELECT COUNT(o) FROM App\\Entity\\Order o WHERE o.status = :status"
      parameters:
        status: "failed"
      operator: ">"
      threshold: 0
      description: "Failed orders exist"
```

### Schedule &amp; Alerting Options

[](#schedule--alerting-options)

Per-rule options for smart alerting:

```
schedule:
  cron: "*/5 * * * *"
  notify_on_recovery: true # alert when service recovers
  remind_on_failure: true # repeat alert while still failing
  remind_interval: 3600 # reminder repeat interval in seconds (default: 3600)
```

Notification Channels
---------------------

[](#notification-channels)

- **Email** - Symfony Mailer
- **SMS** - SMSAPI integration
- **Telegram** - Bot API
- **Slack** - Webhooks
- **Webhook** - Generic HTTP POST
- **Discord** - Webhooks

Storage Options
---------------

[](#storage-options)

- **Database** - Doctrine ORM (MySQL, PostgreSQL, SQLite, etc.)
- **Filesystem** - JSON files (default, zero dependencies)
- **Redis** - High-performance via Predis
- **Custom** - Implement `LogStorageInterface` / `AlertStateStorageInterface` and register as a service

Advanced Configuration
----------------------

[](#advanced-configuration)

### Request-Based Monitoring

[](#request-based-monitoring)

Alternative to cron — runs checks every X HTTP requests via the `kernel.terminate` event:

```
symfony_open_system_monitor:
  request_based:
    enabled: true
    execute_every: 100
```

### Notification Rate Limiting

[](#notification-rate-limiting)

Limit notifications per channel per hour to prevent alert spam:

```
symfony_open_system_monitor:
  rate_limits:
    email: 50
    sms: 10
    telegram: 100
    slack: 100
    discord: 100
    webhook: 100
```

### Custom Notification Templates

[](#custom-notification-templates)

Override built-in Twig templates with your own:

```
symfony_open_system_monitor:
  template_paths:
    - "%kernel.project_dir%/templates/monitoring"
```

### Scheduler Tuning

[](#scheduler-tuning)

```
symfony_open_system_monitor:
  scheduler:
    lock_timeout: 3600 # max seconds a lock is held (default: 3600)
    max_execution_time: 300 # max seconds per monitor run (default: 300)
```

### Database-Stored Rules

[](#database-stored-rules)

Enable rules defined in the database in addition to YAML config:

```
symfony_open_system_monitor:
  enable_database_rules: true
```

### Custom Status Page Path

[](#custom-status-page-path)

```
symfony_open_system_monitor:
  status_page:
    enabled: true
    path: "/admin/monitor" # default: /monitoring/status
    password: "%env(MONITOR_STATUS_PASSWORD)%"
```

License
-------

[](#license)

**Free for personal projects and small companies (&lt;100 employees)** with attribution.

**Commercial license required** for organizations with 100+ employees.

See [LICENSE](LICENSE) for details. Contact: kanakmichal\[at\]gmail.com

Author
------

[](#author)

**Michał Kanak** - [GitHub](https://github.com/michallkanak)kanakmichal\[at\]gmail.com

Contributing
------------

[](#contributing)

Contributions are welcome! Please read the contributing guidelines before submitting PRs.

Support
-------

[](#support)

- [Documentation](docs/)
- [Issue Tracker](https://github.com/michallkanak/symfony-open-system-monitor/issues)

###  Health Score

35

—

LowBetter than 77% of packages

Maintenance89

Actively maintained with recent releases

Popularity3

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity36

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

56d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/35bdeeb4e748dac6cbbc8369be22264af99743a23bb39c033b760385663a6dc1?d=identicon)[michal.kanak](/maintainers/michal.kanak)

---

Top Contributors

[![michallkanak](https://avatars.githubusercontent.com/u/12290176?v=4)](https://github.com/michallkanak "michallkanak (5 commits)")

---

Tags

symfonymonitoringnotificationscronhealth checkalertinguptime

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/michallkanak-symfony-open-system-monitor/health.svg)

```
[![Health](https://phpackages.com/badges/michallkanak-symfony-open-system-monitor/health.svg)](https://phpackages.com/packages/michallkanak-symfony-open-system-monitor)
```

###  Alternatives

[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.4M195](/packages/sulu-sulu)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.4M506](/packages/shopware-core)[open-dxp/opendxp

Content &amp; Product Management Framework (CMS/PIM)

9017.2k55](/packages/open-dxp-opendxp)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
