-
Notifications
You must be signed in to change notification settings - Fork 78
Closed
Labels
Description
Hello,
ArangoDB bulk import supports onDuplicate (error, update, replace, ignore) option.
Could you please implement this one?
Implementation Proposal
This gives an forward compatibility and opportunity to pass custom options to endpoint:
- Add
**kwtoCollection.import_bulksignature. - Overwrite
type,collection,completekeys with current Request params - Use resulting dict as Request params.
Example
891c891
< def import_bulk(self, documents, halt_on_error=True, details=True):
---
> def import_bulk(self, documents, halt_on_error=True, **kwargs):
910a911,914
> kwargs['type'] = 'array'
> kwargs['collection'] = self._name
> kwargs['complete'] = halt_on_error
>
915,920c919
< params={
< 'type': 'array',
< 'collection': self._name,
< 'complete': halt_on_error,
< 'details': details
< }
---
> params=kwargs