diff --git a/luigi/contrib/mongodb.py b/luigi/contrib/mongodb.py index 7fa44cca80..21490bd43b 100644 --- a/luigi/contrib/mongodb.py +++ b/luigi/contrib/mongodb.py @@ -92,6 +92,14 @@ def write(self, value): """ Write value to the target """ + self.get_collection().insert_one( + value + ) + + def update(self, value): + """ + Update value to the target + """ self.get_collection().update_one( {'_id': self._document_id}, {'$set': {self._path: value}},