cloud-fs/src/main/java/io/activej/fs/cluster/DiscoveryService.java
/**
	 * A {@code DiscoveryService} that consists of given partitions that never change
	 *
	 * @param partitions constant {@link ActiveFs} partitions
	 * @return a constant discovery service
	 */
A  DiscoveryService that consists of given partitions that never change
@param partitions constant  ActiveFs partitions
@return a constant discovery service
A DiscoveryService that consists of given partitions that never change @param partitions constant ActiveFs partitions @return a constant discovery service
static DiscoveryService constant(Map<Object, ActiveFs> partitions) {
		Map<Object, ActiveFs> constant = Map.copyOf(partitions);
		return () -> new AsyncSupplier<>() {
			int i = 0;
			@Override
			public Promise<Map<Object, ActiveFs>> get() {
				return i++ == 0 ? Promise.of(constant) : new SettablePromise<>();
			}
		};
	}
static DiscoveryService constant ( Map < Object , ActiveFs > partitions ) { Map < Object , ActiveFs > constant = Map . copyOf ( partitions ) ; return ( ) -> new AsyncSupplier < > ( ) { int i = 0 ; @ Override public Promise < Map < Object , ActiveFs > > get ( ) { return i ++ == 0 ? Promise . of ( constant ) : new SettablePromise < > ( ) ; } } ; }
A {@code DiscoveryService} that consists of given partitions that never change
 @param partitions constant {@link ActiveFs} partitions
 @return a constant discovery service
A { @code DiscoveryService } that consists of given partitions that never change @param partitions constant { @link ActiveFs } partitions @return a constant discovery service