Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Site.content.data for a specific [auction] #7651

Closed
patmmccann opened this issue Nov 2, 2021 · 14 comments · Fixed by #8338
Closed

Site.content.data for a specific [auction] #7651

patmmccann opened this issue Nov 2, 2021 · 14 comments · Fixed by #8338

Comments

@patmmccann
Copy link
Collaborator

patmmccann commented Nov 2, 2021

Type of issue

Right now https://docs.prebid.org/features/firstPartyData.html describes how to set ad unit specific first party data, but not how to set seller defined contextual segments along the lines of #6057 that would normally go in site.content.data

Ad-unit specific first party data might be valid if there is a video unit on the page and the contextual segments are about the video, not the text. It also might be relevant on various single page experiences with multiple types on content that fall into different groupings.

Possible solution

One solution is we set it on imp.ext.data.content . The issue here is adapters would all have to start looking for this data in a second place.

eg

imp": [{
		"id": "Video_Individual_Autoplay_SOff",
		"ext": {
			"data": {
				"adserver": {
					"name": "gam",
					"adslot": "/18190176,83852415/AdThrive_Video_Individual_Autoplay_SOff/53237591208f222c05b9a652"
				},
				"jwTargeting": {
					"playerID": "9F5pbYIL",
					"mediaID": "9F5pbYIL"
				},
				"content": [{
					"name": "www.iris.tv",
					"segment": [{
						"id": "ic_4146983"
					}, {
						"id": "ic_1670398"
					}, {
						"id": "ic_4260700"
					}, {
						"id": "ic_9534888"
					}, {
						"id": "ic_9954675"
					}, {
						"id": "ic_3393155"
					}],
					"ext": {
						"segtax": 501
					}
				}],

Alternative solution

It seems publishers might already have a workaround, setting the global fpd with these extra segments and then quickly unset it so other units aren't affected. Should we develop a utility function to more easily support this concept of temporary global fpd?

@gglas
Copy link

gglas commented Nov 8, 2021

Discussed today, @bretg will look into and discuss the best way to handle this. Could be that we feature this in a second place.

@bretg
Copy link
Collaborator

bretg commented Nov 24, 2021

Two use cases have been offered:

  • video might have different site.content.data
  • a page might have a split personality where some adunits have different site.content.data

Would it be reasonable to assume that these scenarios could be run as separate auctions? If so, we could add the ability to set ortb2 on requestBids:

pbjs.requestBids({
    bidsBackHandler: sendAdserverRequest,
    ...
    ortb2: {
       // for this auction only, deep-merge this block into any existing ortb2 settings sent on the adunit
       // or obtained through getConfig
    }
});

I think this would involve a change to the getConfig routine so when bid adapters call getConfig("ortb2"), they get a fully merged object.

@patmmccann
Copy link
Collaborator Author

Yes, This appears to be an excellent solution!

@dgirardi dgirardi self-assigned this Feb 11, 2022
@dgirardi
Copy link
Collaborator

@bretg @patmmccann there are some technical problems with implementing an auction-aware config.getConfig('ortb2') - the same problems that afflict setBidderConfig: it can only be made to work when getConfig is called directly and from very specific places (currently adapter's buildRequests and interpretResponse).

For example, the fpd module currently calls getConfig('ortb2') in a way that cannot easily be made auction-aware. But more in general, it's a kind of "dark magic" that will cause us trouble in the future because it's very easy for a contributor (and a reviewer) to not fully understand/remember how it actually works. Another word for it is technical debt.

Here's my counter-proposal:

  1. Implement @bretg's proposal with the caveats above (it will only work for direct calls from buildRequests and interpretResponse; it will silently and surprisingly fail elsewhere; it will be invisible to the fpd module);
  2. Also make a fully merged ortb2 object available in the bidRequest (which would include global configuration; auction configuration, and the adUnit's ortb2Imp); then gradually ask adapters to use only that as the access point to FPD, and re-think how the fpd module should do enrichment / validation (it should probably run on each request, and not ask the publisher to manually refresh FPD data). Have a plan to eventually phase out bidRequest.ortb2Imp.

@bretg
Copy link
Collaborator

bretg commented Feb 11, 2022

Thanks for pointing out the problems with the original proposal, @dgirardi.

Getting 70+ adapters to modify FPD again sounds like a pain. We spent a lot of time last year dealing with fallout from the last FPD implementation change.

Stepping back, Patrick's use case is mediatype-related. i.e. different site.content for video. So a more brute-force approach would be to define a parallel convention. e.g. setConfig({ortb2-video}). Adapters would need to read ortb2-video when they're building video requests.

So this needs to be discussed in committee -- if we have stomach for another wrenching change for 70 adapters, cool.

@dgirardi
Copy link
Collaborator

The change from config.getConfig('ortb2') to bidRequest.ortb2 could be done with little more than a search-and-replace, so not necessarily that painful for adapter maintainers (we could do it for them). However, removing the split we currently have between ortb2 and ortb2Imp would be more complicated.

@dgirardi
Copy link
Collaborator

dgirardi commented Mar 2, 2022

Updated proposal:

  • extend the pbjs.requestBids API to take in site-wide FPD as above:
    pbjs.requestBids({
     // ...
     ortb2: {
     // ....
     }
    })
    
  • introduce a new layer between requestBids and the start of the auction, where the ortb2 parameter is transformed to be scoped by bidder:
    requestAuction({
        // ...
        ortb2: {
          standard: { /* ... * / },
          bidderA: { /* ... */ },
          /...
        }
    })
    
  • Change the guidance for RTD submodules and refactor them to populate those fields instead of calling setConfig or setBidderConfig. They are working directly with the object passed to requestBids, so this new approach would simplify this part of the stack (this is the motivation for scoping FPD by bidders). The current system seems very fragile to me as I don't think it's guaranteed to work if there are multiple auctions running simultaneously.
  • Just before calling into adapters' buildRequests(validBidRequests, bidderRequest), core will merge (in increasing order of priority) config.getConfig('ortb2') with ortb2.standard and ortb2.[bidder] as passed to requestBids and processed by RTD modules, and make the result available as bidderRequest.ortb2.
  • Refactor all bid adapters that call config.getConfig('ortb2') to use bidderRequest.ortb2 instead, and update adapter guidance accordingly.
  • For the special case of the PBS adapter, FPD merging will be done for each bidder. This boils down to adding the contents of requestBids({..}) here:
    function addBidderFirstPartyDataToRequest(request) {
    const bidderConfig = config.getBidderConfig();
    const fpdConfigs = Object.keys(bidderConfig).reduce((acc, bidder) => {
    const currBidderConfig = bidderConfig[bidder];
    if (currBidderConfig.ortb2) {
    const ortb2 = mergeDeep({}, currBidderConfig.ortb2);
    acc.push({
    bidders: [ bidder ],
    config: { ortb2 }
    });
    }
    return acc;
    }, []);
    if (fpdConfigs.length) {
    deepSetValue(request, 'ext.prebid.bidderconfig', fpdConfigs);
    }
    }

@dgirardi dgirardi moved this from Open to PR submitted in Prebid.js Tactical Issues table Mar 9, 2022
@dgirardi dgirardi moved this from PR submitted to In progress in Prebid.js Tactical Issues table Mar 9, 2022
@dgirardi
Copy link
Collaborator

I am now thinking this should be a 7.0 change: my proposal would "freeze" the contents of getConfig('ortb2') for a particular auction at the time one calls requestBids, so if a publisher is currently updating it after that point (for example from custom event handlers) we are likely to break their logic.

In fact it will probably have more side effects: currently RTD modules are using auction information to update the global 'ortb2', but if you have multiple simultaneous auctions, there's in general no guarantee on the order they'll run in, so I cannot replicate the same behavior for auction-specific FPD.

@patmmccann, do you have a sense of how publishers are currently working around this? Are they likely to do something like pbjs.onEvent('BID_REQUESTED', () => config.setConfig('ortb2', ...))?

@dgirardi dgirardi moved this from In progress to Needs Req in Prebid.js Tactical Issues table Mar 14, 2022
@bretg
Copy link
Collaborator

bretg commented Mar 15, 2022

Thanks for this proposal @dgirardi .

I would like to question the need for bidder-specific AND auction-specific ortb2 data. The invariant originally envisioned is that everything underneath ortb2 is actually ORTB. Adding a layer underneath that (standard, BIDDER) muddies that model. I propose that we skip bidder-specific ortb2 for the first release. If we're forced to add it by a real use case in the future, we can follow this design pattern and add a new thing like 'bidder-ortb2' as a peer to 'ortb2' in the auction call.

A clarification on the PBS bid adapter piece:

  • the merging of ortb2 into the PBS JSON would be the getConfig({ortb2}) and the bidderRequest.ortb2.
  • in the future, if we have to support bidderRequest.bidder-ortb2.BIDDERA, that would need to get sent to PBS merged into ext.prebid.bidderconfig.BIDDERA.ortb2.

Finally, it would nice for the RTD modules to support some kind of merge function to simplify their processing of bidderRequest.ortb2. Or maybe that's doable in native Javascript?

@dgirardi
Copy link
Collaborator

dgirardi commented Mar 15, 2022

@bretg the bidder and auction specific FPD would not be part of the publisher API, rather a simplification of how the RTD modules set bidder-specific data. Currently the flow is:

  1. publisher calls requestBids(...)
  2. RTD modules "intercept" requestBids, look at its parameters (the adUnits, mostly) and call setConfig({ortb2: ...}) and setBidderConfig(config: {ortb2: ...})
  3. bid adapters finally call getConfig('ortb2') which automagically merges global and bidder configs.

The proposal here is to change it to:

  1. publisher calls requestBids({ortb2: ...})
  2. internally, that calls some other (private) entry point, let's call it startAuction({ortb2: {standard: ..., bidderA: ...}}) (where the difference is FPD is scoped by bidder - and also implicitly by auction, since we are inside a particular one)
  3. RTD modules intercept the new startAuction, and just modify the ortb2 argument rather than setting global or bidder configuration
  4. bid adapters get the merged ortb2 in the request.

The reason I'd prefer this is that RTD modules are effectively already working at that level of granularity - they run on each auction, and they set bidder-specific FPD. I think right now there's an implicit assumption that every auction will always result in the same set of FPD, for all bidders, by all RTD modules - if that's not true, the result of calling getConfig('ortb2') from an adapter is not necessarily correct. If we change the interface so that RTD just accepts and returns auction and bidder specific FPD this problem goes away completely.

@dgirardi
Copy link
Collaborator

dgirardi commented Mar 15, 2022

The problem remains, however, that in general I don't think it's possible to introduce auction-level FPD without breaking compatibility with publisher's custom code that may be modifying the global ortb2 config - which is likely to include any current workaround to this issue.

To clarify, the problem is that if I call requestBids(ortb2: auctionFPD), it's nigh impossible to make it so that custom code calling getConfig('ortb2' ) will reliably see it reflect auctionFPD when it should; likewise, if the custom code calls setConfig({ortb2: ...}), we cannot guarantee that we'll attach it to the right auction.

@bretg
Copy link
Collaborator

bretg commented Mar 15, 2022

I think this all sounds ok, and agree it's an improvement over what's there now. And that it's best to do this in 7.0 so it can be documented for pubs to be aware of.

What I'm reacting to is the aspect that children of ortb2 that aren't actually openrtb. I don't like these: ortb2.standard and ortb2.bidderA . Everything else I'm ok with.

I think what you're saying is that the external interface would still adhere to ortb2 but that the private entry point (e.g. startAuction) splits them. I can see why that could work, but would suggest the alternate startAuction({ortb2: {}, bidderOrtb2:{ bidderA: ...}}) -- this is to keep the invariant that the contents of ortb2 are always actual openrtb.

@patmmccann
Copy link
Collaborator Author

@patmmccann, do you have a sense of how publishers are currently working around this? Are they likely to do something like pbjs.onEvent('BID_REQUESTED', () => config.setConfig('ortb2', ...))?

I think the current workflow for someone who cares deeply about this is to run all your display and then do a new setconfig and then call video. However, in most cases I think video data are just getting appended to display requests incorrectly.

@bretg
Copy link
Collaborator

bretg commented Mar 17, 2022

Discussed with Patrick. We approve your proposal @dgirardi and are ready to see it happen as part of 7.0.

We also agree that the the bidder-AND-auction specific scenario can wait for a later phase.

@bretg bretg moved this from Needs Req to Open in Prebid.js Tactical Issues table Mar 17, 2022
@bretg bretg moved this from Open to Ready for Dev in Prebid.js Tactical Issues table Mar 17, 2022
@dgirardi dgirardi moved this from Ready for Dev to In progress in Prebid.js Tactical Issues table Mar 30, 2022
@patmmccann patmmccann changed the title Site.content.data for a specific ad unit Site.content.data for a specific [auction] Apr 19, 2022
dgirardi added a commit to dgirardi/Prebid.js that referenced this issue Apr 28, 2022
…uction-specific FPD (prebid#7651)

The changes are:

 - `pbjs.requestBids` now accepts an `ortb2` parameter, which will get merged into (and overrides) the global `ortb2` config only for that particular auction
 - `requestBids` now "freezes" FPD for a particular auction into global (`getConfig('ortb2')` + the auction-specific `ortb2`) and bidder fragments that get passed down to a new hook, `startAuction` (and further down the stack to auctionManager, adapterManager, etc)
 - FPD modules and RTD modules have been refactored to hook into `startAuction` (instead of `requestBids`), and they read from and modify its FPD parameters instead of calling `getConfig` / `setConfig`
 - bid requests and bidd*er* requests (the parameters passed to bidders' `buildRequests`) are now augmented with an `ortb2` property that replaces the use of `getConfig('ortb2')` for bid adapters. All adapters have been refactored to read from those instead of calling `getConfig`.

The choice to put `ortb2` into every bid request is due to some adapters doing their FPD logic in the validation phase (`isBidRequestValid`) or in `transformBidParameters`, where the bidd*er* request is not available.

Note that two RTD providers - weborama and jwPlayer - were already populating `bid.ortb2` under some circumstances. Most adapters were blind to it (I know only of proxistore looking for it - related is also prebid#8320). I have refactored those two to update the bidder-level ortb2 config instead.

Squashed commit of the following:

commit 171b5ad6e23837ebbe964c7539345bd825b5545f
Merge: f9d3b96a fa20923
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 12:17:28 2022 -0700

    Merge branch 'pb7-merge' into auction-fpd

commit f9d3b96afd2cb5477d488209c450802ca5c135da
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 11:48:22 2022 -0700

    Revert "Revert "Prohibit getConfig('ortb2')""

    This reverts commit 439e926ed0323e8128e82fa3e6968eefb6ee5daf.

commit 6667c1568dcaf6aaeee3ec02b7609466f5f1ade1
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 11:44:49 2022 -0700

    Fix lint

commit 1f3d7cabf462a3ad287acd93087a9e13f3756f84
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 11:42:10 2022 -0700

    convert invalid setting of bid.ortb2 from RTD providers: weborama

commit 6e7f7d031c5a5da484f14d27a79dce2131d8ff22
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 11:08:40 2022 -0700

    convert invalid setting of bid.ortb2 from RTD providers: jwPlayer

commit 5d9d3b02de35f61b7959a2a923a9116c594fcb91
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 10:34:24 2022 -0700

    convert RTD: weborama

commit b27aada8b9659f0565c66bb3b26ae883358738aa
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 10:11:19 2022 -0700

    convert rtd: sirdata

commit fca00b89588454092240feb89d77e35e90882fa4
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 10:01:03 2022 -0700

    convert rtd: permutive

commit 6ba257a04788a09a214b58d6df1500c2441bf49a
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 26 09:15:52 2022 -0700

    convert rtd: jwPlayer

commit a0fd8b0128b071cddf8e3a81cca552a2ae284271
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 26 09:14:07 2022 -0700

    convert rtd: im

commit 3e2aa858cae8334c3fb670d2094686bb7e689a0f
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 26 09:12:39 2022 -0700

    convert rtd: idWard

commit 39d2139c9617c305c1c0d68948ad0c447342e2da
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 26 09:09:57 2022 -0700

    convert rtd: halo

commit c6f3852795c25e59814c34ad9d0a202127132658
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:48:17 2022 -0700

    convert rtd: hadron

commit 39365892ccf7c4aa5acc19913e01ab6e3a4915f6
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:31:44 2022 -0700

    convert rtd: dgkeyword

commit 0966b92d68122e7677b75f9b5dfad91788ec5ffa
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:25:55 2022 -0700

    convert rtd: brandmetrics

commit 54fe3211ed7967b32bc4d1c81a24d2eb44a806ea
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:17:26 2022 -0700

    convert rtd: akamai

commit c569fb7cf364318991700a01874797b58f492475
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:09:41 2022 -0700

    convert rtd: airgrid

commit d70ad20d59ff63d9e22b7efdd4c87fafe21fddd0
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 12:58:45 2022 -0700

    convert rtd: adloox

commit 11086f1b400c7f4870afd7f8979309747f0d2eff
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 12:07:50 2022 -0700

    Group global and bidder level ortb2 in startAuction

commit b77fc06954a78902c5abbad583c31ef49e7cab12
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 11:41:27 2022 -0700

    Convert fpdModule

commit 439e926ed0323e8128e82fa3e6968eefb6ee5daf
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 10:25:13 2022 -0700

    Revert "Prohibit getConfig('ortb2')"

    This reverts commit 1d93427b271f7b9da490c33c099522a54f1bc614.

commit 1d93427b271f7b9da490c33c099522a54f1bc614
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 12:34:40 2022 -0700

    Prohibit getConfig('ortb2')

commit 118420f7bf58c5d7d63a6456009100efdb6543bd
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 11:20:15 2022 -0700

    Convert PBS adapter

commit 8b85b9bd378f0bae4b10da5a00cdcc2854fac414
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 11:06:28 2022 -0700

    Pass FPD to PBS adapter

commit 3d577a861b01c34ebf9e818d415caf9596b98d7b
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 10:28:57 2022 -0700

    Group ortb2 fragments into one object when passing them down the stack

commit 0199ad2a8a1af033f6787d5c9c113638f755947f
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:23:00 2022 -0700

    convert bidders: improveddigital

commit 13ea77111409e1ec7c2608d950bab9195af23337
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:14:54 2022 -0700

    Fix lint

commit e16f7045e998c66d76a90ba59c4f204db5064170
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:09:05 2022 -0700

    convert bidders: yieldlab

commit 38158faf94561337f218887410e253517c8e914e
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:06:05 2022 -0700

    convert bidders: trustx

commit 9f5b4d5dabaa2df3b406d755b79f8b91e804e258
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:01:52 2022 -0700

    convert bidders: improveddigital

commit 357dc821f83d64e6b434e73ffa77eea98c065928
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 08:56:55 2022 -0700

    convert bidders: grid

commit 386692ebd28467dad70bae35f47f9470495186e6
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 08:47:38 2022 -0700

    convert bidders: pubmatic

commit 5bdb5ec3995e26a6fd209e2c7d1301a2028404ab
Merge: cf662cb8 d8b0509
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 08:27:42 2022 -0700

    Merge branch 'master' into auction-fpd

commit cf662cb80078c3fea5532d0eb56d2148abecca94
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:36:31 2022 -0700

    convert bidders: openx

commit 1485cf33297dd7116c09557f39a0eb5102590eeb
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:30:57 2022 -0700

    Fix lint

commit 33ffd2b1bdb2a7a8c0f27344ec34354696ffd0f6
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:29:27 2022 -0700

    convert bidders: complete for all bidders calling getConfig('ortb2')

commit 409b79b8152751993b0c9fbadfc8c9669e3e7a39
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:28:15 2022 -0700

    convert bidders: yahoo

commit 5d12c257818ec82f1d4f0f3c9f5d8ccda14f556c
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:22:28 2022 -0700

    convert bidders: ttd

commit 30ff4373558c0f0028514e6a0e389f6874ad694a
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:19:44 2022 -0700

    convert bidders: triplelift

commit de1d97382bed073aad6ff06e381f5bccad8c7586
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:18:06 2022 -0700

    convert bidders: sovrn

commit 85a4db11ac70c0c00546cc177ef4b7206066dfe0
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:14:39 2022 -0700

    convert bidders: sonobi

commit 13cf0352f9374a50da9b627fdc53cb34f1a2b090
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:13:41 2022 -0700

    convert bidders: smaato

commit d31679020084b4b8277faa87adbff6c10402ff12
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:12:13 2022 -0700

    convert bidders: sharethrough

commit aac7150b1133c78cc37f9918d109af760c4b7134
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:10:12 2022 -0700

    convert bidders: rubicon

commit 1af8b5103c9004ff3342c8a1d5a7e13b1365ae04
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:05:04 2022 -0700

    convert bidders: pubmatic

commit 85e7de147fd868cb01d46d24bb8bf56400949ed2
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:03:51 2022 -0700

    convert bidders: pubmatic

commit 50d106168206de6a88581731af2b2883c9b85a16
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:59:57 2022 -0700

    convert bidders: ozone

commit 821d995e0d57e7027035962a6fb2d304f45b880c
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:56:54 2022 -0700

    convert bidders: optout

commit 16cf6b4ac9d9a1ff259f9e365043ca2ec88eb07b
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:55:31 2022 -0700

    convert bidders: nobid

commit 0c2c350fb33c25d24017d2e59385c4204e37caf0
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:53:50 2022 -0700

    convert bidders: minutemedia

commit 19f253486dab65d65a15a4b7bd758dd27c95a373
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:52:11 2022 -0700

    convert bidders: mediakeys

commit ba66be0f2c596fabaeb9380245334fa208318840
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:50:24 2022 -0700

    convert bidders: livewrapped

commit e25e3587dbae8ff12adcd57c55a234c918f5f42b
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:47:18 2022 -0700

    convert bidders: ix

commit 9a65715a1b3604036f073288048bbecc81a70b85
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:32:07 2022 -0700

    convert bidders: glimpse

commit 1a3cff66882ca56093fd38e3a054fb764c92078d
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:31:18 2022 -0700

    convert bidders: glimpse

commit 00bf5aa75c3a1b29299f2ecc9e0ee1416afc2024
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:25:32 2022 -0700

    convert bidders: criteo

commit 893ff7ed635e81266b6910d7c1623a4b7b86484c
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:19:49 2022 -0700

    convert bidders: conversant

commit 6b44388bae02d364464dab3c3360d9a0ce8d289e
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:06:25 2022 -0700

    convert bidders: beachfront

commit 92c6f9780f51f6508c36c2dd20701492fb979db1
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:01:01 2022 -0700

    convert bidders: amx

commit afc57dd4b2ba911820ea3f19ab43a73f2e7a4b87
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:58:37 2022 -0700

    convert bidders: adxcg

commit bcb8955f4edd597696a5fe70196976b20a2e611e
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:51:09 2022 -0700

    convert bidders: adrelevantis

commit aeade3ee9da816d74b02af28aa67a474b0a23920
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:46:02 2022 -0700

    convert bidders: adnuntius

commit 675ae0830526b44b82d5060f0b6ba687943695e8
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:27:07 2022 -0700

    convert bidders: adkernel, admixer

commit c7e68088ffda095a6be88b492ef31d45c98df36a
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:24:40 2022 -0700

    Convert bidders: adagio, adf

commit 4991a79c7aa88131d77ea97ed8458bb36212178b
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 12:56:51 2022 -0700

    Make FPD available in bidderRequest

commit 9224806f2457001b12763d7493de7422025880fa
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 12:28:18 2022 -0700

    Pass ortb2 down to adapterManager

commit 532539815910448cf4d758ff2328fc00af2d1179
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 14 10:45:05 2022 -0700

    Make auction FPD-aware
@dgirardi dgirardi moved this from In progress to PR submitted in Prebid.js Tactical Issues table May 2, 2022
patmmccann pushed a commit that referenced this issue May 3, 2022
…ternals (#8338)

* This restructures the way Prebid handles first party data to enable auction-specific FPD (#7651)

The changes are:

 - `pbjs.requestBids` now accepts an `ortb2` parameter, which will get merged into (and overrides) the global `ortb2` config only for that particular auction
 - `requestBids` now "freezes" FPD for a particular auction into global (`getConfig('ortb2')` + the auction-specific `ortb2`) and bidder fragments that get passed down to a new hook, `startAuction` (and further down the stack to auctionManager, adapterManager, etc)
 - FPD modules and RTD modules have been refactored to hook into `startAuction` (instead of `requestBids`), and they read from and modify its FPD parameters instead of calling `getConfig` / `setConfig`
 - bid requests and bidd*er* requests (the parameters passed to bidders' `buildRequests`) are now augmented with an `ortb2` property that replaces the use of `getConfig('ortb2')` for bid adapters. All adapters have been refactored to read from those instead of calling `getConfig`.

The choice to put `ortb2` into every bid request is due to some adapters doing their FPD logic in the validation phase (`isBidRequestValid`) or in `transformBidParameters`, where the bidd*er* request is not available.

Note that two RTD providers - weborama and jwPlayer - were already populating `bid.ortb2` under some circumstances. Most adapters were blind to it (I know only of proxistore looking for it - related is also #8320). I have refactored those two to update the bidder-level ortb2 config instead.

Squashed commit of the following:

commit 171b5ad6e23837ebbe964c7539345bd825b5545f
Merge: f9d3b96a fa20923
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 12:17:28 2022 -0700

    Merge branch 'pb7-merge' into auction-fpd

commit f9d3b96afd2cb5477d488209c450802ca5c135da
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 11:48:22 2022 -0700

    Revert "Revert "Prohibit getConfig('ortb2')""

    This reverts commit 439e926ed0323e8128e82fa3e6968eefb6ee5daf.

commit 6667c1568dcaf6aaeee3ec02b7609466f5f1ade1
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 11:44:49 2022 -0700

    Fix lint

commit 1f3d7cabf462a3ad287acd93087a9e13f3756f84
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 11:42:10 2022 -0700

    convert invalid setting of bid.ortb2 from RTD providers: weborama

commit 6e7f7d031c5a5da484f14d27a79dce2131d8ff22
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 11:08:40 2022 -0700

    convert invalid setting of bid.ortb2 from RTD providers: jwPlayer

commit 5d9d3b02de35f61b7959a2a923a9116c594fcb91
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 10:34:24 2022 -0700

    convert RTD: weborama

commit b27aada8b9659f0565c66bb3b26ae883358738aa
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 10:11:19 2022 -0700

    convert rtd: sirdata

commit fca00b89588454092240feb89d77e35e90882fa4
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 28 10:01:03 2022 -0700

    convert rtd: permutive

commit 6ba257a04788a09a214b58d6df1500c2441bf49a
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 26 09:15:52 2022 -0700

    convert rtd: jwPlayer

commit a0fd8b0128b071cddf8e3a81cca552a2ae284271
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 26 09:14:07 2022 -0700

    convert rtd: im

commit 3e2aa858cae8334c3fb670d2094686bb7e689a0f
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 26 09:12:39 2022 -0700

    convert rtd: idWard

commit 39d2139c9617c305c1c0d68948ad0c447342e2da
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 26 09:09:57 2022 -0700

    convert rtd: halo

commit c6f3852795c25e59814c34ad9d0a202127132658
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:48:17 2022 -0700

    convert rtd: hadron

commit 39365892ccf7c4aa5acc19913e01ab6e3a4915f6
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:31:44 2022 -0700

    convert rtd: dgkeyword

commit 0966b92d68122e7677b75f9b5dfad91788ec5ffa
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:25:55 2022 -0700

    convert rtd: brandmetrics

commit 54fe3211ed7967b32bc4d1c81a24d2eb44a806ea
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:17:26 2022 -0700

    convert rtd: akamai

commit c569fb7cf364318991700a01874797b58f492475
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 13:09:41 2022 -0700

    convert rtd: airgrid

commit d70ad20d59ff63d9e22b7efdd4c87fafe21fddd0
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 12:58:45 2022 -0700

    convert rtd: adloox

commit 11086f1b400c7f4870afd7f8979309747f0d2eff
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 12:07:50 2022 -0700

    Group global and bidder level ortb2 in startAuction

commit b77fc06954a78902c5abbad583c31ef49e7cab12
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 11:41:27 2022 -0700

    Convert fpdModule

commit 439e926ed0323e8128e82fa3e6968eefb6ee5daf
Author: Demetrio Girardi <[email protected]>
Date:   Mon Apr 25 10:25:13 2022 -0700

    Revert "Prohibit getConfig('ortb2')"

    This reverts commit 1d93427b271f7b9da490c33c099522a54f1bc614.

commit 1d93427b271f7b9da490c33c099522a54f1bc614
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 12:34:40 2022 -0700

    Prohibit getConfig('ortb2')

commit 118420f7bf58c5d7d63a6456009100efdb6543bd
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 11:20:15 2022 -0700

    Convert PBS adapter

commit 8b85b9bd378f0bae4b10da5a00cdcc2854fac414
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 11:06:28 2022 -0700

    Pass FPD to PBS adapter

commit 3d577a861b01c34ebf9e818d415caf9596b98d7b
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 10:28:57 2022 -0700

    Group ortb2 fragments into one object when passing them down the stack

commit 0199ad2a8a1af033f6787d5c9c113638f755947f
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:23:00 2022 -0700

    convert bidders: improveddigital

commit 13ea77111409e1ec7c2608d950bab9195af23337
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:14:54 2022 -0700

    Fix lint

commit e16f7045e998c66d76a90ba59c4f204db5064170
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:09:05 2022 -0700

    convert bidders: yieldlab

commit 38158faf94561337f218887410e253517c8e914e
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:06:05 2022 -0700

    convert bidders: trustx

commit 9f5b4d5dabaa2df3b406d755b79f8b91e804e258
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 09:01:52 2022 -0700

    convert bidders: improveddigital

commit 357dc821f83d64e6b434e73ffa77eea98c065928
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 08:56:55 2022 -0700

    convert bidders: grid

commit 386692ebd28467dad70bae35f47f9470495186e6
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 08:47:38 2022 -0700

    convert bidders: pubmatic

commit 5bdb5ec3995e26a6fd209e2c7d1301a2028404ab
Merge: cf662cb8 d8b0509
Author: Demetrio Girardi <[email protected]>
Date:   Fri Apr 22 08:27:42 2022 -0700

    Merge branch 'master' into auction-fpd

commit cf662cb80078c3fea5532d0eb56d2148abecca94
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:36:31 2022 -0700

    convert bidders: openx

commit 1485cf33297dd7116c09557f39a0eb5102590eeb
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:30:57 2022 -0700

    Fix lint

commit 33ffd2b1bdb2a7a8c0f27344ec34354696ffd0f6
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:29:27 2022 -0700

    convert bidders: complete for all bidders calling getConfig('ortb2')

commit 409b79b8152751993b0c9fbadfc8c9669e3e7a39
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:28:15 2022 -0700

    convert bidders: yahoo

commit 5d12c257818ec82f1d4f0f3c9f5d8ccda14f556c
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:22:28 2022 -0700

    convert bidders: ttd

commit 30ff4373558c0f0028514e6a0e389f6874ad694a
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:19:44 2022 -0700

    convert bidders: triplelift

commit de1d97382bed073aad6ff06e381f5bccad8c7586
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:18:06 2022 -0700

    convert bidders: sovrn

commit 85a4db11ac70c0c00546cc177ef4b7206066dfe0
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:14:39 2022 -0700

    convert bidders: sonobi

commit 13cf0352f9374a50da9b627fdc53cb34f1a2b090
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:13:41 2022 -0700

    convert bidders: smaato

commit d31679020084b4b8277faa87adbff6c10402ff12
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:12:13 2022 -0700

    convert bidders: sharethrough

commit aac7150b1133c78cc37f9918d109af760c4b7134
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:10:12 2022 -0700

    convert bidders: rubicon

commit 1af8b5103c9004ff3342c8a1d5a7e13b1365ae04
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:05:04 2022 -0700

    convert bidders: pubmatic

commit 85e7de147fd868cb01d46d24bb8bf56400949ed2
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 15:03:51 2022 -0700

    convert bidders: pubmatic

commit 50d106168206de6a88581731af2b2883c9b85a16
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:59:57 2022 -0700

    convert bidders: ozone

commit 821d995e0d57e7027035962a6fb2d304f45b880c
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:56:54 2022 -0700

    convert bidders: optout

commit 16cf6b4ac9d9a1ff259f9e365043ca2ec88eb07b
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:55:31 2022 -0700

    convert bidders: nobid

commit 0c2c350fb33c25d24017d2e59385c4204e37caf0
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:53:50 2022 -0700

    convert bidders: minutemedia

commit 19f253486dab65d65a15a4b7bd758dd27c95a373
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:52:11 2022 -0700

    convert bidders: mediakeys

commit ba66be0f2c596fabaeb9380245334fa208318840
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:50:24 2022 -0700

    convert bidders: livewrapped

commit e25e3587dbae8ff12adcd57c55a234c918f5f42b
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:47:18 2022 -0700

    convert bidders: ix

commit 9a65715a1b3604036f073288048bbecc81a70b85
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:32:07 2022 -0700

    convert bidders: glimpse

commit 1a3cff66882ca56093fd38e3a054fb764c92078d
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:31:18 2022 -0700

    convert bidders: glimpse

commit 00bf5aa75c3a1b29299f2ecc9e0ee1416afc2024
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:25:32 2022 -0700

    convert bidders: criteo

commit 893ff7ed635e81266b6910d7c1623a4b7b86484c
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:19:49 2022 -0700

    convert bidders: conversant

commit 6b44388bae02d364464dab3c3360d9a0ce8d289e
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:06:25 2022 -0700

    convert bidders: beachfront

commit 92c6f9780f51f6508c36c2dd20701492fb979db1
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 14:01:01 2022 -0700

    convert bidders: amx

commit afc57dd4b2ba911820ea3f19ab43a73f2e7a4b87
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:58:37 2022 -0700

    convert bidders: adxcg

commit bcb8955f4edd597696a5fe70196976b20a2e611e
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:51:09 2022 -0700

    convert bidders: adrelevantis

commit aeade3ee9da816d74b02af28aa67a474b0a23920
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:46:02 2022 -0700

    convert bidders: adnuntius

commit 675ae0830526b44b82d5060f0b6ba687943695e8
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:27:07 2022 -0700

    convert bidders: adkernel, admixer

commit c7e68088ffda095a6be88b492ef31d45c98df36a
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 13:24:40 2022 -0700

    Convert bidders: adagio, adf

commit 4991a79c7aa88131d77ea97ed8458bb36212178b
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 12:56:51 2022 -0700

    Make FPD available in bidderRequest

commit 9224806f2457001b12763d7493de7422025880fa
Author: Demetrio Girardi <[email protected]>
Date:   Tue Apr 19 12:28:18 2022 -0700

    Pass ortb2 down to adapterManager

commit 532539815910448cf4d758ff2328fc00af2d1179
Author: Demetrio Girardi <[email protected]>
Date:   Thu Apr 14 10:45:05 2022 -0700

    Make auction FPD-aware

* add jwPlayer note
Repository owner moved this from PR submitted to Done in Prebid.js Tactical Issues table May 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging a pull request may close this issue.

4 participants