Вот упрощенная версия моего кода:
Код: Выделить всё
import java.util.Properties;
import com.toshiba.mwcloud.gs.GridStore;
import com.toshiba.mwcloud.gs.GridStoreFactory;
public class GridDBConnectionTest {
public static void main(String[] args) {
Properties props = new Properties();
props.setProperty("notificationAddress", "239.0.0.1");
props.setProperty("notificationPort", "31999");
try {
GridStore gridstore = GridStoreFactory.getInstance().getGridStore(props);
System.out.println("Successfully connected to GridDB server.");
gridstore.close();
} catch (Exception e) {
System.err.println("Failed to connect to GridDB server: " + e.getMessage());
e.printStackTrace();
}
}
}
Код: Выделить всё
Failed to connect to GridDB server: Error occurred while getting connection: [hosts=239.0.0.1:31999] Failed to connect to any of given addressesМожет ли кто-нибудь объяснить, почему может возникать эта ошибка, и предложить потенциальные решения для ее устранения? Есть ли какие-либо дополнительные шаги настройки или зависимости, которые я мог упустить?
Подробнее здесь: https://stackoverflow.com/questions/783 ... ver-when-a
Мобильная версия