aboutsummaryrefslogtreecommitdiffstats
path: root/packages/pipeline/src/scripts/pull_radar_relay_orders.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/pipeline/src/scripts/pull_radar_relay_orders.ts')
-rw-r--r--packages/pipeline/src/scripts/pull_radar_relay_orders.ts11
1 files changed, 6 insertions, 5 deletions
diff --git a/packages/pipeline/src/scripts/pull_radar_relay_orders.ts b/packages/pipeline/src/scripts/pull_radar_relay_orders.ts
index 03fc764f2..8e8720803 100644
--- a/packages/pipeline/src/scripts/pull_radar_relay_orders.ts
+++ b/packages/pipeline/src/scripts/pull_radar_relay_orders.ts
@@ -1,5 +1,6 @@
-// tslint:disable:no-console
import { HttpClient } from '@0x/connect';
+import { logUtils } from '@0x/utils';
+
import * as R from 'ramda';
import 'reflect-metadata';
import { Connection, ConnectionOptions, createConnection, EntityManager } from 'typeorm';
@@ -21,13 +22,13 @@ let connection: Connection;
})().catch(handleError);
async function getOrderbookAsync(): Promise<void> {
- console.log('Getting all orders...');
+ logUtils.log('Getting all orders...');
const connectClient = new HttpClient(RADAR_RELAY_URL);
const rawOrders = await connectClient.getOrdersAsync({
perPage: ORDERS_PER_PAGE,
});
- console.log(`Got ${rawOrders.records.length} orders.`);
- console.log('Parsing orders...');
+ logUtils.log(`Got ${rawOrders.records.length} orders.`);
+ logUtils.log('Parsing orders...');
// Parse the sra orders, then add source url to each.
const orders = R.pipe(
parseSraOrders,
@@ -35,7 +36,7 @@ async function getOrderbookAsync(): Promise<void> {
)(rawOrders);
// Save all the orders and update the observed time stamps in a single
// transaction.
- console.log('Saving orders and updating timestamps...');
+ logUtils.log('Saving orders and updating timestamps...');
const observedTimestamp = Date.now();
await connection.transaction(
async (manager: EntityManager): Promise<void> => {