Search in sources :

Example 1 with AzureRedis

use of com.microsoft.azure.toolkit.redis.AzureRedis in project azure-tools-for-java by Microsoft.

the class RedisCachePropertyView method onReadProperty.

@Override
public void onReadProperty(String sid, String id) {
    AzureRedis az = Azure.az(AzureRedis.class).subscription(sid);
    Mono.fromCallable(() -> az.get(id).entity()).map(redis -> {
        RedisCacheProperty property = new RedisCacheProperty(redis.getName(), redis.getType(), redis.getResourceGroupName(), redis.getRegion().getName(), sid, redis.getRedisVersion(), redis.getSSLPort(), redis.getNonSslPortEnabled(), redis.getPrimaryKey(), redis.getSecondaryKey(), redis.getHostName());
        return property;
    }).subscribeOn(Schedulers.boundedElastic()).subscribe(property -> {
        this.showProperty(property);
    });
}
Also used : AzureRedis(com.microsoft.azure.toolkit.redis.AzureRedis) RedisCacheProperty(com.microsoft.azuretools.core.mvp.ui.rediscache.RedisCacheProperty)

Aggregations

AzureRedis (com.microsoft.azure.toolkit.redis.AzureRedis)1 RedisCacheProperty (com.microsoft.azuretools.core.mvp.ui.rediscache.RedisCacheProperty)1