diff --git a/modules/oxxionRtdProvider.js b/modules/oxxionRtdProvider.js index c979a10d00c..f968fc10e4b 100644 --- a/modules/oxxionRtdProvider.js +++ b/modules/oxxionRtdProvider.js @@ -23,6 +23,7 @@ function init(config, userConsent) { } function getAdUnits(reqBidsConfigObj, callback, config, userConsent) { + const moduleStarted = new Date(); logInfo(LOG_PREFIX + 'started with ', config); if (typeof config.params.threshold != 'undefined' && typeof config.params.samplingRate == 'number') { let filteredBids; @@ -47,6 +48,11 @@ function getAdUnits(reqBidsConfigObj, callback, config, userConsent) { }); } if (typeof callback == 'function') { callback(); } + const timeToRun = new Date() - moduleStarted; + logInfo(LOG_PREFIX + ' time to run: ' + timeToRun); + if (getRandomNumber(50) == 1) { + ajax('https://' + config.params.domain + '.oxxion.io/ova/time', null, JSON.stringify({'duration': timeToRun, 'auctionId': reqBidsConfigObj.auctionId}), {method: 'POST', withCredentials: true}); + } }).catch(error => logError(LOG_PREFIX, 'bidInterestError', error)); } }