Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Mongodb Odm Softdelete Laravel Package

doctrine/mongodb-odm-softdelete

Adds soft delete support to Doctrine MongoDB ODM. Mark documents as deleted without removing them, with automatic filtering of deleted records from queries and options to restore or include trashed documents. Integrates cleanly with ODM repositories and event system.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Feature Development: Enables soft delete functionality for MongoDB-based applications, allowing data to remain accessible for auditing, compliance, or recovery without permanent deletion.
  • Data Retention & Compliance: Supports regulatory requirements (e.g., GDPR) where data must be retained but logically "deleted" for user privacy.
  • Build vs. Buy: Avoids reinventing soft-delete logic for MongoDB ODM, reducing development time and technical debt.
  • Roadmap Prioritization: Justifies adding soft-delete features to a product backlog if data lifecycle management is a priority (e.g., SaaS platforms, analytics tools, or enterprise apps).
  • User Experience: Improves UX by allowing users to "undelete" or restore records accidentally marked as deleted.

When to Consider This Package

  • Use Case Alignment: Only relevant if your application uses Doctrine MongoDB ODM and requires soft-delete functionality (e.g., no hard deletes needed).
  • Architecture Constraints: Avoid if your stack doesn’t use MongoDB or Doctrine ODM (e.g., SQL databases, custom NoSQL solutions, or ORMs like Eloquent).
  • Maintenance Risk: Since the package is archived, evaluate if the project is actively maintained or if a fork exists. Consider alternatives like:
    • Custom soft-delete implementation (if MongoDB ODM is critical).
    • Switching to a maintained package (e.g., spatie/laravel-soft-deletes for Eloquent).
  • Performance Needs: Soft deletes add overhead for queries (e.g., filtering out deleted records). Assess if this impacts scalability or latency.
  • Alternatives Exist: If using Laravel/Eloquent, built-in soft deletes may suffice without MongoDB ODM.

How to Pitch It (Stakeholders)

For Executives: "This package lets us implement soft deletes in our MongoDB-driven app without building it from scratch, saving dev time while meeting compliance needs. For example, [Product X] could use this to retain user data for audits but hide it from active views—reducing risk and improving flexibility. The trade-off is minimal maintenance risk (since it’s archived), but we’d need to validate if a fork or alternative fits our stack better."

For Engineering: *"If we’re using Doctrine MongoDB ODM and need soft deletes (e.g., for [use case]), this package cuts dev time by ~[X] hours. Key pros:

  • Pros: Standardized soft-delete behavior, auditing support.
  • Cons: Archived (check for forks), adds query complexity. Alternatives: Custom logic or Eloquent’s built-in soft deletes if we’re not locked into MongoDB ODM. Recommend a spike to compare options."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
terminal42/code-quality-tools
codifyo/ts-generator-bundle
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky
spatie/mailcoach-vapor