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

Zeotap ID+ submodule #5640

Merged
merged 10 commits into from
Sep 11, 2020
Merged

Zeotap ID+ submodule #5640

merged 10 commits into from
Sep 11, 2020

Conversation

shikharsharma-zeotap
Copy link
Contributor

Type of change

  • Feature

Description of change

This pr adds the zeotapIdPlusIdSystem submodule to add Zeotap IDP id to the bid requests.

Documentation PR Link: prebid/prebid.github.io#2260

Copy link
Collaborator

@smenzer smenzer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a few changes requested based on not seeing the need for storage configuration or configParams mostly

Comment on lines 218 to 224
},
{
name: "zeotapIdPlus",
storage: {
type: "cookie",
name: "IDP"
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it looks like you are defining your own name for the cookie and you're not leveraging the userId module storage (which is what this bit is used for). so I think you can just ignore this, like how Parrable does.

based on your module code, I think you can just do this:

Suggested change
},
{
name: "zeotapIdPlus",
storage: {
type: "cookie",
name: "IDP"
}
},
{
name: "zeotapIdPlus"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @smenzer, thanks for the suggestion, have made changes to the module and files to remove storage configuration.

Comment on lines 14 to 24
function isValidConfig(configParams) {
if (!configParams) {
utils.logError('User ID - zeotapId submodule requires configParams');
return false;
}
if (!configParams.name) {
utils.logError('User ID - zeotapId submodule requires valid config params: name');
return false;
}
return true;
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in your example you don't list any params, but you are requiring "name" here. what is the name param and how are you using it? i don't see it anywhere in your code

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is removed, not required.

}

function fetchId(configParams) {
if (!isValidConfig(configParams)) return undefined;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

per the above, i don't think you need this since you're not using any configParams

Suggested change
if (!isValidConfig(configParams)) return undefined;

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

made changes.

Comment on lines 440 to 441
name: 'zeotapIdPlus',
storage: { name: 'IDP', type: 'cookie' }
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

per above, this can probably be dropped

Suggested change
name: 'zeotapIdPlus',
storage: { name: 'IDP', type: 'cookie' }
name: 'zeotapIdPlus'

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dropped.

@@ -1314,6 +1357,8 @@ describe('User ID', function() {
name: 'sharedId', storage: {name: 'sharedid', type: 'cookie'}
}, {
name: 'intentIqId', storage: { name: 'intentIqId', type: 'cookie' }
}, {
name: 'zeotapIdPlus', storage: { name: 'IDP', type: 'cookie' }
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

per above, this can probably just be your name

Suggested change
name: 'zeotapIdPlus', storage: { name: 'IDP', type: 'cookie' }
name: 'zeotapIdPlus'

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

made changes.

Comment on lines 13 to 14
name: 'zeotapIdPlus',
storage: { name: 'IDP', type: 'cookie' }
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

probably can drop storage

Suggested change
name: 'zeotapIdPlus',
storage: { name: 'IDP', type: 'cookie' }
name: 'zeotapIdPlus'

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dropped.

Comment on lines 22 to 26
name: 'zeotapIdPlus',
storage: {
name: 'IDP',
type: 'cookie'
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

probably can drop storage

Suggested change
name: 'zeotapIdPlus',
storage: {
name: 'IDP',
type: 'cookie'
}
name: 'zeotapIdPlus'

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dropped.

@idettman idettman added needs review needs update needs 2nd review Core module updates require two approvals from the core team labels Aug 20, 2020
Copy link
Collaborator

@smenzer smenzer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@shikharsharma-zeotap
Copy link
Contributor Author

@smenzer anything else required from my side for this to be merged?

@smenzer
Copy link
Collaborator

smenzer commented Aug 26, 2020

@shikharsharma-zeotap where are you actually generating the ID? if there's no ID in cookie/local storage...right now you just return undefined...is that what you want? No calls to your servers are required?

@shikharsharma-zeotap
Copy link
Contributor Author

@smenzer the ID will be generated on the publisher page by our JS. No calls to our server is required from prebid's end.

@patmmccann
Copy link
Collaborator

patmmccann commented Aug 26, 2020

Are modifications to the eids spec and userid spec required parts of adding a user id module? Most user id commits seem to modify them but not all. You seem to be missing a unit test on eids spec

@smenzer
Copy link
Collaborator

smenzer commented Aug 26, 2020

Are modifications to the eids spec and userid spec required parts of adding a user id module? Most user id commits seem to modify them but not all. You seem to be missing a unit test on eids spec

there are a couple tests in those two specs that look at basic testing for any modules that want to. eids seems required although the tests in userId_spec can be covered by a separate test suite; but better to have both than nothing if you ask me.

@smenzer
Copy link
Collaborator

smenzer commented Aug 26, 2020

@smenzer the ID will be generated on the publisher page by our JS. No calls to our server is required from prebid's end.

so if the publisher doesn't have your JS on page from a direct integration with Zeotap, you aren't expecting to be able to provide an ID, right?

@shikharsharma-zeotap
Copy link
Contributor Author

Yes @smenzer, we expect publisher integration with zeotap for ID to be present, so generation/server calls from prebid are not required. Also, thanks @patmmccann , will be adding the Eid spec tests too.

@smenzer
Copy link
Collaborator

smenzer commented Aug 26, 2020

@idettman can you do a quick review and make sure you're ok with this before we merge? thanks!

@patmmccann
Copy link
Collaborator

@idettman can you do a quick review and make sure you're ok with this before we merge? thanks!

I don't think this can be merged until eids.js is covered with a test

import {submodule} from '../src/hook.js';
import { getStorageManager } from '../src/storageManager.js';

const ZEOTAP_COOKIE_NAME = 'IDP';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be configurable by the pub? can you read if this is set in config and fallback to 'IDP' ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@patmmccann I have added the tests to eid spec file. The cookie name 'IDP' is not configurable by the pub. It gets added to the storage by Zeotap JS after publisher integration. I didn't get the other question.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@shikharsharma-zeotap
Copy link
Contributor Author

@idettman waiting for your comments. @smenzer @patmmccann have resolved conflicts with base branch. Can we merge this now?

Copy link
Collaborator

@smenzer smenzer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the additional test for eids.

CI is failing, though, so that needs to be fixed before we can merge. @idettman can you do a quick review, too, please?

@shikharsharma-zeotap
Copy link
Contributor Author

@smenzer the circleCI shows 2 tests breaking during the BrowserStack testing.
One is related to Parrable Id Module, other is for Zeotap Id module. Is there something that I require to fix from my end, so that CI looks green?

@smenzer
Copy link
Collaborator

smenzer commented Sep 4, 2020

@shikharsharma-zeotap i'm not really sure why the builds are failing...locally they run fine for me. i've reached out to the prebid community in slack and perhaps someone else here can take a look at things. once that is fixed this is good to go from my end

@smenzer
Copy link
Collaborator

smenzer commented Sep 10, 2020

@shikharsharma-zeotap can you try pulling in the latest master to see if that helps at all?

@shikharsharma-zeotap
Copy link
Contributor Author

Hey @smenzer , have rebased with the latest master, looks like the circleCI has stopped complaining for us now. Thanks!

@smenzer smenzer assigned jlukas79 and unassigned idettman and jsnellbaker Sep 11, 2020
@smenzer smenzer requested review from jlukas79 and removed request for idettman September 11, 2020 09:32
@smenzer
Copy link
Collaborator

smenzer commented Sep 11, 2020

Hey @smenzer , have rebased with the latest master, looks like the circleCI has stopped complaining for us now. Thanks!

great! I'd like to get a review from @jlukas79 and then this can be merged.

@smenzer smenzer merged commit 1e9be73 into prebid:master Sep 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs review needs update needs 2nd review Core module updates require two approvals from the core team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants