Building and Maintaining Visier DB: One Cached Copy, Security, and Engineering Discipline

Back to the Engineering Blog index Visier Developer Docs

In Part 1, we explored Visier’s subject- and time-centric data model. In Part 2, we looked at the Event Stream Loader, Visier DB’s temporal engine, and how we model metrics and cohorts.

In this final part, we’ll focus on three areas that make the system sustainable over time:


One Cached Copy Architecture and Security

Visier’s analytics architecture is built around a managed cached copy of source data.

Source systems remain the systems of record. Visier ingests from those systems, applies the analytic model, and maintains a cache that is optimized for time-aware analytics. The goal is to give customers consistent analytics while preserving a clear boundary between source data and Visier’s analytic representation.

At a high level, we:

One Cache Boundary, Multiple Internal Representations

When we say one cached copy, we do not mean there is literally only one physical file, table, or internal representation of data inside Visier. The system may store data in different formats for different operational reasons, such as flat files, derived views, or index-like structures used for query performance.

The important boundary is architectural: Visier as a whole behaves like one managed cached copy of the source data. Internal representations are implementation details inside that cache. They are not separate downstream sources of truth with their own business semantics, security definitions, or governance lifecycle.

That cache has two important properties:

All analytics, exports, and downstream experiences operate over this managed cached copy.

Visier architecture showing source systems flowing through ingestion and modeling into one modeled cached copy, with security and governance inherited by downstream consumers

Figure 1: Visier’s one cached copy architecture treats Visier’s analytic data layer as a managed cache boundary, while supporting multiple downstream consumers.

Why One Cached Copy?

The one cached copy approach has several advantages.

  1. Consistent semantics
    • There is a single, canonical semantic model for each subject and its history.
    • Business logic, such as promotion rules and cohort definitions, is defined once at the model level.
  2. Security applied consistently
    • Row- and column-level security policies are expressed over the modeled data.
    • Any view or export that runs against Visier DB inherits those rules.
  3. Clear cache lifecycle
    • Internal performance structures can be recreated because they are part of the cache, not independent records of truth.
    • When data must be removed, invalidated, or reloaded, the system can reason about the cache as one managed boundary.
  4. Reduced governance complexity
    • In “many-copy” models, each derived dataset or cube may need its own policy configuration and lifecycle.
    • In Visier’s one cached copy model, the modeled analytic layer is governed consistently regardless of how the data is accessed.

This does not mean the one cached copy architecture is the only mechanism for data governance. Other controls, such as bring your own key (BYOK) and same-jurisdiction storage, address complementary governance and compliance requirements. The cache-copy model is specifically about preserving source-of-truth semantics, avoiding unmanaged analytic copies, and making cache deletion and refresh a first-class part of the architecture.


Test Automation and Code Quality

The technical decisions we’ve described (temporal modeling, event streams, and one cached copy architecture) introduce significant complexity. To evolve such a system safely, we depend heavily on test automation and disciplined code review.

Heavyweight Test Automation from the Start

From the early days:

These tests have several important characteristics.

Table-In / Result-Out

Tests are often structured around specific input tables and expected analytic results:

This style keeps tests close to the behavior users depend on, rather than only checking internal implementation details.

Business-Meaningful Tests

Good tests encode clear business requirements. They should be understandable and verifiable by humans, not just snapshots of internal engine behavior. For an analytics engine, that means tests should make it clear what business question is being asked and what answer is expected:

That framing matters because the engine’s internals can change over time, but the business contract must remain stable.

A Tiered Test Strategy

We use different test tiers for different kinds of risk.

At the lowest level, unit tests cover core parts of the engine logic. These focus on business requirements such as:

At the next level, integration tests verify how the core engine logic works with the rest of the platform. These tests cover interactions such as:

At the highest level, end-to-end tests cover API endpoints and UI components working together. These tests run in two important contexts:

In addition to these functional tiers, we also test non-functional aspects of the system, including:

This level of coverage means:


Third-Party Libraries vs. Building In-House

Finally, a word about dependencies. Visier uses open-source and third-party libraries, but cautiously, especially for components in the critical path.

What We Look For in Third-Party Libraries

Key considerations include:

Decision framework for choosing between a third-party library and building in-house for critical analytics infrastructure

Figure 2: For critical analytics infrastructure, the build vs. buy decision depends on strategic importance, maintainability, responsiveness, quality, and control.

In one positive third-party library experience, we saw:

In a historical example from the other direction, roughly a decade ago, we had a critical third-party OLAP dependency that no longer fit our requirements. This is not meant as a current assessment of any specific project or maintainer group. At the time, for the specific critical-path use case we had, we found:

When We Decided to Build Our Own Engine

That historical experience with a critical third-party OLAP engine eventually led to a pivotal decision:

This shift:

The broader lesson:

For components that are central to your differentiation and hard to swap out, relying on a dependency whose roadmap, release cadence, or design goals no longer match your requirements is risky. Owning that technology can be the better long-term choice.


Closing Thoughts

Across this three-part series, we’ve covered:

  1. Why analytics breaks under change and how a subject- and time-centric model helps.
  2. How event-driven ingestion and a temporal, object-based engine (Visier DB) support rich metrics and cohorts.
  3. How a one cached copy architecture, strong test automation, and careful decisions about third-party dependencies make the system sustainable over time.

Taken together, these decisions allow Visier to:

If you’d like a deeper dive into areas such as the internal representation of cohorts, the details of our temporal join algorithms, or specifics of our security model, those would be natural next steps for a future article.

Return to the Engineering Blog index for the latest posts.