Skip to content

Commit

Permalink
feat: add data indexing API
Browse files Browse the repository at this point in the history
  • Loading branch information
csg01123119 committed Aug 14, 2024
1 parent 7fefdc0 commit 9d415be
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 6 deletions.
11 changes: 9 additions & 2 deletions test/browser/browser.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2809,8 +2809,15 @@ describe('browser', () => {
]
},
aggregations: [
{ field: 'Size', operation: 'sum' },
{ field: 'OSSTaggingCount', operation: 'min' }
{ field: 'ETag', operation: 'count' },
{ field: 'FileModifiedTime', operation: 'distinct' },
{ field: 'Filename', operation: 'group' },
{ field: 'ObjectACL', operation: 'group' },
{ field: 'OSSCRC64', operation: 'distinct' },
{ field: 'OSSStorageClass', operation: 'group' },
{ field: 'OSSTaggingCount', operation: 'max' },
{ field: 'ServerSideEncryption', operation: 'group' },
{ field: 'Size', operation: 'sum' }
]
};

Expand Down
15 changes: 11 additions & 4 deletions test/node/bucket.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -1650,7 +1650,7 @@ describe('test/bucket.test.js', () => {
assert(result.aggregations[0].field, 'Size');
});

it('doMetaQuery() two Aggregations', async () => {
it.only('doMetaQuery() two Aggregations', async () => {
const queryParam = {
maxResults: 2,
query: {
Expand All @@ -1661,8 +1661,15 @@ describe('test/bucket.test.js', () => {
]
},
aggregations: [
{ field: 'Size', operation: 'sum' },
{ field: 'OSSTaggingCount', operation: 'min' }
{ field: 'ETag', operation: 'count' },
{ field: 'FileModifiedTime', operation: 'distinct' },
{ field: 'Filename', operation: 'group' },
{ field: 'ObjectACL', operation: 'group' },
{ field: 'OSSCRC64', operation: 'distinct' },
{ field: 'OSSStorageClass', operation: 'group' },
{ field: 'OSSTaggingCount', operation: 'max' },
{ field: 'ServerSideEncryption', operation: 'group' },
{ field: 'Size', operation: 'sum' }
]
};

Expand All @@ -1676,7 +1683,7 @@ describe('test/bucket.test.js', () => {
it('closeMetaQuery()', async () => {
const result = await store.closeMetaQuery(sts.bucket);
assert.strictEqual(result.status, 200);
// await utils.sleep(sleepTime);
await utils.sleep(sleepTime * 2);
});
});
});
Expand Down

0 comments on commit 9d415be

Please sign in to comment.