Bridge — Java Config Model Compilation to C++ Proton Config Subscription

Declarative application schemas (schemas/*.sd and services.xml) are compiled in Java by config-admin (vespa/config-model) and consumed live by C++ content nodes in content-nodes (vespa/searchcore) via typed .def config subscriptions (vespa/config + vespa/configgen).

Side A — Java Config Model Producer (vespa/config-model)

  • Anchor classes: vespa/config-model/src/main/java/com/yahoo/vespa/model/content/engines/ProtonEngine.java and com/yahoo/schema/derived/DerivedConfiguration.java
  • Compiles each .sd schema into derived config producers (AttributesConfig, IndexschemaConfig, RankProfilesConfig, SummaryConfig, ProtonConfig).
  • Each config producer is addressed by a hierarchical configId (e.g., content/search/cluster.music/0) and served by vespa/configserver.

Wire Protocol — .def Schema & JRT Config Subscription

  • Shared .def files in vespa/configdefinitions/ and vespa/searchcore/src/vespa/searchcore/config/ are compiled by vespa/configgen into both Java *Config.Builder classes and C++ vespa::config::*Config classes.
  • Node-local vespa/config-proxy caches payloads over JRT RPC and delivers synchronized config generations to local subscribers.

Side B — C++ Proton Consumer (vespa/searchcore)

  • Anchor classes: vespa/searchcore/src/vespa/searchcore/proton/server/proton.cpp and documentdb_config_manager.cpp
  • DocumentDBConfigManager subscribes to the per-doctype config bundle via config::ConfigSubscriber.
  • When a new application generation arrives, Proton diffs the old and new DocumentDBConfig snapshots and applies online schema changes (new attributes, updated rank profiles) or triggers background reindexing without restarting the C++ daemon (see schemas-app-packages).