CertSafari
    Databricks Certified Machine Learning Associate· Lessons

    Domain 4 · Lesson 48/48

    Traffic splitting across served models on a Model Serving endpoint

    Split data between endpoints for realtime interference

    15 min read
    2% of exam
    5 sources
    Published 22 Oct 2026
    Docs as of 17 Oct 2026

    What you will be able to do

    • Configure one Model Serving endpoint with several served entities and a traffic_config that routes a percentage of requests to each
    • Change the traffic split on a live endpoint so a new model version takes over gradually, with no downtime and no client changes
    • Send test requests to one served model through its own invocations path, outside the traffic split

    Key concept

    traffic_config — The part of an endpoint's configuration that lists routes. Each route names one served entity and gives the percentage of the endpoint's requests that entity receives, so a single endpoint URL can spread live traffic across several model versions.

    1.Why one endpoint serves more than one model

    Testing a new model offline is not the same as seeing how it behaves on real requests. A held-out dataset shows you how the model scores. Live traffic shows you how it performs against the inputs and business outcomes production actually produces. Mosaic AI Model Serving lets one real-time endpoint host several models at once and split incoming requests between them. Because the endpoint URL stays the same, the calling application never knows which model answered.

    The usual case is a Champion and a Challenger. Aliases in Unity Catalog mark which registered version is the current Champion and which one is competing for the role (see Model aliases (Champion / Challenger)). Serving both versions behind one endpoint lets you compare them online before you move the Champion alias. The MLOps workflow describes these as longer running online comparisons, either an A/B test or a gradual rollout. You don't have to replace the production version to try a new one: the incumbent keeps serving most requests while the new version gets a slice.

    The models on one endpoint have to be the same kind. An endpoint can hold one of three kinds, but not a mix:

    • Custom models: models you registered in Unity Catalog, each served with its own workload size and scale-to-zero setting.
    • Foundation Model APIs provisioned throughput models: Databricks-hosted foundation models such as system.ai.meta_llama_v3_1_70b_instruct, sized by a minimum and maximum provisioned throughput rather than a workload size.
    • External models: models run by an outside provider such as OpenAI or Anthropic, configured with the provider name, a task type and an API key kept in a secret.

    A custom model and an external model can't share an endpoint. If you split traffic across several external models, they must all have the same task type, such as llm/v1/chat, and each needs a unique name.

    Checkpoint 1 of 7· Check yourself

    A team serves its Champion, a custom model registered in Unity Catalog, on a real-time Model Serving endpoint. They want to send 10% of live traffic to a Challenger that is an external model (an OpenAI chat model) and compare the two online. How should they set this up?

    Sources12

    2.Configuring served_entities and traffic_config routes

    A split endpoint has two parts. The first is served_entities, which lists the deployment units: each one is a single model version with its own compute settings. The second is traffic_config, whose routes decide how requests are spread across those entities. A served entity holds exactly one model version. To serve two versions you declare two entities, each with its own entity_name, entity_version, workload size and scale-to-zero setting. You can't put two model artifacts in one entity and expect the endpoint to alternate between them.

    Two served entities on one endpoint: 'current' hosts version 1 of model-A, 'challenger' hosts version 1 of model-Bjson
          "served_entities":
          [
             {
                "name":"current",
                "entity_name":"catalog.schema.model-A",
                "entity_version":"1",
                "workload_size":"Small",
                "scale_to_zero_enabled":true
             },
             {
                "name":"challenger",
                "entity_name":"catalog.schema.model-B",
                "entity_version":"1",
                "workload_size":"Small",
                "scale_to_zero_enabled":true
             }
          ],

    Each route links to an entity by name. A route's served_model_name must match the name you gave a served entity, not the Unity Catalog model name. That's why giving entities short, meaningful names like current and challenger is worth the effort: the routes, the endpoint UI and the per-model query path all use them. Once an endpoint has more than one served model, a traffic configuration is required. Between them, the routes account for all of the endpoint's traffic. In this example they add up to 100: current gets 90% and challenger gets 10%.

    The traffic_config sent with the create request: 90% of requests to 'current', 10% to 'challenger'json
          "traffic_config":
          {
             "routes":
             [
                {
                   "served_model_name":"current",
                   "traffic_percentage":"90"
                },
                {
                   "served_model_name":"challenger",
                   "traffic_percentage":"10"
                }
             ]
          }
    Fields that set up a traffic split, and what each one controls
    FieldWhere it sitsWhat it controls
    nameEach entry in served_entitiesThe served entity's name inside the endpoint, which routes refer to
    entity_name / entity_versionEach entry in served_entitiesWhich Unity Catalog model and version this entity hosts, for example catalog.schema.model-A version 1
    workload_size / scale_to_zero_enabledEach entry in served_entitiesCompute for that entity only, so the challenger can be sized separately from the incumbent
    routestraffic_configThe list of routes that divide the endpoint's traffic
    served_model_name / traffic_percentageEach entry in routesWhich served entity the route targets and what share of requests it receives

    You set the initial split when you create the endpoint, using either the API or the UI. The API takes the full configuration above in POST /api/2.0/serving-endpoints. In the Serving UI, every served entity you add has its own field for the percentage of traffic to route to it, and Add served entity adds the next one. For a canary release of a new fraud model at 20%, you would declare the incumbent version and the new version as two served entities, then add two routes with 80 and 20.

    Checkpoint 2 of 7· Fill the gap

    This traffic_config sends 90% of requests to the served entity named current and 10% to challenger. Which field name completes the first route's target?

          "traffic_config":
          {
             "routes":
             [
                {
                   " ? ":"current",
                   "traffic_percentage":"90"
                },
                {
                   "served_model_name":"challenger",
                   "traffic_percentage":"10"
                }
             ]
          }

    Checkpoint 3 of 7· Exam question

    A team wants to canary-release a new fraud model version on their live Model Serving endpoint, sending only 20% of production requests to it while the incumbent version keeps handling 80%. Both versions are already registered in Unity Catalog. How should they configure the single endpoint to achieve this split?

    Sources3415

    3.Shifting the split on a live endpoint

    You change the split by updating the endpoint's configuration, not by replacing the endpoint. Send PUT /api/2.0/serving-endpoints/{name}/config with the same served_entities and a traffic_config that has the new percentages. In the UI, open the endpoint from the Serving tab and click Edit configuration. The endpoint name, its URL and its served entities stay the same, so callers notice nothing.

    The traffic_config part of an update-config request, moving the split to 50/50json
       "traffic_config":
       {
          "routes":
          [
             {
                "served_model_name":"current",
                "traffic_percentage":"50"
             },
             {
                "served_model_name":"challenger",
                "traffic_percentage":"50"
             }
          ]
       }
    }

    The update causes no downtime. Model Serving keeps the existing configuration running until the new one is ready, so requests keep arriving under the old percentages until the new routes take over. That is what makes a gradual rollout safe. Deploying a new version in a single step means it takes all traffic at once (see Updating a live endpoint to a new model version). With a split you raise its share in stages instead: 10% first, then 50%, then 90%. You check the results between each step, and if a stage goes badly you can move the percentage back down.

    Each step should be backed by evidence from the endpoint itself. Model Serving can collect inference tables that record request and response data for an endpoint, and those tables are what you compare the two versions on. Once the challenger has earned the role, reassigning the Champion alias finishes the promotion. The traffic split was how you ran the comparison.

    Checkpoint 4 of 7· Check yourself

    Midway through a gradual rollout, you send PUT /api/2.0/serving-endpoints/{name}/config to move the challenger from 10% to 50% of traffic. What happens to requests that reach the endpoint while the update is in progress?

    Checkpoint 5 of 7· Exam question

    An endpoint is already live serving a champion and challenger model at a 50/50 traffic split. After two weeks, the challenger's business metrics look strong, so the team wants to shift the split to 90% challenger and 10% champion without any client-side changes or downtime. What is the correct way to do this?

    Sources12

    4.Querying one served model directly

    Every served entity behind an endpoint can be called directly. A normal request to the endpoint goes through traffic_config and lands on whichever model the split picks (see Querying a real-time serving endpoint for the request formats). To reach one particular entity, add its name to the path:

    Per-model invocations path that bypasses the traffic splittext
    POST /serving-endpoints/{endpoint-name}/served-models/{served-model-name}/invocations

    Two things make this path useful. The request body has the same format as a normal endpoint query, so a test payload you already have works unchanged. And the traffic settings are ignored: if you send every request to /serving-endpoints/multi-model/served-models/challenger/invocations, the challenger answers every one, while production callers on the main endpoint URL still get the 90/10 split. That's how you can smoke-test a newly added entity on the real serving infrastructure without touching its percentage. Scoring an exported copy offline wouldn't test the endpoint at all.

    Checkpoint 6 of 7· Fill the gap

    A new served entity named challenger sits on the multi-model endpoint, which splits traffic 90/10. You want to send smoke-test requests to that entity only, without touching the split. Which placeholder completes the path you call?

    POST /serving-endpoints/{endpoint-name}/served-models/ ? /invocations

    Checkpoint 7 of 7· Exam question

    Before adding a newly trained model version into an endpoint's 80/20 traffic split, an ML engineer wants to send a handful of manual test requests to only that new version to confirm it responds correctly, without affecting the live production split at all. How can this be done?

    Sources1

    Sources

    (5)

    Every claim above is drawn from one of these pages, quoted as it was written on the date shown.

    1. 1.
      “Serving multiple models from a single endpoint enables you to split traffic between different models to compare their performance and facilitate A/B testing.”
      ↩︎ Why one endpoint serves more than one model
      “serve different versions of a model at the same time, which makes experimenting with new versions easier”
      ↩︎ Why one endpoint serves more than one model
      “You can not serve different model types in a single endpoint.”
      ↩︎ Why one endpoint serves more than one model
      “as long as they all have the same task type and each model has a unique name”
      ↩︎ Why one endpoint serves more than one model
      “50% of the traffic to gpt-4 provided by OpenAI”
      ↩︎ Why one endpoint serves more than one model
      “The served entity, current, hosts version 1 of model-A and gets 90% of the endpoint traffic”
      ↩︎ Configuring served_entities and traffic_config routes
      “You can also make this update from the Serving tab in the Databricks UI using the Edit configuration button.”
      ↩︎ Shifting the split on a live endpoint
      “While querying the individual served model, the traffic settings are ignored.”
      ↩︎ Querying one served model directly
      “The request format is the same as querying the endpoint.”
      ↩︎ Querying one served model directly
      “then all requests are served by the challenger served model.”
      ↩︎ Querying one served model directly
      “While querying the individual served model, the traffic settings are ignored.”
      ↩︎ Exam trap 3
      “You can not serve different model types in a single endpoint.”
      ↩︎ Exam trap 4
      “For example you can not serve a custom model and an external model in the same endpoint.”
      ↩︎ Checkpoint
      “You can also update the traffic split between served models.”
      ↩︎ Prediction
    2. 2.
      “longer running online comparisons, such as A/B tests or a gradual rollout of the new model.”
      ↩︎ Why one endpoint serves more than one model
      “Model Serving executes a zero-downtime update by keeping the existing configuration running until the new one is ready.”
      ↩︎ Shifting the split on a live endpoint
      “Model Serving and data profiling allow you to automatically collect and monitor inference tables that contain request and response data for an endpoint.”
      ↩︎ Shifting the split on a live endpoint
      “Model Serving executes a zero-downtime update by keeping the existing configuration running until the new one is ready.”
      ↩︎ Exam trap 2
    3. 3.
      “Named deployment unit inside an endpoint that represents a specific model with its compute configuration that can receive routed traffic.”
      ↩︎ Configuring served_entities and traffic_config routes
      “Traffic configuration is required for endpoints with more than one served model.”
      ↩︎ Configuring served_entities and traffic_config routes
      “Specification for what percentage of traffic to an endpoint should go to each model.”
      ↩︎ Key concept
      “Named deployment unit inside an endpoint that represents a specific model with its compute configuration that can receive routed traffic.”
      ↩︎ Exam trap 1
    4. 4.
      “A list of routes for traffic distribution. Each route contains served_model_name and traffic_percentage.”
      ↩︎ Configuring served_entities and traffic_config routes

    Ready to test yourself?

    Practise the 7 questions on this subdomain.

    Spotted a mistake, or was something unclear? Tell us.