Conversation
ID5 basic module See merge request id5-sync/prebid-server-java!1
| @Configuration | ||
| @EnableConfigurationProperties(Id5IdModuleProperties.class) | ||
| @ConditionalOnProperty(prefix = "hooks." + Id5IdModule.CODE, name = "enabled", havingValue = "true") | ||
| @Slf4j |
There was a problem hiding this comment.
Remove any usage of Slf4j. Use LoggerFactory.getLogger instead
| } | ||
|
|
||
| @Bean | ||
| @ConditionalOnMissingBean(Id5PartnerIdProvider.class) |
There was a problem hiding this comment.
No need for @ConditionalOnMissingBean(Id5PartnerIdProvider.class)
| Id5PartnerIdProvider id5PartnerIdProvider) { | ||
| final HttpFetchClient client = new HttpFetchClient( |
There was a problem hiding this comment.
Add empty line after multi-line declaration
| properties.getFetchEndpoint(), | ||
| httpClient, | ||
| jacksonMapper, | ||
| Clock.systemUTC(), |
| /** | ||
| * Configuration model for the ID5 ID module. | ||
| */ |
There was a problem hiding this comment.
Please, remove all unnecessary comments
| Future<Id5UserId> fetch(long partnerId, AuctionRequestPayload payload, | ||
| AuctionInvocationContext invocationContext); |
| public Future<Id5UserId> fetch(long partnerId, AuctionRequestPayload payload, | ||
| AuctionInvocationContext invocationContext) { | ||
| final FetchRequest fetchRequest = createFetchRequest(partnerId, payload, invocationContext); | ||
| try { |
There was a problem hiding this comment.
No need for this try catch. There is no real IO while encoding request to string
| public Future<Id5UserId> fetch(long partnerId, AuctionRequestPayload payload, | ||
| AuctionInvocationContext invocationContext) { |
There was a problem hiding this comment.
public Future<Id5UserId> fetch(long partnerId,
AuctionRequestPayload payload,
AuctionInvocationContext invocationContext) {
| this.fetchUrl = endpoint; | ||
| this.httpClient = httpClient; | ||
| this.mapper = mapper; | ||
| this.clock = clock; | ||
| this.versionInfo = versionInfo; | ||
| this.id5IdModuleProperties = id5IdModuleProperties; |
There was a problem hiding this comment.
Add Objects.requireNonNull where possible for all fields in all services
There was a problem hiding this comment.
|
@CTMBNara Thank you for the review. I've updated the code. Could you please take another look? |
🔧 Type of changes
✨ What's the context?
ID5 wants to have its own module that can enrich bid requests with ID5 universal identifiers. This module fetches identity signals from ID5's API and automatically injects them into OpenRTB bid requests as Extended
Identifiers (EIDs).
🧠 Rationale behind the change
Why a dedicated module?
Key design decisions:
ProcessedAuctionRequestHook): Initiates async ID5 API call early in the request lifecycleBidderRequestHook): Injects EIDs into each bidder request only when not already presentTrade-offs:
🔎 New Bid Adapter Checklist
Not applicable - this is a module, not a bid adapter🧪 Test plan
Unit Tests:
Integration Tests:
sample/directoryManual Testing:
The module has been tested with various configurations and filter combinations to ensure safe production deployment.
🏎 Quality check
🤔 Questions for reviewers
1. Hook invocation status/action handling:
We would particularly appreciate review of our hook invocation status and action returns. Please verify that we're correctly returning:
InvocationStatusvalues in different scenarios (success, failure, skipped)InvocationActionto control execution flow2. Execution plan configuration simplification:
Both hooks (fetch + inject) are required for the module to function - the module is non-functional if either hook is missing from the execution plan. Currently, operators must configure both hooks separately in the
execution plan:
Question: Is there a way to simplify this configuration? For example: