feat: document the new BulkLoad streaming API
chdh opened this issue · comments
Hi @chdh , Thanks for bringing this up. We just did read through the doc again and seems the docs have been updated to the new APIs by changes from #1352
For example: under the bulk load page: under the example, instead of calling add rows, it now uses a rows array:
connection.execBulkLoad(bulkLoad, [
{ myInt: 7, myString: 'hello' },
{ myInt: 23, myString: 'world' }
]);
Also, the function declaration has been updated from the connection API page as well.
I am kind of wondering which part of the doc you worried that is not yet been properly documented yet? Can you give us an example or there is some other docs that are outdated and missing this update?
- It's not documented how to use
BulkLoad
with a Stream.
Instead of an array (or anotherIterable
), anAsyncIterable
(e.g.stream.Readable
) can be passed in therows
parameter ofconnection.execBulkLoad()
.
There is no explicit description for therows
parameter. - The
options
parameter is missing in the function signature ofconnection.newBulkLoad()
.
The missingoptions
parameter is documented under usage instead. - It's not documented that two kinds of record structures can be used for the rows of the data stream:
a) Name/value object structure:{columnName1: columnValue1, columnName2: columnValue2, ...}
b) Array of values:[columnValue1, columnValue2, ...]
Btw: #1307 is still open, but BulkLoad.addRow()
and BulkLoad.getRowStream()
have been removed in version 14.0.0.
Hi @chdh, we just created a task for adding the missing detail for this new Bulk API. We will also include you in the reviewer list when we actually finish the changes for the doc. Thanks for bringing this up!
Thanks @mShan0, looks fine.