public void replaceSubscribers ( Subscribers subscribers ) throws IOException { String payload = gson . toJson ( subscribers ) ; IronReader reader = client . put ( "queues/" + name + "/subscribers" , payload ) ; reader . close ( ) ; }
Sets list of subscribers to a queue . Older subscribers will be removed . If there is no queue an EmptyQueueException is thrown .