com.netflix.eureka2.service.RegistrationChannel Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of eureka-core Show documentation
Show all versions of eureka-core Show documentation
eureka-core developed by Netflix
package com.netflix.eureka2.service;
import com.netflix.eureka2.registry.InstanceInfo;
import rx.Observable;
/**
* A {@link ServiceChannel} implementation for registration.
*
*
* The following are the states of a {@link RegistrationChannel}
*
*
- Created: Created but no instance registered.
- Registered: Instance registered.
- Unregistered: Instance unregistered but channel opened and hence can get into Registered state again.
- Close: Channel closed. Nothing can be done on this channel anymore.
*
* @author Nitesh Kant
*/
public interface RegistrationChannel extends ServiceChannel {
/**
* Registers the passed instance with eureka.
*
* @param instanceInfo The instance definition.
*
* @return Acknowledgment for the registration.
*/
Observable register(InstanceInfo instanceInfo);
/**
* Updates the {@link InstanceInfo} registered with this channel.
*
* @param newInfo The updated info.
*
* @return Acknowledgment for this update.
*/
Observable update(InstanceInfo newInfo);
/**
* Unregisters the {@link InstanceInfo} associated with this channel.
*
* @return Acknowledgment for unregistration.
*/
Observable unregister();
}