Sends all the subscriptions for the specified schedule
185244
def send(self, request, pk=None):
        
        schedule = self.get_object()
        queue_subscription_send.delay(str(schedule.id))

        return Response({}, status=status.HTTP_202_ACCEPTED)
74318
static <T> void subscribe(Subscriber<? super T> s, Iterator<? extends T> it) {
        if (it == null) {
            error(s, new NullPointerException("The iterator is null"));
            return;
        }

        boolean b;

        try {
            b = it.hasNext();
        } catch (Throwable e) {
            error(s, e);
            return;
        }

        if (!b) {
           complete(s);
            return;
        }

        s.onSubscribe(new IterableSubscription<T>(s, it));

    }
510420
def execute_all(event, object)
      each_subscription_id(event) do |subscription_id|
        execute(subscription_id, event, object)
      end
    end
823298
def schedule(self, when=None, action=None, **kwargs):
        
        action = '_publish'
        super(BaseVersionedModel, self).schedule(when=when, action=action,
                                                 **kwargs)
523273
def _subscribed(self):
        
        self.logger.debug('Subscription confirmed.')
        self.state = 'subscribed'
        for message in self.message_queue:
            self.send(message)
862412
function() {
    if (!this.hasOwnProperty("_postalSubscriptions")) {
        this._postalSubscriptions = {};
    }
    for (var topic in this.subscriptions) {
      if (this.subscriptions.hasOwnProperty(topic)) {
        var callback = this.subscriptions[topic];
        this.subscribe(topic, callback);
      }
    }
  }
951937
function (event) {
    this.debug("Requesting subscription for " + event);
    sendReceive.call(this, {'do': 'subscribe', params: [event]}, function (result) {
        if (result.success) {
            this.debug("Succesfully subscribed to %s", event);
        } else {
            this.debug("Subscription request for %s failed", event);
        }
    });
    this.subscribedEvents.push(event);
}
787950
function (subscriptions, fn, context) {
  for (var id in subscriptions) {
    for (var property in subscriptions[id]) {
      fn.call(context, subscriptions[id][property], property, id);
    }
  }
}
619697
def schedule_saved(sender, instance, **kwargs):
    
    from contentstore.tasks import sync_schedule

    sync_schedule.delay(str(instance.id))
10236
public static SubscriptionSchedule retrieve(String schedule) throws StripeException {
    return retrieve(schedule, (Map<String, Object>) null, (RequestOptions) null);
  }
483649
function Subscription (queue, options) {
        assert.object(queue, 'queue');
        assert.object(options, 'options');

        this.MAX_DISPOSE_RETRIES = 3;
        this.retryDelay = 1000;
        this.queue = queue;
        this.options = options;
        this._disposed = false;
    }
51465
@MainThread
    private void scheduleSubscribersInvocation(Event event) {
        for (EventTarget target : targets) {
            for (EventMethod method : target.methods) {
                if (event.getKey().equals(method.eventKey)
                        && method.type == EventMethod.Type.SUBSCRIBE) {

                    Utils.log(event.getKey(), method, "Scheduling event execution");

                    ((EventBase) event).handlersCount++;

                    Task task = Task.create(this, target, method, event);
                    executionQueue.add(task);
                }
            }
        }
    }
327591
def subscriptions(options = {})
      batches = Enumerator.new do |y|
        resp = @client.list_subscriptions(options)
        resp.each_page do |page|
          batch = []
          page.data.subscriptions.each do |s|
            batch << Subscription.new(
              arn: s.subscription_arn,
              client: @client
            )
          end
          y.yield(batch)
        end
      end
      Subscription::Collection.new(batches)
    end
1167052
public void _onSubscribe(Subscription subscription) {
        producer = subscription;
        ArrayList<Runnable> tmp = this.doOnSubscribe;
        this.doOnSubscribe = null;
        tmp.forEach(runnable -> runnable.run());
    }
415095
def prepare_dispatches(cls, message, recipients=None):
        
        return Dispatch.create(message, recipients or cls.get_subscribers())
1334963
def _scheduleMePlease(self):
        
        sched = IScheduler(self.store)
        if len(list(sched.scheduledTimes(self))) == 0:
            sched.schedule(self, sched.now())
1144035
def get_subscriptions(self, fetch=False):
        """"""
        return Subscriptions(
            self.resource.subscriptions, self.client, populate=fetch)