Mongorestore command always fails with expected an object

I am using MongoDB version 4.4.
mongodump and mongorestore version: 100.1.0

mongorestore --port 27017 --oplogReplay “/365784/local/oplog_replay_input”
[2020-10-09T15:12:08.618+0530 preparing collections to restore from
2020-10-09T15:12:08.618+0530 replaying oplog
2020-10-09T15:12:08.676+0530 Failed: restore error: error applying oplog: applyOps: (Location10065) invalid parameter: expected an object ()
2020-10-09T15:12:08.676+0530 0 document(s) restored successfully. 0 document(s) failed to restore.
]

# bsondump oplog.bson
.
.
2020-10-09T15:19:47.624+0530    1350 objects found

It again failed with this error. This is just the dump of oplog collection that is being applied during restore.

mongorestore --port 27019 --oplogReplay “365916/local/oplog_replay_input”
2020-10-09T18:31:41.317+0530 preparing collections to restore from
2020-10-09T18:31:41.318+0530 replaying oplog
2020-10-09T18:31:41.392+0530 Failed: restore error: error applying oplog: applyOps: (Location40528) Direct writes against config.transactions cannot be performed using a transaction or on a session.
2020-10-09T18:31:41.392+0530 0 document(s) restored successfully. 0 document(s) failed to restore.