public class OpenXAdapter extends ExchangeAdapterImpl<OpenRtbRequest,OpenRtbResponse>
ExchangeAdapter.BidChoiceAlgorithm| Modifier and Type | Field and Description |
|---|---|
private OpenXConfig |
config |
private static SsRtbCrypter |
OPENX_CRYPTER |
static String |
RESPONSE_MEDIA_TYPE |
| Constructor and Description |
|---|
OpenXAdapter() |
| Modifier and Type | Method and Description |
|---|---|
String |
checkExchangeTargeting(OpenRtbRequest req,
Impression imp,
ExchangeTargeting targeting)
Check any exchange-specific targeting.
|
OpenRtbRequest |
convertRequest(OpenRtbRequest req) |
OpenRtbResponse |
convertResponse(OpenRtbRequest req,
OpenRtbResponse o) |
ExchangeAdapter.BidChoiceAlgorithm |
getBidChoiceAlgorithm()
We put RANDOM here but only because we don't want the default "ALL" - so that we properly key
the BidInFlightInfo object.
|
String |
getClickEncMacro() |
String |
getClickMacro() |
long |
getDefaultTimeout()
What is the default timeout, in milliseconds (default, because timeout can also be provided
dynamically as
OpenRtbRequest.getTmax() on each request, which takes precedence). |
private SecretKeySpec |
getKeySpec(String keyStr) |
String |
getName() |
String |
getResponseMediaType() |
String |
getSampleWinningPrice()
Return sample winning price suitable for decoding with
ExchangeAdapter.parse(String, long) |
String |
getWinningPriceMacro()
Winning price macro.
|
long |
getWinTimeout()
How long, in seconds, to wait, before declaring a loss.
|
boolean |
localUserMapping()
Whether the mapping of
our user ID to exchange
ID is stored by us. |
Bid |
massageBid(OpenRtbRequest req,
Impression imp,
Tag tag,
Bid bid)
Post-process a bid.
|
ParsedPriceInfo |
parse(String winningPriceString,
long bidMicros) |
boolean |
trueWinOnNurlOrImpression()
Whether the true win is known by the
winning price, gotten
either during the call of NUrl or out of band. |
toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitdebug, error, error, fillPlatformInfoFromUa, getOptoutBuilder, getPartnerInitiatedSyncUrl, getSeat, info, isAggregator, isMacrosInNurl, isNurlRequired, makeExchangeSpecificInstructionsMap, parseUserId, setHeaders, trace, validateAdprivate static final SsRtbCrypter OPENX_CRYPTER
private final OpenXConfig config
public static final String RESPONSE_MEDIA_TYPE
public OpenXAdapter()
throws Lot49Exception
Lot49Exceptionpublic long getWinTimeout()
ExchangeAdapterpublic ExchangeAdapter.BidChoiceAlgorithm getBidChoiceAlgorithm()
public final long getDefaultTimeout()
ExchangeAdapterOpenRtbRequest.getTmax() on each request, which takes precedence).public final String getSampleWinningPrice()
ExchangeAdapterExchangeAdapter.parse(String, long)public final String getWinningPriceMacro()
ExchangeAdapterExchangeAdapter.parse(String, long)public final boolean localUserMapping()
ExchangeAdapterour user ID to exchange
ID is stored by us.public final OpenRtbRequest convertRequest(OpenRtbRequest req) throws Throwable
Throwablepublic String getName()
public OpenRtbResponse convertResponse(OpenRtbRequest req, OpenRtbResponse o) throws Exception
Exceptionpublic ParsedPriceInfo parse(String winningPriceString, long bidMicros) throws Throwable
ThrowableExchangeAdapter.getWinningPriceMacro()private final SecretKeySpec getKeySpec(String keyStr) throws UnsupportedEncodingException, org.apache.commons.codec.DecoderException
UnsupportedEncodingExceptionorg.apache.commons.codec.DecoderExceptionpublic String getClickMacro()
public String getClickEncMacro()
public boolean trueWinOnNurlOrImpression()
ExchangeAdapterwinning price, gotten
either during the call of NUrl or out of band. For example, OpenX
does the latter, and so a true Win should be registered in
StatsSvc.resultsOpenX(javax.ws.rs.core.UriInfo, String, com.enremmeta.rtb.proto.openx.AuctionResultMessage, String, javax.servlet.http.HttpServletRequest, String, javax.ws.rs.core.HttpHeaders)StatsSvc#nurl(javax.ws.rs.core.UriInfo, String, String, String, String, String, String,
String, String, String, String, long, String, String, String, String, String, String,
javax.servlet.http.HttpServletRequest, String, String, String, String, String),
LogUtils.logWin(String, String, String, String, String, String, String, double, long,
long, long, String, String, String, String, String,
javax.servlet.http.HttpServletRequest, String, Long, String, java.net.URI, boolean,
String, String, String, String, String, String, boolean, boolean, String),
StatsSvc.impression(javax.ws.rs.core.UriInfo, String, String, String, String, String,
String, String, String, String, long, String, int, String, String, String, String,
String, String, String, javax.servlet.http.HttpServletRequest, String,
javax.ws.rs.core.HttpHeaders, String, String)public String checkExchangeTargeting(OpenRtbRequest req, Impression imp, ExchangeTargeting targeting)
ExchangeAdapterExchangeAdapter.checkExchangeTargeting(OpenRtbRequest, Impression, ExchangeTargeting)MatchingAdIdpublic Bid massageBid(OpenRtbRequest req, Impression imp, Tag tag, Bid bid)
ExchangeAdapterTag.getBid(OpenRtbRequest, Impression)public String getResponseMediaType()