pub async fn validate_subscription_deletion<C>(
txn: &C,
subscription_id: ObjectId,
) -> MetaResult<()>where
C: ConnectionTrait,
Expand description
Validate that subscription can be safely deleted, meeting any of the following conditions:
- The upstream table is not referred to by any cross-db mv.
- After deleting the subscription, the upstream table still has at least one subscription.