Metadata platform service
The Metadata platform service is the Java server that gives OpenMetadata one controlled place to read, write, search, secure, and publish metadata. It joins APIs, durable metadata state, authorization, derived views, event delivery, platform settings, governance workflows, and Context Center processing so clients use one consistent platform boundary.
Service role
The service coordinates the server-side metadata platform. It accepts requests, applies platform rules, stores authoritative state, and starts background work that keeps search, lineage, alerts, insights, governance, and AI context useful.
Its main responsibilities are:
- Expose metadata, administration, search, context, service, AI, and governance APIs.
- Store entities, relationships, history, settings, credentials, tasks, and time-series records.
- Keep search, lineage, RDF, activity, insight, and vector views aligned with committed metadata.
- Identify callers and enforce resource, field, PII, secret, context, and impersonation boundaries.
- Publish change signals to audit, activity, subscriptions, alerts, and workflow consumers.
- Run scheduled work for delivery, indexing, migrations, cleanup, recovery, and workflow execution.
- Assemble bounded, permission-aware context for AI tools and persona-based search.
The application assembles these responsibilities during startup. It captures deployment settings before database-backed settings can change the live configuration object, validates runtime settings, prepares persistence and search, installs security controls, registers resources, and starts managed workers before it serves requests. The entry point is openmetadata-service/…/OpenMetadataApplication.java.
The child pages describe the main platform areas:
- Service API resources
- Metadata entity lifecycle
- Platform security and governance
- Platform configuration management
- Alerting and event delivery
- Governance workflow automation
- Context Center and AI knowledge
Request and resource surface
The API surface is a set of metadata collections. A collection is a related group of endpoints for one platform concept, such as an asset, glossary term, user, policy, lineage record, metric, knowledge page, context memory, context file, service, ontology, AI server, or search request. The service places these collections behind one HTTP, validation, and security boundary.
The service API resources page describes the resource groups and their request contracts. At this level, resources express request intent while repositories apply shared rules for validation, persistence, relationships, lifecycle, and downstream state.
Collection registration
The collection registry builds the public API from collection descriptors. It gives each resource shared access to persistence, authentication, authorization, limits, and common response behavior. This keeps resource groups from creating separate platform rules.
References: openmetadata-service/…/CollectionRegistry.java• L50-67 openmetadata-service/…/CollectionRegistry.java• L99-153 openmetadata-service/…/CollectionRegistry.java• L160-199
Resource capabilities
Resources expose more than basic create, read, update, and delete actions. The same API model supports versions, cursor paging, bulk work, status and time-series views, asynchronous work, search, lineage, data quality, data contracts, context memories, ontologies, AI execution records, and governance actions.
The service also exposes platform features that are not simple assets. These include users and bots, service connections, ingestion pipelines, activity feeds, knowledge pages, context files, AI and MCP resources, data contracts, ontologies and releases, notification templates, event subscriptions, workflows, and task records. Each resource keeps its product contract while sharing platform rules for state, relationships, secrets, search, and access.
Domain selection narrows user-facing lists as a view preference. It does not replace authorization or hide a direct read. Some global administration, team, task, incident, and shared vocabulary lists remain whole because users need them to resolve access and work across domains.
References: openmetadata-service/…/EntityResource.java• L60-100 openmetadata-service/…/DomainNavFilter.java• L20-28 openmetadata-service/…/DomainFilterExclusions.java• L22-35 openmetadata-service/…/ListFilter.java• L101-180 openmetadata-service/…/McpOAuthClientResource.java• L39-69
Metadata state and derived state
The database is the source of truth for metadata. Search, lineage, RDF, activity, charts, status views, alerts, vector search, insights, and workflow state reshape committed data for discovery and action. The service keeps these views connected to the database without making a projection the owner of metadata.
This diagram shows how a request becomes durable metadata and then feeds views and background work.
flowchart LR
Request[API request] --> Resource[Resource boundary]
Resource --> Repository[Entity repository]
Repository --> Database[(Metadata database)]
Database --> Commit[Committed change]
Commit --> Search[Search and vector views]
Commit --> Graph[Lineage and RDF views]
Commit --> History[Versions and time-series records]
Commit --> Signals[Change signals]
Commit --> Work[Insights, alerts, workflows, and AI context]
Entity persistence
An entity is a typed metadata object with an identity, version, relationships, and shared fields such as owners, tags, domains, and descriptions. The entity registry connects each type to the rules that read, validate, store, and project it.
Repositories use one common lifecycle for many entity types while adding rules for their product needs. Entity attributes are stored as JSON-backed records, while relationships are stored as separate edges and rebuilt for reads. This lets direct reads, relationship queries, history, and downstream projections use the same relationship state.
The repositories also cover special state such as API schemas, glossaries, metrics, services, tables, users, teams, tasks, incidents, workflow records, and data contracts. Time-series records keep run, incident, profile, and workflow history separate from the current entity view. Bulk ingestion can skip a full update only when the source hash matches and the stored record still contains every field covered by the incoming entity.
Comments and incident resolution updates use the current locked task state before they write. This prevents a stale caller snapshot from replacing a newer comment or task edit, while post-commit work keeps search and notifications aligned with the saved task.
References: openmetadata-service/…/EntityRepository.java• L318-347 openmetadata-service/…/EntityRepository.java• L15390-15435 openmetadata-service/…/CoreRelationshipDAOs.java• L70-80 openmetadata-service/…/WorkflowDocStoreDAOs.java• L52-90 openmetadata-service/…/TaskRepository.java• L776-900
Search and lineage state
Search is a projection shaped for discovery, filtering, aggregation, paging, semantic search, and lineage. Database commits do not wait for search updates. If a search update fails, durable retry work can rebuild the document from committed rows.
Lineage scenes turn indexed relationships into a bounded view at asset, layer, or field level. The service loads the needed nodes and edges, adds hierarchy and rollups, applies domain and caller filters, and then hydrates the result. This lets a large lineage graph remain useful without returning every related object.
Search and lineage results filter every visible node and edge through the caller's view permission. This prevents a visible asset from exposing hidden neighbors, pipelines, columns, or upstream SQL. Query filters are checked at the search boundary and invalid search-engine filters become caller errors rather than server failures.
Task lists use a timestamp and entity id as their page key when callers request creation-time or update-time order. An update-time view also accepts a lower update bound so a client can refresh changed tasks without relying on a cursor that moved when a task changed.
References: openmetadata-service/…/SearchRepository.java• L236-265 openmetadata-service/…/LineageSceneResolver.java• L55-114 openmetadata-service/…/LineageSceneLoader.java• L87-100 openmetadata-service/…/LineageSceneGraph.java• L74-96 openmetadata-service/…/TaskListOrder.java• L79-188 openmetadata-service/…/TaskResource.java• L292-381
Search privacy state
Search results and aggregations can contain data that is safe for an administrator but not for another caller. The service hides private user fields from hits and rejects searches, sorts, filters, scripts, and aggregations that name those fields for callers without access.
The same boundary applies to Context Center memories. Every memory is indexed so its owner and shared principals can find it. Search then applies memory visibility and status rules at query time rather than indexing only public memories. This keeps restricted memories searchable for the people who may use them without exposing them to other callers.
Related search records inherit access fields from their source entities. For example, query cost records carry the source query's owners, tags, tier, and domains at the top level so search authorization does not treat the record as public. PII tags also control masking of sample data and profile output before it reaches a caller.
References: openmetadata-service/…/PrivateSearchFields.java• L35-90 openmetadata-service/…/PrivateFieldReferences.java• L109-124 openmetadata-service/…/ContextMemorySearchVisibility.java• L35-80 openmetadata-service/…/SearchListFilter.java• L21-39 openmetadata-service/…/QueryCostRecordIndex.java• L23-56 openmetadata-service/…/PIIMasker.java• L66-115
Ontology and RDF projection
Ontology features connect governed concepts to catalog assets and expose a graph view of metadata. Releases capture immutable definitions for review, comparison, validation, and export. RDF remains a derived view, not the owner of metadata.
RDF live writes enter a durable ordered store in the same metadata transaction. Rebuild work uses a separate generation or dataset and replays live writes before promotion. Owned subresources such as columns, constraints, extensions, quality measurements, and list cells are replaced with their entity instead of deleting shared references.
The active ontology release defines which ontology members the serving graph represents. Changes to concept bindings, active release membership, profiles, or test-case incident status refresh the affected asset projection so the graph does not keep an old derived view after a time-series or binding change.
RDF is optional and can be initialized after a server starts with it disabled. A disabled server records that fact so a rebuild does not claim to have repaired changes made while RDF was off. Projection health distinguishes a ready graph from one that needs replay, rebuild, compaction, or storage recovery. Native previews and ontology imports use bounded parsing and do not load external documents or named graphs.
References: openmetadata-service/…/RdfLiveWriteStore.java• L29-39 openmetadata-service/…/RdfLiveWriteStore.java• L89-120 openmetadata-service/…/RdfDisabledMark.java• L27-50 openmetadata-service/…/RdfProjectionStateResolver.java• L51-119 openmetadata-service/…/RdfOwnedResources.java• L15-80 openmetadata-service/…/OntologyConceptRepository.java• L117-151 openmetadata-service/…/OntologyReleaseDAO.java• L82-103 openmetadata-service/…/EntityProfileRepository.java• L72-106 openmetadata-service/…/TestCaseResolutionStatusRepository.java• L185-212
Security and governance boundary
Security is part of every service request. Authentication identifies the caller. Authorization decides whether the caller may perform an operation on a resource or field. Governance rules then limit what the caller may view or change across metadata and administration.
The platform security and governance page explains these controls in detail. This page gives the system view: the service establishes the security boundary before it serves resource actions, then passes caller and operation context into those actions.
Authentication and identity
The service supports native credentials and external identity providers. It accepts bearer tokens and browser authentication flows, maps provider claims to an OpenMetadata user, and maintains sessions, refresh, logout, bots, and impersonation state.
Impersonation has two separate meanings. The service keeps audit attribution for the bot that made a request, while a request-scoped security context records only an impersonation that passed authorization. Identity endpoints such as token, password, and logout actions reject an authorized impersonated session so it cannot mint a credential that outlives the grant.
MCP clients use the same platform security boundary. Administrators can list or revoke registered client grants, and a shared policy validates redirect schemes, hosts, loopback use, and native redirects before an OAuth client is accepted.
External sign-in also binds an email-first account to the provider subject that first established it. A later login with the same email and a different subject is rejected until an administrator transfers or clears the binding. Test Login performs the same account admission checks as live login without creating an account, so a successful protocol check means the resolved identity is allowed to sign in.
SAML settings preserve configured identity-provider signing keys for rollover. New settings must contain a currently valid trust anchor, and a response must meet the configured time, audience, destination, signature, and encryption rules before the service accepts it.
References: openmetadata-service/…/JwtFilter.java• L99-120 openmetadata-service/…/ImpersonationContext.java• L3-24 openmetadata-service/…/ImpersonationRestrictionFilter.java• L27-49 openmetadata-service/…/McpClientPolicy.java• L23-69 openmetadata-service/…/McpOAuthClientResource.java• L57-107 openmetadata-service/…/McpGrantTransaction.java• L20-59 openmetadata-service/…/EmailFirstUserProvisioner.java• L123-167 openmetadata-service/…/TestLoginAccountChecks.java• L32-128 openmetadata-service/…/SamlCertificates.java• L30-58 openmetadata-service/…/SamlResponseValidator.java• L67-137
Authorization and data protection
Roles, policies, teams, domains, personas, and resource conditions define access. Field-level view operations make the required permission depend on the fields a read returns. Row-level checks then remove items that a broad list permission does not permit.
The service applies the same view decision to direct reads, search, lineage, feeds, exports, and related references. It also masks PII, secrets, query evidence, and sensitive test data. Team grants are especially protected: adding roles, policies, or parent teams requires the proper administrative or edit permission and cannot be done from an impersonated request.
References: openmetadata-service/…/ViewOperations.java• L11-45 openmetadata-service/…/ViewPermissionFilter.java• L25-47 openmetadata-service/…/RuleEvaluator.java• L29-59 openmetadata-service/…/TeamGrantAuthorizer.java• L39-59 openmetadata-service/…/EntityUtil.java• L73-90 openmetadata-service/…/PIIMasker.java• L122-175
Governance approvals
Governance approvals turn a proposed metadata mutation into a visible review record before it reaches the source entity. The service records the proposed change, exposes a preview, routes review to authorized users, and applies or rejects the decision through the normal entity rules.
Review can decide changes one by one. Approval and rejection thresholds determine which changes are ready, while requester votes do not count. A later publication can make one change obsolete or conflict with a newer value. The service reports those per-change outcomes and applies only changes that still pass current validation.
References: openmetadata-service/…/ChangeRequestService.java• L69-99 openmetadata-service/…/ChangeSelection.java• L31-49 openmetadata-service/…/ChangeSelection.java• L51-89 openmetadata-service/…/ChangeApplyService.java• L67-119
Governance workflows
Governance workflows turn review and lifecycle decisions into durable task state. A workflow can wait for human input, apply an approved change, run an ingestion action, or move an entity through a governed lifecycle.
The workflow engine keeps process definitions, running instances, tasks, timers, variables, and results durable so a server restart can recover work. Variables use node and global namespaces so one task can pass context to the next without collisions. Approval tasks enforce vote thresholds, record whether a step was automatic, voted, partially approved, rejected, or overridden, and write that outcome after the workflow transaction commits.
When a configured approval step has no usable assignee, it can cascade from service owners to domain owners. Team expansion happens before the service decides that a step is empty, and the requester is removed so a change is not sent back to its proposer. This gives governance work a path to an accountable owner without weakening explicit assignee or administrator rules.
Workflows can also create and run the ingestion pipeline that matches a service and pipeline type. This connects a governance decision to the catalog refresh that makes the decision visible in metadata.
References: openmetadata-service/…/WorkflowHandler.java• L101-163 openmetadata-service/…/WorkflowVariableHandler.java• L35-67 openmetadata-service/…/UserApprovalTask.java• L179-220 openmetadata-service/…/UserApprovalTask.java• L645-672 openmetadata-service/…/OwnerCascade.java• L12-57 openmetadata-service/…/SetApprovalAssigneesImpl.java• L77-220 openmetadata-service/…/ApprovalTaskCompletionValidator.java• L13-21 openmetadata-service/…/ApprovalOutcomeRecorder.java• L25-46 openmetadata-service/…/CreateIngestionPipelineImpl.java• L56-84 openmetadata-service/…/WorkflowInstanceRepository.java• L41-90
Event and alert delivery
The service turns committed metadata changes into signals for work outside the database write. A lifecycle event describes an entity change. An alert subscription selects events, evaluates conditions, renders a message, resolves recipients, sends through configured channels, and records progress and health.
The alerting and event delivery page follows rule evaluation, target resolution, channel delivery, and recovery in more detail.
sequenceDiagram
participant C as Caller
participant R as Resource
participant D as Database
participant E as Event consumers
participant X as Alert destination
C->>R: Mutating request
R->>D: Validate and store
D-->>R: Commit
R-->>C: Successful response
R->>E: Lifecycle and response signals
E->>E: Match sources and conditions
E->>E: Render a safe notification
E->>X: Deliver notification
X-->>E: Delivery result
E->>D: Store progress and health
Entity and response signals
Lifecycle handlers are selected by entity type and event. A handler can run inline when its result must be ready before the operation ends, or after commit when work can be deferred. Deferred work has a durable retry path and does not change the source transaction when a downstream system fails.
Response handlers receive successful mutating HTTP actions after the server creates the response. This supports audit and integrations tied to an API action. It remains separate from lifecycle events and offset-based alert consumers. Sensitive entity fields are removed from stored change signals before alerts, audit, and event reads consume them.
References: openmetadata-service/…/ChangeEvents.java• L56-139 openmetadata-service/…/ChangeEventMasking.java• L28-61 openmetadata-service/…/EntityLifecycleEventDispatcher.java• L41-90 openmetadata-service/…/EntityLifecycleEventDispatcher.java• L459-487
Alert destinations and secrets
Alert destinations and user or team profile webhooks carry credentials that the platform must use without returning them to clients. The service binds each stored secret to its destination or profile owner, encrypts it with the server's Fernet keys at rest, decrypts it only for delivery, and masks it in responses and history.
A changed endpoint, token URL, or receiver list requires all related secrets again. Webhook delivery resolves valid configured endpoints, skips unusable receiver values, and treats redirects as errors rather than silently following them.
References: openmetadata-service/…/ConfigSecrets.java• L30-46 openmetadata-service/…/ConfigSecrets.java• L53-97 openmetadata-service/…/DestinationSecrets.java• L40-67 openmetadata-service/…/ProfileWebhookSecrets.java• L41-90 openmetadata-service/…/WebhookAddresses.java• L39-80
Alert progress and diagnostics
Alert consumers read committed change records by offset. Durable position, scheduling, destination health, diagnostics, and delivery counts let operators distinguish rule problems from scheduler, channel, recipient, or source lag.
The service reads destination health in batches and reports handled, failed, pending, successful, and lower-bound counts. An alert update converges its saved definition with its scheduled job after commit, so editing or enabling an alert does not leave its job out of sync.
References: openmetadata-service/…/AlertDiagnostics.java• L47-79 openmetadata-service/…/AlertDiagnostics.java• L108-160 openmetadata-service/…/AlertRecord.java• L23-55 openmetadata-service/…/EventSubscriptionRepository.java• L86-119
Runtime coordination
Runtime configuration defines the external systems and optional platform features that the service can use. It covers the database, search, authentication, authorization, event handlers, alerts, caches, object storage, secrets, workflows, AI, RDF, insights, and worker capacity.
The platform configuration management page explains how operators manage these settings. Startup establishes shared state before traffic reaches the API:
- Capture deployment settings and validate configuration.
- Initialize language, database, search, RDF, caches, and optional platform runtimes.
- Register repositories and load database-backed settings.
- Reconcile deployment settings before security reads them.
- Install authentication, authorization, limits, exception handling, and request cleanup.
- Register resources, event handling, schedulers, and background workers.
- Start alert delivery, distributed jobs, live feeds, indexing, insights, RDF work, and workflow services.
Database and worker capacity
The service separates request database work from subsystem work. Search rebuilds, RDF indexing and maintenance, alert consumers, workflow engines, insight runs, CSV jobs, application schedules, and other workers use bounded capacity so a slow worker cannot starve API traffic.
Distributed jobs use durable ownership, leases, heartbeats, and progress state. Application listeners clear request state before a long-lived scheduler thread starts a run and fill terminal run timings so a failed or stopped job still has a useful end state.
References: openmetadata-service/…/OpenMetadataApplication.java• L327-367 openmetadata-service/…/OpenMetadataApplication.java• L475-524 openmetadata-service/…/OmAppJobListener.java• L52-82 openmetadata-service/…/OmAppJobListener.java• L96-113 openmetadata-service/…/AbstractNativeApplication.java• L72-100
Scheduled jobs and recovery
Scheduled work carries out tasks that do not need to block the request path. It includes alert delivery, audit logging, search retry work, RDF rebuilding and maintenance, cache warmup, ingestion calls, insight processing, workflow execution, application runs, CSV import and export, context-file extraction, ontology library installation, and change-request recovery.
Startup recovery marks abandoned application and workflow work interrupted unless distributed ownership proves that another server still owns it. This prevents a restart from leaving user-visible work in a permanent running state.
References: openmetadata-service/…/OpenMetadataApplication.java• L384-390 openmetadata-service/…/OpenMetadataApplication.java• L496-524 openmetadata-service/…/OmAppJobListener.java• L96-113 openmetadata-service/…/WorkflowHandler.java• L151-163
Platform settings and health
System settings let administrators tune platform behavior without changing the service image. Settings stored in the database can be reconciled from deployment configuration and refreshed on a running cluster when another server, the CLI, or an administration job changes them.
The deployment source is captured before reload so the service can compare deployment intent with stored settings. This supports environment-backed settings, operations-file settings, database settings, and safe provider changes without treating the database's refreshed value as the deployment value.
Health and metrics show whether the request path and its main background systems remain usable. RDF projection health distinguishes durable source state from a derived view that needs replay, rebuild, compaction, or storage recovery.
References: openmetadata-service/…/DeploymentConfig.java• L30-69 openmetadata-service/…/DeploymentConfig.java• L90-121 openmetadata-service/…/SystemResource.java• L229-260 openmetadata-service/…/RdfProjectionStateResolver.java• L101-119
Schema migration flow
Server migrations move an existing installation to the current database and platform contract. They apply ordered schema changes and data repairs for MySQL and PostgreSQL, with durable step identity so an interrupted upgrade can resume without repeating completed work.
Migration work preserves the contracts used by settings, encrypted connection values, alerts, workflow data, ontology bindings, lineage edges, data contracts, and first-time setup. The current migration also moves webhook secrets from earlier storage forms to server-Fernet encryption and masks historical versions and change events that never send.
References: openmetadata-service/…/Migration.java• L69-100 openmetadata-service/…/Migration.java• L65-100 openmetadata-service/…/StoredWebhookSecrets.java• L50-58 openmetadata-service/…/WebhookSecretsMigration.java• L30-45 openmetadata-service/…/WebhookSecretsMigration.java• L53-105
Context Center and AI knowledge
Context Center stores reusable knowledge memories and links them to assets, source files or pages, related entities, and other memories. AI features use these memories as business context, while the service keeps ownership, visibility, evidence, review status, and retrieval signals separate from the source content.
The Context Center and AI knowledge page explains memory capture, retrieval, derivation, and review in detail. The platform view is that memory processing is an entity lifecycle with search, relationship, security, and background work at each stage.
Memory lifecycle
A context memory can be created directly or extracted from a Context Center source. It can be approved, kept as a draft, deprecated, superseded, invalidated, rejected, or archived. A memory may also cite a query as evidence, point to a primary asset, relate to other entities, and form a root or parent hierarchy.
Writes validate references and lifecycle transitions before they change durable state. Extraction work can derive glossary or ontology knowledge. A human edit to extraction-managed content changes ownership of that content to manual work so a later extraction does not overwrite it.
References: openmetadata-service/…/ContextMemoryRepository.java• L114-185 openmetadata-service/…/ContextMemoryLifecycle.java• L47-64 openmetadata-service/…/ContextMemoryReconciler.java• L96-119 openmetadata-service/…/MemoryReviewHolds.java• L40-47
Memory visibility
Memory visibility is a per-memory sharing rule in addition to normal resource policy. Private memories are owner-only. Shared memories use named users, teams, or domains. Entity and public memories are readable through the primary asset when the caller can view that asset.
The rule is applied on direct reads, list responses, global search, vector search, and history. Search indexes all memories, then filters documents by caller, anchor, visibility, and lifecycle status. Pending memories are shown to their owners and administrators, with extracted pending memories also visible to owners of the source document.
References: openmetadata-service/…/ContextMemoryVisibility.java• L106-135 openmetadata-service/…/ContextMemoryVisibility.java• L275-356 openmetadata-service/…/ContextMemorySearchVisibility.java• L117-180 openmetadata-service/…/ContextMemoryIndex.java• L141-200
Memory write and evidence boundaries
An ordinary user may create a memory for themselves and may point it only at entities they can view. Only an administrator or bot may assign another owner, claim file or page extraction provenance, open a conflict review, or approve a memory when review is required.
Query evidence is filtered independently of memory visibility. A caller who cannot view a cited query receives only its id and type. The same redaction applies to relationship changes in the memory's version history, so evidence cannot reappear through an older snapshot.
References: openmetadata-service/…/ContextMemoryWriteAccess.java• L37-48 openmetadata-service/…/ContextMemoryEvidenceAccess.java• L41-47 openmetadata-service/…/ContextMemoryEvidenceAccess.java• L106-119
Context file processing
Context files turn uploaded source material into searchable text and extracted knowledge. Processing runs outside the request path, records clear states from upload through extraction or failure, and resumes transient work after a server restart.
The service checks that each worker still owns the current file content before it writes. It uses conditional updates so a newer upload or human change wins over an older extraction. When extraction finds an existing fact from another document, reconciliation can reuse the existing memory and its review state rather than create a second fact.
References: openmetadata-service/…/ContextFileProcessingService.java• L41-47 openmetadata-service/…/ContextFileProcessingService.java• L154-185 openmetadata-service/…/ContextMemoryReconciler.java• L26-44
AI context assembly
AI context is a bounded view of an asset and its governed knowledge. It combines the asset description, tags, glossary terms, metrics, linked pages, lineage, observability, and type-specific structure such as table fields and joins. The service removes knowledge the caller cannot view and marks attached knowledge as stale when the asset or its data quality has changed.
Long knowledge is reduced to a relevant excerpt or a reference so one response cannot consume an unbounded model context. A concept context adds the visible assets and fields bound to a glossary term or metric. It also carries selected evidence from approved memories and viewable queries.
References: openmetadata-service/…/AIContextBuilder.java• L90-101 openmetadata-service/…/AIContextBuilder.java• L192-235 openmetadata-service/…/ConceptContextBuilder.java• L99-135
Persona context
Persona context is a shared, rule-based knowledge view for an AI assistant. An enabled persona selects assets and approved knowledge with saved search rules, enriches the selected assets with the requested context sections, and exposes a search scope that limits later discovery when rules opt into filtering.
The service validates saved filters against the active search engine and applies caller visibility again when it serves a shared document. Administrators and bots may rebuild the shared context. Other users must belong to the persona and receive a caller-filtered view. Shared source data may be cached, but authorization decisions are made for each caller.
References: openmetadata-service/…/PersonaContextAccess.java• L33-99 openmetadata-service/…/PersonaContextBuilder.java• L181-207 openmetadata-service/…/PersonaContextVisibility.java• L43-93 openmetadata-service/…/PersonaContextCache.java• L128-200 openmetadata-service/…/PersonaRepository.java• L300-315
Change checklist
When these files or sections are changed, remember to consider these:
- A new resource must keep collection registration, entity registration, repository mapping, operation mapping, masking, and cache invalidation aligned.
- A new or renamed field must keep API behavior, relationship storage, inherited fields, search mapping, event masking, lineage or RDF mapping when applicable, and change descriptions aligned.
- Search, lineage, aggregation, domain navigation, and private-field changes must keep direct visibility, node and edge filtering, hidden pipeline data, PII masks, private email references, explicit domain filters, and complete aggregation scopes aligned.
- Search or RDF changes must preserve source-of-truth ownership, post-commit or durable writes, rebuild cutover, live-mutation replay, locks, health state, storage backpressure, and the separation between live and rebuild capacity.
- Time-series profile, test-status, and ontology-binding changes must refresh every affected RDF asset projection after insert, update, delete, release change, or concept removal.
- Query-derived search records must keep source owners, tags, tier, and domains aligned with search access checks.
- Task list changes must keep the selected timestamp, cursor value, sort field, update bound, database keyset query, and search-reindex cursor model aligned.
- Task comment and resolution changes must lock current state, preserve post-commit events, maintain mention relationships, and avoid duplicate automatic resolution comments.
- Authentication and MCP changes must cover provider callbacks, verified identity claims, token and grant state, redirect policy, active persona, impersonation restrictions, and admin client revocation.
- Test Login changes must keep protocol identity resolution, account admission, self-signup domains, email verification, bot and deleted-user checks, and live-login behavior aligned without provisioning accounts.
- SAML changes must keep certificate parsing, rollover trust, encryption requirements, assertion time checks, audience and destination checks, and live versus dry-run settings aligned.
- Alert changes must keep current capabilities, historical buildability, source compatibility, condition matching, channel resolution, recipient isolation, secret restoration, scheduler jobs, offsets, diagnostics, and per-destination health aligned.
- Webhook changes must keep server-key encryption, target-change re-entry, profile and alert history masking, migration behavior, receiver validation, and redirect failure behavior aligned.
- Approval and workflow changes must keep proposed changes, per-change outcomes, conflicts, vote thresholds, automatic approvals, task records, variable namespaces, ingestion actions, process definitions, recovery state, and owner fallback behavior aligned.
- Startup changes must preserve the order between deployment capture, settings reconciliation, security registration, resource registration, projection setup, scheduler startup, worker startup, and optional RDF initialization.
- Migration changes must keep MySQL and PostgreSQL paths, step identity, idempotence, partial-run recovery, encryption state, alert seed data, lineage cleanup, workflow redeploy state, data contract state, and ontology binding state aligned.
- AI context changes must keep asset permissions, knowledge-item permissions, lineage filtering, approved-definition rules, content budgets, stale signals, persona membership, and shared-cache isolation aligned.
Important failure modes
| Trigger | Consequence | Guard |
|---|---|---|
| A metadata write commits but a search or RDF update fails | A derived view is stale while the database is current | Use post-commit work, durable retry, replay, or rebuild from committed state |
| A time-series profile or test status changes without refreshing its asset projection | RDF serves old profile or quality state | Refresh the affected entity after the time-series write or delete |
| An ontology concept or active release changes without re-projecting bound assets | RDF exposes stale concept bindings or inactive release members | Read affected bindings and active members and refresh the impacted assets |
| RDF live writes are accepted while the current migration is missing | The graph writer and reader use different payload rules | Require the current live-write protocol before RDF is enabled |
| An RDF rebuild promotes before live mutations are caught up | The new graph loses changes made during the rebuild | Journal live writes, replay them, and promote only after the journal cursor is caught up |
| An RDF rebuild loses its lease or fails its success threshold | A hollow or abandoned graph becomes the serving graph | Validate the build before promotion and leave the prior serving dataset active on failure |
| A search query or aggregation names a private user field | A caller can infer or retrieve an email through search even when the hit is masked | Refuse private field references and remove private fields from non-privileged hits |
| A query cost record omits the source query's access fields | A caller can see cost data for a query outside the caller's scope | Lift owners, tags, tier, and domains into the indexed record |
| A global domain filter narrows a task, team, or permission list | Work or access data disappears under a navigation preference | Exclude cross-domain work and administration surfaces from the navigation filter |
| A task cursor uses a different timestamp from the selected sort field | Pages skip tasks, repeat tasks, or reject a valid next request | Bind the cursor to the selected timestamp and restart update-time refreshes with an update bound |
| A cached persona document contains a caller-filtered view | One user's restricted context becomes visible to other persona members | Cache shared source data only and apply authorization during each caller render |
| A destination target changes while masked secrets are restored | Stored credentials are sent to a target chosen without proof of ownership | Require every secret again when an endpoint, token URL, or receiver list changes |
| A stored alert or profile history includes a secret | Alerts, audit records, or API reads expose credentials | Encrypt current secrets and mask destination and profile history on reads and migrations |
| An alert definition and its scheduled job diverge | An enabled alert does not deliver, or an old job keeps delivering | Converge the job after the entity commit and retain durable position and health rows |
| An approval task completes below its vote threshold | A governed change is treated as decided too early | Validate thresholds before completion and record the outcome after commit |
| Owner fallback includes only the requester or a team with no users | A governance task is self-assigned or has no actionable assignee | Remove the requester and cascade through expanded service then domain owners |
| A change request applies after a field changed | Review publishes a value over a newer value | Re-read current state, split conflicts, and apply only still-valid operations |
| A workflow worker keeps stale request state | A later run uses an old app configuration or caller context | Clear per-request state before each scheduler run and recover abandoned work |
| An impersonated request reaches an identity endpoint | A temporary grant creates a credential that outlives the grant | Block identity endpoints using the request-scoped validated impersonation state |
| A Test Login reports success for a bot, deleted user, unverified account, or disallowed new user | Administrators approve a security setting that live login would reject | Run read-only account admission checks after protocol identity resolution |
| All configured SAML signing certificates are expired or not yet valid | New SAML settings have no usable trust anchor | Reject the new configuration while retaining configured rollover keys for runtime validation |
| A SAML response is clear text when encrypted assertions are required | An assertion bypasses the configured protection level | Check the response structure before normal assertion validation |
| A context file worker writes after a newer upload becomes current | Old extracted text or memories overwrite the current source | Check the current content id and use conditional updates before each state change |
| A migration encrypts only current webhook rows | Old versions or events still expose credentials | Rewrite current rows, versions, and stored change events in one idempotent step |