pub async fn perform_actor_auction(
        &self,
        actor_ref: &str,
        constraints: HashMap<String, String>,
        timeout: Duration,
    ) -> Result<Vec<ActorAuctionAck>> {
        let subject = broker::actor_auction_subject(&self.nsprefix);
        let bytes = serialize(ActorAuctionRequest {
            actor_ref: actor_ref.to_string(),
            constraints,
        })?;
        let sub = self.nc.request_multi(&subject, bytes).await?;
        let actors = SubscriptionStream::new(sub)
            .collect(timeout, "actor auction")
            .await;
        Ok(actors)
    }
/// Performs an actor auction within the lattice, publishing a set of constraints and the metadata for the actor
/// in question. This will always wait for the full period specified by _duration_, and then return the set of
/// gathered results. It is then up to the client to choose from among the "auction winners" to issue the appropriate
/// command to start an actor. Clients cannot assume that auctions will always return at least one result.
Performs an actor auction within the lattice, publishing a set of constraints and the metadata for the actor
in question. This will always wait for the full period specified by _duration_, and then return the set of
gathered results. It is then up to the client to choose from among the "auction winners" to issue the appropriate
command to start an actor. Clients cannot assume that auctions will always return at least one result.
Performs an actor auction within the lattice publishing a set of constraints and the metadata for the actor in question . This will always wait for the full period specified by _duration_ and then return the set of gathered results . It is then up to the client to choose from among the " auction winners " to issue the appropriate command to start an actor . Clients cannot assume that auctions will always return at least one result .
pub async fn perform_actor_auction(
        &self,
        actor_ref: &str,
        constraints: HashMap<String, String>,
        timeout: Duration,
    ) -> Result<Vec<ActorAuctionAck>> {
        let subject = broker::actor_auction_subject(&self.nsprefix);
        let bytes = serialize(ActorAuctionRequest {
            actor_ref: actor_ref.to_string(),
            constraints,
        })?;
        let sub = self.nc.request_multi(&subject, bytes).await?;
        let actors = SubscriptionStream::new(sub)
            .collect(timeout, "actor auction")
            .await;
        Ok(actors)
    }
pub async fn perform_actor_auction ( & self , actor_ref : & str , constraints : HashMap < String , String > , timeout : Duration , ) -> Result < Vec < ActorAuctionAck > > { let subject = broker :: actor_auction_subject ( & self . nsprefix ) ; let bytes = serialize ( ActorAuctionRequest { actor_ref : actor_ref . to_string ( ) , constraints , } ) ? ; let sub = self . nc . request_multi ( & subject , bytes ) . await ? ; let actors = SubscriptionStream :: new ( sub ) . collect ( timeout , " " ) . await ; Ok ( actors ) }
Performs an actor auction within the lattice, publishing a set of constraints and the metadata for the actor
in question.
Performs an actor auction within the lattice publishing a set of constraints and the metadata for the actor in question .
&self
actor_ref
&str
constraints
HashMap<String, String>
timeout
Duration
&self
actor_ref
&str
constraints
HashMap<String, String>
timeout
Duration