Skip to main content

cancelSubscribeData

cancelSubscribeData

Releases a Provider Instance's real-time subscription immediately. It sends the cancel request straight to the server, with no lifecycle events.

Parameters

  • provInstName (String): The name of the Provider Instance to unsubscribe from

Returns: None (void)

Description

Like unsubscribeData, it sends a subscription-cancel message to the server.

Difference from unsubscribeData:

  • unsubscribeData: fires the onUnsubscribeDataBefore → server cancel → onUnsubscribeDataAfter lifecycle events
  • cancelSubscribeData: sends the server cancel straight from the stored subscription info, with no lifecycle events

Use it when you do not need the lifecycle events, or to clean up quickly when a form is disposed.

Example

// lifecycle 이벤트 없이 즉시 구독 해제
$vm.cancelSubscribeData("stockProvider");

Related

  • $vm.subscribeData(provInstName, callback) — start a real-time subscription
  • $vm.unsubscribeData(provInstName) — release the subscription with lifecycle events
  • $vm.cancelAllSubscribeData() — release every subscription