Skip to content

Pipeline is freeze at try search or delete documents #7363

@wazzu3000

Description

@wazzu3000

Hello, currently I'm working with Pipeline new feature, but this is freeze at try to remove a document

Issue detauls:

  • This issue was detected from 16.13.0 version but still occurring with 16.19.0.
  • I'm working with Windows 11
  • My web browser is Microsoft Edge

I share with you, my code to reproduce it.

    reminderCollection.addPipeline({
      identifier: 'reminder-schedule',
      destination: remindersScheduleCollection,
      handler: async docs => {
        for (let reminder of docs) {
          if (reminder.deleted) {
            await this.remindersScheduleCollection.findByIds([ reminder.id ]).remove();
            // I tried with these other ways but the code still freeze
            // await this.remindersScheduleCollection.findOne({ selector: { id: reminder.id } }).remove();
            // await this.remindersScheduleCollection.find({ selector: { id: reminder.id } }).remove();
          }
        }

        // Additionally, I tried applying a bulkRemove but the result are same
        // await this.remindersScheduleCollection.bulkRemove(docs.map(doc => doc.id))
      }
    });

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions