Commit Graph
954 Commits
Author SHA1 Message Date
Loakesh Indiran afc0d18d9b fix: return 401 Unauthorized instead of 403 Forbidden for authentication failures (#9564)
## Problem

APIs were returning **403 Forbidden** when tokens were invalid or
expired, which is incorrect. According to HTTP specifications:
- **401 Unauthorized**: Authentication failure (invalid/expired token,
user not found)
- **403 Forbidden**: Authorization failure (authenticated but lacks
permissions)

## Changes

- [x] Previously, short URL paths would redirect to `/web/` on auth
failure. Now they consistently return 401 like all other endpoints.

### token.rs
- Changed `ErrorForbidden` to `ErrorUnauthorized` when token validation
fails (`is_valid == false`)
- Changed `ErrorForbidden` to `ErrorUnauthorized` when user does not
exist in the system
- Changed `ErrorForbidden` to `ErrorUnauthorized` for non-enterprise
builds (unsupported auth method)
- Kept `ErrorForbidden` only for `check_permissions()` failures (true
authorization issues)
2025-12-10 18:28:42 +05:30
Yashodhan JoshiandYashodhan Joshi 4780a9edc6 fix: rbac for native user for license call (#9529)
Fixes an issue where a native user in non-default account would get 401
for license api call, whereas we want all users to have get access to
license call.

---------

Signed-off-by: Yashodhan Joshi <yjdoc2@gmail.com>
Co-authored-by: Yashodhan Joshi <yjdoc2@gmail.com>
2025-12-10 17:07:31 +05:30
Yashodhan JoshiandYashodhan Joshi 6493f2b003 fix: cloud org related fixes (#9416)
Fixes for various p2 bugs and UI issues, some other functionality
changes as well.
NOTE: because of some CLA issues, I have squashed all the original
commits into a single one. There are no code changes compared to before.

Signed-off-by: Yashodhan Joshi <yjdoc2@gmail.com>
Co-authored-by: Yashodhan Joshi <yjdoc2@gmail.com>
2025-12-10 15:15:29 +05:30
Ashish Kolheandgithub-actions[bot] 34939d0769 fix: fqn co relation user settings (#9536)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-12-10 06:38:21 +05:30
79bbe72ee3 feat: co-relation phase 2 (#9513)
Design at : streams-corelation

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2025-12-08 19:05:33 +05:30
9056a2c92d feat: revamp Conditions in alerts and pipelines (#9267)
Co-authored-by: Uddhav Dave <uddhav@MacBook-Pro.local>
Co-authored-by: sai nikhil kethe <nikhil@openobserve.ai>
Co-authored-by: Shrinath Rao <shnath@openobserve.ai>
2025-12-08 11:36:56 +05:30
Hengfei Yang 3435b80d6d feat: Add cache reload API and CLI command (#9497) 2025-12-05 16:01:01 +08:00
udev 0829ee89fe feat: add metrics workgroup (#9400) 2025-12-04 21:43:31 +05:30
Hengfei Yang 04b15af48f refactor: unify bulk API to use the same ingestion function (#9467) 2025-12-04 18:21:58 +08:00
Ashish Kolheandgithub-actions[bot] 1353ea653b feat: service discovery (#9469)
Design at:

streams-corelation/SERVICE_CORRELATION_ARCHITECTURE.md

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-12-04 13:58:09 +05:30
Hengfei Yang 9c249f2c3c fix: rollback scc (#9442) 2025-12-03 11:08:23 +08:00
ByteBaker ada80858e8 feat: migrate service graph to SQL-based daemon architecture
Replace in-memory EdgeStore with daemon-based architecture that periodically
queries trace streams using SQL aggregation in DataFusion.

Architecture:
- Daemon runs in compactor job every 1 hour (default, configurable)
- Queries last 60 minutes of trace data (configurable window)
- Uses DataFusion SQL with CTE for efficient aggregation
- Calculates p50, p95, p99 percentiles using approx functions
- Writes aggregated edges to internal `_o2_service_graph` stream
- Zero impact on trace ingestion performance

Key Changes:
- Add `processor.rs` with SQL-based daemon that queries trace streams
- Add `aggregator.rs` to write SQL results to `_o2_service_graph` stream (uses json! macro)
- Refactor `api.rs` to query pre-aggregated data from stream
- Move business logic to enterprise repo (`build_topology()`, `span_to_graph_span()`)
- Remove ALL inline processing during trace ingestion
- Delete in-memory EdgeStore, worker threads, and buffering code
- Feature-gated for enterprise builds with non-enterprise stubs

SQL Query:
- CTE extracts client/server from span_kind ('2'=SERVER, '3'=CLIENT)
- Aggregates by (client, server) with COUNT, percentiles, error rate
- Filters: span_kind IN ('2','3') AND peer_service IS NOT NULL

Configuration:
- O2_SERVICE_GRAPH_ENABLED (default: false)
- O2_SERVICE_GRAPH_PROCESSING_INTERVAL_SECS (default: 3600) - Daemon run frequency
- O2_SERVICE_GRAPH_QUERY_TIME_RANGE_MINUTES (default: 60) - Query window size

Technical Details:
- Stream name: `_o2_service_graph` (internal stream)
- Edge timestamp: Uses query end time for API compatibility
- Span kinds: '2' (SERVER), '3' (CLIENT) as VARCHAR in parquet
- Percentiles: approx_median(), approx_percentile_cont(0.95), approx_percentile_cont(0.99)
2025-12-01 17:06:53 +05:30
Loakesh Indiran baa7520d90 fix: overwrite aggs cache instead of delete and rewrite cache (#9390)
How I run my query 
1. nov 26 10:30 - 11:30 - interval 30 mins
2. nov 26 10:30 - 16:30 - interval 60 mins
3. nov 26 10:30 - 16:30 - interval 60 mins -- refresh cache

Cache dir
1. on first run 
- has 2 caches 30 mins 
2. on 2nd run 
- will havve mixed 30mins cache and 60 mins cache 

TODO: 
-  [x] Problem 1: 
on step 3 
- the interval for that duration is 60 mins
- but the discovery of cache will also include the 30 mins cache
[@mod.rs](file:///Users/lin/o2/openobserve/src/service/search/mod.rs)
`discover_cache_for_query`
- the overwrite will over write the 60 mins cache only. How to address
this problem?
- [x] Problem 2:
- fix: add rbac control only user with permussion to edit stream can
`refresh cache`

Proposed Solution
- On `refresh_cache` run streaming aggs without using cache
- at `streaming/execution.rs` , at the end of steaming aggs delete all
the cache files for the given duration when there are miss matched cache
interval files
- then remove the `streaming_id` from the `GLOBAL_CACHE`
- eg: nov 26 10:30 - 16:30 - interval 60 mins -- refresh cache 
- Cache consists of 30mins or 4hr interval files all of them will be
deleted
- 60 mins cache interval files will be overwritten or created a new.
- This way on the next run there will be no query results mismatch when
the query runs again with the newly updated cache, especially delayed
data for the same duration.
- add rbac control to only allow users with edit permissions to stream
to use this feature
2025-11-29 12:49:39 +05:30
Ashish Kolhe e0aef9677e chore:move-service-graph-config (#9370) 2025-11-28 22:19:32 +05:30
Ashish Kolheandgithub-actions[bot] 0b4e66c8f6 feat: sampling for search apis and patterns (#9207)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-11-28 16:13:04 +05:30
udev e5284b82aa fix: add email headers to metrics and traces ep (#9357)
adding headers to multiple endpoints for usage reporting
2025-11-28 10:57:17 +05:30
Hengfei Yang fa0672a663 feat: add super cluster support for metrics (#9225) 2025-11-27 20:39:09 +08:00
44011fbebc feat: add organization-level alert deduplication with semantic field groups (#9209)
## Summary

Implements org-level alert deduplication with semantic field groups for
intelligent alert suppression and batched notifications. This feature
prevents alert storms by deduplicating alerts based on configurable
fingerprints and grouping related alerts together.

### Core Capabilities

- **Semantic Field Groups**: Map field name variations (`hostname`,
`host`, `node`) to canonical dimensions for consistent deduplication
across different data sources
- **Organization-Level Configuration**: Global deduplication settings
with cross-alert support to suppress alerts from different rules sharing
semantic dimensions
- **Alert Grouping & Batching**: Wait-and-collect logic with three send
strategies (`FirstWithCount`, `Summary`, `All`) for batched
notifications
- **Per-Alert Control**: Individual alert deduplication settings with
optional fingerprint field customization

### Features

**Deduplication Modes:**
- Per-alert exact matching using fingerprint-based TTL expiration
- Cross-alert semantic matching using org-defined dimension groups
- Configurable time windows (per-alert override or org-level default)

**Alert Grouping:**
- Batch alerts with same fingerprint before sending notifications
- Three strategies: first alert with count, summary with names, or all
details
- Configurable wait time (1-300 seconds) and max batch size (1-100
alerts)
- Background processor runs every 1 second for expired batches

**Semantic Field Groups:**
- Built-in presets for common fields (host, IP address, service)
- Kubernetes resource groups (cluster, namespace, pod, node, container)
- Field normalization support (lowercase + trim)
- Overlap handling with first-defined precedence

### Configuration Types

- `SemanticFieldGroup`: Field name equivalence definitions with
normalization
- `GlobalDeduplicationConfig`: Org-level settings with semantic groups
and cross-alert dedup
- `DeduplicationConfig`: Per-alert fingerprint fields and grouping
options

### API Endpoints

- `GET /{org_id}/alerts/deduplication/config` - Retrieve org-level dedup
config
- `POST /{org_id}/alerts/deduplication/config` - Set org-level dedup
config
- `DELETE /{org_id}/alerts/deduplication/config` - Delete org-level
dedup config

### Implementation Details

- Pure business logic algorithms in enterprise layer (fingerprinting,
matching, calculations)
- OSS service layer orchestrates database operations with enterprise
delegation
- Feature-gated with `#[cfg(feature = "enterprise")]` for
enterprise-only functionality
- Background job architecture for async batch processing
- Storage: Org config in KV DB at `/alert_config/{org_id}/deduplication`

### Architecture

```
Alert Triggered
     ↓
Query Evaluation
     ↓
Deduplication Check (fingerprint + TTL)
     ↓
Grouping Enabled? → Add to Batch → Wait/Collect → Send Grouped
     ↓ No
Send Individual Notification
```

---------

Co-authored-by: Ashish Kolhe <ashish.j.kolhe@gmail.com>
Co-authored-by: Shrinath Rao <shnath@openobserve.ai>
2025-11-26 12:09:10 +05:30
Huaijin 9190a9d650 feat: upgrade datafusion to 51 (#9202) 2025-11-25 23:16:09 +08:00
de5edadb9e feat: added destination type for remote destination (#9080)
Signed-off-by: Yashodhan Joshi <yjdoc2@gmail.com>
Co-authored-by: Yashodhan Joshi <yjdoc2@gmail.com>
Co-authored-by: mmosarafO2 <mosraf@openobserve.ai>
Co-authored-by: Yashodhan Joshi <yashodhan@openobserve.ai>
2025-11-25 14:07:37 +05:30
Harsh Mahajan 7f9a4b7359 fix: small bug in runtime config API (#9278)
There was case in which root-password was not hidden, PR makes this go
away
2025-11-24 19:38:51 +05:30
Subhra264 5c465c1fc5 feat: add a warning about future deprecation of mysql support (#9229) 2025-11-24 16:28:05 +05:30
Loakesh Indiran 1e7af6372a fix: add use_cache & clear_cache for _multi_search_stream (#9249) 2025-11-23 19:38:25 +05:30
Subhra264 de734bd5d8 feat: Allow Json values in alert row templates (#9137)
# Add Row Template Type Support for Alerts

## Overview
This PR adds support for configurable row template types in alerts,
allowing users to choose between **String** and **JSON** formats for row
templates. This provides flexibility in how alert data is formatted and
sent to destinations.

## Features

### Row Template Type Selection
- Added a new `row_template_type` field to alerts with two options:
- **String**: Traditional string-based templates with variable
interpolation
  - **JSON**: Structured JSON templates for programmatic consumption

### Database Layer
- Uses efficient `smallint` (i16) storage: `0` for String, `1` for JSON
- Added migration `m20251118_000001_add_alert_row_template_type` with
backward compatibility (defaults to String)
- Includes support for PostgreSQL, MySQL, and SQLite

### API Layer
- Returns enum string representation (`"String"` or `"Json"`) in API
responses
- Full support in GET, CREATE, and UPDATE alert endpoints

### UI Changes
- Added toggle button in alert creation/editing form to switch between
String and JSON template types
- Dynamic placeholder text based on selected template type
- Persists user's template type selection in the database

## Usage Example

### String Template (Default)
When creating an alert with row template type set to **String**:

```
Template Type: [String] JSON
Row Template: Alert triggered: {alert_name} at {timestamp} Affected user: {user_id} Error count: {error_count}
```

### JSON Template
When creating an alert with row template type set to **JSON**:

```
Template Type: String [JSON]
Row Template: { "alert": "{alert_name}", "timestamp": "{timestamp}", "user": { "id": "{user_id}", "name": "{user_name}" }, "metrics": { "error_count": {error_count}, "severity": "{severity}" } }
```

The JSON template type automatically parses and validates JSON
structure, making it ideal for:
- Webhook integrations that expect JSON payloads
- Structured logging systems
- API endpoints requiring specific JSON schemas
- Downstream systems that need programmatic access to alert data

## Technical Details

### Architecture
- **Database**: Stores as `smallint` (0 or 1) for efficiency
- **Service Layer**: Uses `RowTemplateType` enum throughout application
logic
- **API**: Serializes enum as strings (`"String"`, `"Json"`)
- **Frontend**: TypeScript interface uses string type with toggle UI
component

### Backward Compatibility
- Existing alerts without `row_template_type` default to `String`
- Migration adds column with `DEFAULT 0` ensuring zero downtime
- API handles both old and new alert formats seamlessly

## Testing
- Added unit tests for database migration (PostgreSQL, MySQL, SQLite)
- Tested enum serialization/deserialization
- Verified UI toggle behavior and data persistence
- Confirmed backward compatibility with existing alerts

<img width="1070" height="770" alt="Screenshot 2025-11-19 at 5 46 34 PM"
src="https://github.com/user-attachments/assets/900edb1c-815e-4240-91e2-50a1a582a9b0"
/>
2025-11-20 14:44:08 +05:30
Hengfei Yang f3f5b29aa2 feat: introduce query_values_default_num configuration. (#9206)
This PR add a new ENV that allow you to change the default num of field
values.
```
ZO_QUERY_VALUES_DEFAULT_NUM=10
```
2025-11-20 16:25:12 +08:00
Hengfei Yang 51a0980323 feat: [BE] PromQL streaming output support (#9191) 2025-11-20 10:30:55 +08:00
Sai Nikhil f98183787f fix: mainlayout page refactoring (#9176)
1. we have created header component which will seperate out the header
part from mainlayout
2. introduced custom dark logo feature , it will fallback to light mode
logo if dark mode logo is not there
2025-11-19 15:48:35 +05:30
Harsh Mahajan ab260764b3 feat:adding config api (#9160) 2025-11-19 14:59:18 +08:00
ByteBaker 84aa3902db feat: move graceful drain to enterprise
Moves all graceful shutdown logic from PR #8876 to enterprise repository.
2025-11-19 10:10:56 +05:30
ByteBaker 2c75a4fea9 fix: broken tests from #9009
https://github.com/openobserve/openobserve/pull/9009
broke a few tests by introducing a new param in a function.

Fixed those as well as a few clippy issues.
2025-11-19 09:27:48 +05:30
sktrpathiandAshish Kolhe ee28cab80b fix: prevent triggers stream schema divergence across organizations (#9163)
When `ZO_USAGE_REPORT_TO_OWN_ORG` is enabled (default: true), triggers
are written to both _meta and originating orgs. This caused schema
divergence where some orgs missing fields like 'error', breaking
dashboard queries.

Add ensure_triggers_stream_schema() to auto-sync missing TriggerData
fields before ingestion. Runs once per stream, logs missing fields, and
updates defined_schema_fields gracefully without blocking ingestion.

Fixes queries like: SELECT error FROM triggers WHERE status='failed'

---------

Co-authored-by: Ashish Kolhe <ashish.j.kolhe@gmail.com>
2025-11-18 14:53:18 +05:30
Ashish Kolhe 9059afdb2b feat: sso claim parser (#9156) 2025-11-18 13:30:44 +05:30
Hengfei Yang 8aeff17410 fix: remove no need middleware for actix-web (#9167) 2025-11-18 08:44:01 +08:00
Simha G 6ca371ec99 fix: Concurrency control for file locking has multiple anti-concurrent design patterns in the way (#8523) 2025-11-17 20:35:43 +08:00
ByteBaker 187cdd72f4 fix: make WAL_DIR_DEFAULT_PREFIX pub
https://github.com/openobserve/openobserve/pull/8876 had made
this variable private, resulting in failed enterprise builds.

It also removed one of the imports causing build failure.

This commit reverts those specific changes.
2025-11-17 12:22:29 +05:30
ByteBaker d8e8e27661 fix: address code review feedback on graceful drain API
- Fix panic on path canonicalization in check_has_pending_files()
- Implement proper recursive directory checking for parquet files
- Add exponential backoff to draining loop (50ms -> 1s)
- Validate query parameter strictly in enable endpoint to prevent accidental node disablement

These changes address critical robustness issues identified in the code review:
1. Prevents potential panics during shutdown when WAL path is missing
2. Ensures correct pending file detection instead of assuming all subdirectories have files
3. Reduces CPU usage during drain with exponential backoff
4. Prevents unintentional node disablement from invalid/missing parameters
2025-11-17 05:45:44 +05:30
ByteBaker 2bbb915862 feat: add graceful drain API for Kubernetes autoscaling
Implements cloud-agnostic graceful shutdown mechanism to support
Kubernetes preStop hooks and other orchestration platforms.

Changes:
- Add IS_INGESTER_DRAINING global flag with atomic operations
- Enhance /enable?value=false to trigger flush and set draining mode
- Add /drain_status endpoint to monitor shutdown readiness
- Modify parquet upload job to prioritize draining mode
- Exit upload loop when all files are uploaded to S3

API Usage:
- PUT /node/enable?value=false - Initiates drain (flushes memory, sets flag)
- GET /node/drain_status - Returns readyForShutdown status

Benefits:
- Eliminates fixed 900s wait in Helm charts
- Cloud-agnostic (works with K8s, ECS, Docker Swarm, systemd)
- Data-safe: ensures all WAL files uploaded before shutdown
2025-11-17 05:45:44 +05:30
Sai Nikhil 803434bd30 fix: theme customization (#9077) 2025-11-14 11:55:50 +05:30
Hengfei Yang 561ddd3b4d fix: add some debug logs for query slow (#9072) 2025-11-12 22:34:18 +08:00
Simha Gandsai nikhil kethe e92f385751 feat: Alert and Pipeline History columns are now sortable (#9052)
# PR Type
Enhancement

# Description
The columns in the Alerts and Pipelines History are augmented to be
sortable. The backend endpoint is updated accordingly too.

---------

Co-authored-by: sai nikhil kethe <nikhil@openobserve.ai>
2025-11-12 19:03:47 +05:30
ByteBaker d0cf8d3fc3 chore: utilize with_capacity in collections + cleanup 2025-11-12 14:18:01 +05:30
85a8fc1648 feat: license check (#8522)
### **User description**
This adds license check job


___

### **PR Type**
Enhancement, Bug fix


___

### **Description**
- Add enterprise license HTTP APIs and DB watch

- Enforce quota checks on search and ingestion

- Always enable usage reporting; simplify modes

- Expose license expiry in config and UI


___

### Diagram Walkthrough


```mermaid
flowchart LR
  Backend["Backend: License APIs + quota checks"]
  DB["DB: License watch + dist lock"]
  Config["Config: usage/reporting & expiry"]
  UI["UI: Settings License page + banner"]
  Search["Search/PromQL: quota enforcement"]

  Backend -- "watch updates" --> DB
  Backend -- "expose expiry" --> Config
  UI -- "GET/POST /api/license" --> Backend
  Search -- "check_search_allowed" --> Backend
```



<details> <summary><h3> File Walkthrough</h3></summary>

<table><thead><tr><th></th><th align="left">Relevant
files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>21
files</summary><table>
<tr>
<td><strong>config.rs</strong><dd><code>Validate usage mode and publish
interval bounds</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-9aeee4a74c0520daa40f9b81c7016f5b6b3254375b968dd7598e745630980d62">+16/-4</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Add license GET/POST endpoints with
validation</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-d569000673e415b222a20a6f4f50a93c278c189a7d6e43231d5ab8807e93021f">+75/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Register license routes for
enterprise builds</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-a1cfd40da1ab6cd4db0181fd8664965034298047b3b7c3320c5385897a7c4aed">+2/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Enforce search quota in PromQL
endpoints</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-0ad5729a1fbce00ff53076728c51822400c13af9918e1d8554f41be56d060fa0">+24/-1</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Add enterprise search quota checks
in endpoints</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-96630a0dbb6dd7b2b0248fa325c7c7041ce31340c32826675a4a70772e9d29f6">+51/-1</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>search_stream.rs</strong><dd><code>Enforce quota in
streaming search endpoints</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-642de43ff6b19ae41087a9f1efc02d8b0b873809e0c92cbddfac1a30ef3f1184">+21/-1</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Expose license expiry; always
enable usage flag</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-ca09c9c9b020049bdbc3382c466bfcca80daac92e98760d9a9a76172abf34049">+8/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Wire license endpoints into
router</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-02556e3f515441b5d2b6bbea7829df488beac03c4cc41309a6638ae3c0e0aec6">+3/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Add license check locking and
startup watchers</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-f2e4c29b8eef22189ec704a832633c4bd135a24444f054864c98064bd0963681">+57/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>license.rs</strong><dd><code>Implement license update
broadcast and watch</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-43bb2d7d70d03657337dfabb078079de71fae8a7f58962a10ac68c03594e0f81">+70/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Export license DB module for
enterprise</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-b7e3bf7f0ac23dd084c0c817a310a4d5e7a64ff532746d182986ef940fa03fd0">+2/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Enforce ingestion quota for
enterprise</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-7c7b5bca85f0ced652965cae66540c96f56dfcca4f4c16b77bf7b45aac203d1b">+10/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Provide search quota check
helper</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-c3b85ea662a885fbd39797968928b291cb59a58f53a03f7b7dfd7ba8b6a7985a">+18/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>ingestion.rs</strong><dd><code>Simplify reporting mode;
always requeue on error</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-3edd5f4ed1eed0f765b7b450ef0fbf587632e6b22302006a5e397049e297057f">+19/-50</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>mod.rs</strong><dd><code>Always enable usage queue and
publishing</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-c6255010f7a87d6acdb3ad04954fc9f2c27350ae319c53a1857b120aa06408a3">+2/-25</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>useManagementRoutes.ts</strong><dd><code>Add license
management route</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-b71a1d39b1fab0749f0668d5f16382536fbda6e2f0c92c56a972fb5d8b5835f5">+8/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>license_server.ts</strong><dd><code>Add client for license
APIs</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-3ac3fe8faca5f5a6aebd9d5e8885837f1511834eb7c78d0830af8f00c70523cb">+16/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>License.vue</strong><dd><code>New license management UI with
usage</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-614c7b48f6f2ab1e8041d20c7583b6864285eacf9db032c27508b76f6de8467f">+469/-0</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>index.vue</strong><dd><code>Add License tab and routing
guards</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-699c63979f851c48ad440a078e93282fd797a18fc065e5331b2e41122ddb8b69">+27/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>LicensePeriod.vue</strong><dd><code>License expiry banner
component</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-14f02914aaa78ef3e82717173fa95455b7f1092faff2d0dbd51e243663850ad4">+111/-0</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>HomeView.vue</strong><dd><code>Show license expiry banner
and navigate</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-9af441af191d3254ef5f9db603dca75486de7638cda41a3c050e7b3c33d68280">+9/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>
</table></details></td></tr><tr><td><strong>Bug
fix</strong></td><td><details><summary>1 files</summary><table>
<tr>
<td><strong>schema.rs</strong><dd><code>Remove usage_enabled dependency
in org creation</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-4696a44abde2df4ac48fed716f930bfdcc01759bdfcfd8d802821c6dd857bff9">+1/-3</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

</table></details></td></tr><tr><td><strong>Documentation</strong></td><td><details><summary>1
files</summary><table>
<tr>
<td><strong>en.json</strong><dd><code>Add i18n key for License tab
label</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8522/files#diff-892aa3d75ab6e129ef9116aa21bec1b9a15ba69ce5366d2a19128078c690d824">+2/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>
</table></details></td></tr></tr></tbody></table>

</details>

___

---------

Signed-off-by: Yashodhan Joshi <yjdoc2@gmail.com>
Co-authored-by: Yashodhan Joshi <yjdoc2@gmail.com>
Co-authored-by: sai nikhil kethe <nikhil@openobserve.ai>
2025-11-11 14:36:03 +05:30
Simha GandSubhradeep Chakraborty 24ac8ee0ff fix: Add RBAC to the Alerts and Pipelines history endpoints and add tests (#8930)
# PR Type
Feature/Fix

# Description
The pipelines history and alerts history endpoints are now covered by
RBAC. Added basic e2e api test for the same endpoints.

---------

Co-authored-by: Subhradeep Chakraborty <chakrabortysubhradeep556@gmail.com>
2025-11-11 11:49:14 +05:30
Abhay PadamaniandKirtan Thakkar 098ee9d7d2 fix: dashboard panel re-position (#9016)
- #9020

---------

Co-authored-by: Kirtan Thakkar <kirtan@kiara.tech>
2025-11-10 18:54:30 +05:30
Yashodhan JoshiandYashodhan Joshi a5ea45bd54 fix: fix middleware check (#8986)
There were few issues with the middleware, this attempts to fix it.

---------

Signed-off-by: Yashodhan Joshi <yjdoc2@gmail.com>
Co-authored-by: Yashodhan Joshi <yjdoc2@gmail.com>
2025-11-07 14:48:53 +05:30
ByteBaker eedebaeec8 feat: enable dual reporting and add alert history UI
Changes alert trigger reporting behavior to write to both the originating
organization and `_meta` org by default, with new UI for viewing history.

**Backend:**
- Change `ZO_USAGE_REPORT_TO_OWN_ORG` config default from `false` to `true`
- Update alert history API to query organization's own `triggers` stream
- Add comprehensive backend tests for history API and config

**Frontend:**
- Integrate history metrics into main alerts table (`Total Evaluations`, `Firing Count`)
- Add alert details drawer showing properties and evaluation timeline
- Display formatted timestamps, status badges, and performance metrics
- Support click-outside and ESC key to close drawer
- Add i18n translations for history-related labels

This eliminates cross-org API calls for alert history while maintaining
global monitoring capability in `_meta` org.
2025-11-07 01:49:57 +05:30
Loakesh Indiran c7ee02a9f1 fix: aggs cache ratio reporting (#8984)
Signed-off-by: loaki07 <rustyloaki@gmail.com>
2025-11-06 22:07:59 +05:30
Loakesh Indiran 6b76fbf785 feat: clear cache main (#8919) 2025-11-05 22:27:19 +08:00
Yashodhan JoshiandYashodhan Joshi 9492f23353 fix: add a middleware for blocked org checks (#8951)
This adds a midddleware for blocking the requests for invalid orgs
before they reach the handler level.

---------

Signed-off-by: Yashodhan Joshi <yjdoc2@gmail.com>
Co-authored-by: Yashodhan Joshi <yjdoc2@gmail.com>
2025-11-04 20:50:08 +05:30
ByteBaker 1593db0e22 feat: skip aud validation for MCP-invoked requests
- Add `x-o2-mcp` header support for MCP request identification in token validator
- Wrap OpenAPI schema types with `inline()` for better documentation generation
- Update AI module imports to use new agent namespace
- fix compilation for `cloud` feature, also return early if user isn't in trial
- Enable service graph by default
2025-11-04 17:36:23 +05:30