-
Notifications
You must be signed in to change notification settings - Fork 190
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
Added medianet adapter #1378
Added medianet adapter #1378
Conversation
src/test/java/org/prebid/server/bidder/medianet/MedianetBidderTest.java
Outdated
Show resolved
Hide resolved
src/test/java/org/prebid/server/bidder/medianet/MedianetBidderTest.java
Outdated
Show resolved
Hide resolved
src/test/java/org/prebid/server/bidder/medianet/MedianetBidderTest.java
Outdated
Show resolved
Hide resolved
src/main/java/org/prebid/server/spring/config/bidder/MedianetConfiguration.java
Outdated
Show resolved
Hide resolved
src/main/java/org/prebid/server/bidder/medianet/MedianetBidder.java
Outdated
Show resolved
Hide resolved
src/test/resources/org/prebid/server/it/openrtb2/medianet/test-auction-medianet-request.json
Outdated
Show resolved
Hide resolved
Hey, @And1sS @snahornyi . |
… medianet-adapter-integration
public class MedianetBidderTest extends VertxTest { | ||
|
||
private static final String ENDPOINT_URL = "https://test.media.net?src=external.prebidserver.com"; | ||
private static final BidRequest DUMMY_REQUEST = BidRequest.builder() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We prefer to use givenBidRequest method, you can check examples in another test classes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed to 'given' nomenclature
String encodedExternalUrl = HttpUtil.encodeUrl(externalUrl); | ||
String bidderEndpoint = configEndpoint.replace(EXTERNAL_URL_MACRO, encodedExternalUrl); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
56 line can be merged to 57 and also we prefer to declare variables as final
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And even more better, pls create create method resolveEndpoint
and then pass it to constructor, which will be in medianetBidderDeps
method
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
private String resolveEndpoint(String configEndpoint) {
return configEndpoint.replace(EXTERNAL_URL_MACRO, HttpUtil.encodeUrl(externalUrl));
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added this method, and calling it in medianetBidderDeps()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks)
Adds Media.Net Bidder Adapter.
Vendor ID: 142
Maintainer Email: prebid@media.net