MicroStrategy dataset identity
The dataset_identity setting decides what one DataHub dataset entity stands for in the MicroStrategy connector. The default, per_dashboard, is the historical behaviour and is unchanged; per_report is opt-in. This note describes where the two diverge.
The problem
A MicroStrategy report (object type 3: grid report subtype 768, intelligent cube 776, super cube 779) is a catalog object in its own right, filed in its own folder. Dossiers and Report Services documents embed it as a dataset. Under per_dashboard the dataset entity is keyed by the dashboard that embeds it, so a report used by N dashboards becomes N dataset entities with the same name and the same schema. A report used by several dashboards therefore becomes several dataset entities. With extract_reports: true the same report is also emitted as a chart (subtype Report) plus a report-scoped source dataset, which doubles it again. Users do not navigate by "dataset or dossier"; they look for the report and its lineage.
Scheme per_dashboard (default)
- Dashboard dataset URN name:
<project id>.<dashboard id>.<dataset id>;qualifiedNameis the same string. One entity per (dashboard, dataset) pair. - With
extract_reports: a chart<project id>.<report id>(subtypeReport) plus a dataset<project id>.<report id>.<source id or "source">holding the report's objects. - Charts (
ChartInfo.inputs), documentdatasetEdgesand dossierdatasetEdgesall point at the dashboard-scoped dataset; a dashboard that depends on a report links to the report chart throughchartEdges. - Warehouse lineage is attached per dashboard-scoped dataset, so a shared report's SQL is parsed once per dashboard.
Scheme per_report
- Dataset URN name:
<project id>.<report id>, where the report id is the dataset's own MicroStrategy object id (lowercased; the platform instance and env are applied exactly as before).qualifiedNameis the same string. Exactly one entity per report per project, however many dashboards use it. Datasets that dashboards embed are emitted whileextract_cubesis on (the default), whether or notextract_reportsis on; withextract_cubesoff only the datasets the report pass registers are emitted. - Name: the report's name as the dashboard definition carries it (which is the report object's name), or the report object's name when the report pass sees it first. Subtype as before:
Cubefor subtypes 776/779,MicroStrategy Datasetotherwise. - Browse path and container: the report's own folder ancestry, taken from the report pass's search hit when the report pass registered it and otherwise from the object lookup (
GET /api/objects/{id}?type=3), with the predefined-folder relabelling the connector already uses for dataset folders. When that ancestry is unavailable, or is a personal folder, the dataset falls back to the first dashboard's folder, or the project container for a report seen only by the report pass. - Schema:
availableObjectsfrom the report's own definition when the report pass fetched it (extract_reportswithextract_report_definitions), keeping dashboard fields it lacks so chart fields still resolve; otherwise the first dashboard-dataset definition seen for the report. Derived metrics, metric expressions and column groups accumulate on the one entity from every dashboard that uses it, and the report pass adds the report's own derived metrics whenextract_derived_metricsis on. - Warehouse lineage is settled once a SQL view parses to at least one upstream table (a dossier SQL view, a document's report instance read through
_report_sql_cache, or the report pass'sextract_report_sql_lineageread); later sightings of the same report then neither create a report instance (an execution) nor re-parse. A view that parses to no upstream tables does not settle it, so a later sighting tries again, and when the report pass changes the schema so the field lineage already attached no longer matches, that lineage is dropped and the report is read again. The report instance SQL cache is shared withper_dashboardand is unchanged. - Ownership: with
ingest_owneron, the report object's owner is emitted as the dataset's technical owner, since theReportchart that used to carry it is not emitted (dashboard-scoped datasets have never carried ownership). - What links to it: every dossier visualization that reads the report (
ChartInfo.inputs/inputEdges/inputFields, withextract_chartsandextract_lineageon), every document'sdatasetEdgeswhenemit_document_dataset_edgesis on (the default), and dossierdatasetEdgeswhenemit_dashboard_dataset_edgesis on. The lineage therefore readswarehouse table -> report dataset -> every chart and dashboard that uses it, and the dataset page lists every downstream dashboard. - Custom properties record
microstrategyReportId,microstrategyDashboardCountandmicrostrategyDashboardIds(the dashboards that use the report, in the order seen), plus the report definition's prompt count, filter flag and source when the report pass read the report definition from the API (a definition rebuilt from the search result does not record them). - Emission happens once per project after the dashboard and report passes, so the entity carries everything learned about the report in that run; if a pass raises, the datasets registered so far are emitted before the error propagates, and a dataset whose emission fails is skipped and reported as a failure, so stale-entity removal is skipped for that run, while the rest are still emitted. Edges emitted earlier in the run point at the URN that is emitted later; DataHub does not require the target to exist first.
extract_reports under per_report
The chart (subtype Report) and the report-scoped source dataset are not emitted. Keeping the chart only for ChartUsageStatistics would keep a duplicate of the report for one aspect, so report usage is emitted as DatasetUsageStatistics on the report dataset instead (uniqueUserCount and userCounts; totalSqlQueries is left unset because the Platform Analytics count is report executions, not SQL queries), keyed by the same object GUID, for every report dataset emitted, not only those the report pass saw, when extract_usage_statistics is on.
An independent report (no dashboard uses it; it needs both extract_reports and extract_independent_reports: true) is the same single dataset entity, with its schema from its definition and its own folder, and no chart. A report both passes see is one entity: the dashboard pass creates it, the report pass upgrades its schema and properties. The dashboard-to-report chartEdges that per_dashboard emits from dependencies have no target under per_report; the dashboard's visualizations and dataset edges carry the link instead.
Migration
Switching schemes changes every dataset URN, so the first run after switching emits a new set of dataset entities and, with stateful ingestion, soft-deletes the old ones as stale. Steps for a tenant on per_dashboard today: (1) set dataset_identity: per_report; (2) raise stateful_ingestion.fail_safe_threshold for that run, because the number of entities that disappear exceeds the default percentage whenever datasets are a sizeable share of the ingested entities (every dataset URN changes, plus every report chart when extract_reports is on); (3) run; (4) restore the threshold. Without stateful ingestion the old entities remain and must be deleted by hand. Editable metadata (descriptions, owners, tags, terms) on the old dataset entities is not carried over.
Counters
reports_deduplicated counts each additional dashboard that embeds a report already registered in the project (a report used by three dashboards counts two); the report pass does not add to it. report_datasets_emitted counts the dataset entities emitted under per_report.
Limitations
- A report whose definition cannot be fetched keeps the first dashboard-dataset definition as its schema; a report seen only by the report pass with a failed definition fetch is emitted with an empty schema, as the report-scoped dataset would have been.
- Prompted reports: a report instance may fail to execute for SQL (HTTP 406), so such a report gets no warehouse lineage from the report pass or the document path, exactly as before; a dossier's SQL view can still supply it.
- Cubes have no report SQL view; their warehouse lineage comes only from dossier SQL views, as before.
- A dossier's SQL view reflects the dossier's own view filters, so the lineage attached is that of the first dossier that parsed; a second dossier joining extra tables for a filter is not merged in.
- A dashboard dependency on a report that is not among the dashboard definition's datasets is not linked under
per_report(underper_dashboardit linked to the report chart). - The report's source cube (
dataSourcein the report definition) is recorded as a property, not emitted as a separate upstream dataset.