Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vdsm-jsonrpc-java Connecting error #25

Closed
midieyz opened this issue Oct 27, 2022 · 1 comment
Closed

vdsm-jsonrpc-java Connecting error #25

midieyz opened this issue Oct 27, 2022 · 1 comment

Comments

@midieyz
Copy link

midieyz commented Oct 27, 2022

bro, help!
version: ovirt 4.3.10, vdsm-jsonrpc-java-client 1.4.18

result error:
2022-10-27 11:15:56.163 INFO 5696 --- [ Stomp Reactor] o.o.v.j.client.reactors.ReactorClient : Connecting to /10.42.200.63
2022-10-27 11:15:56.170 ERROR 5696 --- [ Stomp Reactor] o.o.v.jsonrpc.client.reactors.Reactor : Unable to process messages 远程主机强迫关闭了一个现有的连接。
<JsonRpcResponse id: null error: {"code":5022,"message":"远程主机强迫关闭了一个现有的连接。"}>

test code:
` String hostName = "10.42.200.63";
int port = 54321;
int clientTimeout = 100000;
int connectionRetry = 0;
int heartbeat = 3000;
int parallelism = 30000;
int eventTimeoutInHours = 100000;
int connectionTimeout =300000;
String eventQueue = "queue";
ScheduledExecutorService executorService = new ScheduledThreadPoolExecutor(1);
StompClientPolicy connectionPolicy =
new StompClientPolicy(connectionTimeout,
connectionRetry,
heartbeat,
IOException.class,
DEFAULT_REQUEST_QUEUE,
DEFAULT_RESPONSE_QUEUE);
connectionPolicy.setEventQueue(eventQueue);
ClientPolicy clientPolicy = new ClientPolicy(clientTimeout, connectionRetry, heartbeat, IOException.class);

    final Reactor reactor = ReactorFactory.getReactor(null, ReactorType.STOMP);
    final ReactorClient client = reactor.createClient(hostName, port);

    client.setClientPolicy(connectionPolicy);
    ResponseWorker worker = ReactorFactory.getWorker(parallelism, eventTimeoutInHours);
    JsonRpcClient jsonClient = worker.register(client);
    jsonClient.setRetryPolicy(clientPolicy);
    jsonClient.setExecutorService(executorService);

    JsonRpcRequest request = new RequestBuilder("Host.getCapabilities").build();
    Future<JsonRpcResponse> call = jsonClient.call(request);
    JsonRpcResponse jsonRpcResponse = call.get();
    System.out.println(jsonRpcResponse);

`

@sandrobonazzola
Copy link
Member

Closing as 4.3 gone EOL long time ago. Please upgrade to latest oVirt release and if problem still exists please open a new issue.

@sandrobonazzola sandrobonazzola closed this as not planned Won't fix, can't repro, duplicate, stale Jun 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants