optable-targeting new features: non-blocking early network call + hid + id5 - #4601
Open
justadreamer wants to merge 56 commits into
Open
optable-targeting new features: non-blocking early network call + hid + id5#4601justadreamer wants to merge 56 commits into
justadreamer wants to merge 56 commits into
Conversation
return early from the hook if (hasRawAuctionRequestHook && hasBidderRequestHook) - the new mode
random is 0-99, percentage is 0-100. enrich when random < (strictly less than) percentage. so if we specify percentage 0 we never enrich, if we specify percentage 100 we always enrich.
…ntage property is specified and it's value is 100%
The account config node is deserialized with the prebid mapper, which uses SNAKE_CASE, so the unannotated fields bound to enrich_web and enrich_app while the documented account keys are enrich-web and enrich-app. Per-account overrides of both were silently dropped and the global value kept.
…change Core changed ExecutionPlan.endpoints key type from Endpoint to HookHttpEndpoint. Map.get accepts Object, so the stale lookup kept compiling but always returned null against the EnumMap: the module read a bidder-request hook timeout of 0, so the targeting API call inherited only the raw-auction-request stage budget (50ms) instead of the configured 500ms and timed out on every auction.
… resolving id5Signature
…re not participate in targeting enrichment process.
The test named for the NOBID branch stubbed a bid response that has a bid, so with non-empty targeting the validator returned SUCCESS and the test exercised the full enrichment chain instead of the signature-only one.
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Type of changes
What's the context?
Two related improvements to the
optable-targetingmodule: the Optable API call no longerblocks the auction pipeline, and the Targeting API request now carries the parameters needed
for mobile in-app resolution (hid, bundle/ver, ID5).
Latency: non-blocking early network call
The API call starts at
raw-auction-requestand runs in parallel with the rest of the auction.The result is consumed per bidder at
bidder-request, where enrichment is actually injected,so the pipeline never waits on the network.
Traffic controls
enrichment-percentage/bidder-enrichment-percentages: sampling rate (0-100) applied perbidder. A bidder with no entry falls back to the account default;
0disables it entirely.enrich-web/enrich-app: select which traffic sources are enriched.Sampling applies to the split plan only. The legacy
processed-auction-requesthook enrichesthe whole bid request before bidders split out, so it cannot sample per bidder.
Targeting API request parameters
hid-prefixes(new config entry): comma-separated id prefixes to emit ashid=, in thegiven order (e.g.
"e,p,i6,a,g,c"). Independent ofid-prefix-order, and selective ratherthan merely ordering: only the listed prefixes are sent as
hid.bundle/ver: emitted frombidRequest.appwhen present.id5_signaturein: read fromuser.ext.optable, forwarded as a Targeting API queryattribute alongside email/phone/zip/vid.
id5_signatureout: returned inext.prebid.passthrough.optable.id5_signature. PBScannot persist the signature between requests, so it round-trips through the client, which
caches it and replays it on the next auction.
Backwards compatibility
No breaking changes. The
processed-auction-requesthook is retained and detects whether bothnew hooks are present in the execution plan: if so it passes through immediately, otherwise it
falls back to the previous synchronous behavior. The legacy fragment can therefore be left in
place during migration without negating the latency benefit.
Configuration (recommended)
The
bidder-requestgroup timeout bounds the wait on the API call, so it must accommodateround-trip latency to the Optable edge. The
raw-auction-requesttimeout only covers dispatch.To migrate, drop the legacy fragment:
Test plan
per-bidder sampling (including a bidder pinned at 0%), ad server targeting keywords,
ID5 signature passthrough, and the legacy execution plan
Quality check
cc: @jrosendahl-opt @softcoder594