-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
v1-to-v2-migrator/src/dumpSourceData.js
module.exports = () => {
logStep('Dumping source data', true);
const timestampFilter = config.timestamp ? [`stored: {$gte: new Date("${config.timestamp}")}`] : [];
const createdAtFilter = config.timestamp ? [`created_at: {$gte: new Date("${config.timestamp}")}`] : [];
const lrsIDFilter = config.source.lrsId ? [`lrs_id: ObjectId("${config.source.lrsId}")`] : [];
const lrsFilter = config.source.lrsId ? [`_id: ObjectId("${config.source.lrsId}")`] : [];
const statementFilter = createQueryFilter(['active: true'].concat(lrsIDFilter, timestampFilter));
const documentFilter = createQueryFilter(lrsIDFilter.concat(createdAtFilter)); // **** Question 1
const clientFilter = createQueryFilter(lrsIDFilter);
const storeFilter = createQueryFilter(lrsFilter);
return Promise.all([
dumpCollection('statements', statementFilter),
dumpCollection('documentapi', documentFilter), // **** Question 2
dumpCollection('client', clientFilter),
dumpCollection('lrs', storeFilter),
]);
};Question 1 :
documentapi table not available in LRS V1.
So, I want to know about that "documentapi" referese to which table in LRS V1.
Question 2 :
const timestampFilter = config.timestamp ? [stored: {$gte: new Date("${config.timestamp}")}] : [];
can we creates a any config JSON to take timestamp and so many fixed value which are used in source code.
Metadata
Metadata
Assignees
Labels
No labels
