I came up with a client version and was attempting to connect to a free OPC server here: opc.tcp://opcuaserver:4840
Here is the link to my project, where I run my unit test to get the server timestamp and state
When I run my unit test, I get this error:
May 23, 2019 1:51:40 PM wvlet.log.Logger log
INFO: Using endpoint: opc.tcp://opcuaserver:4840, None
java.net.UnknownHostException: opcuaserver: nodename nor servname provided, or not known
java.util.concurrent.CompletionException: java.net.UnknownHostException: opcuaserver: nodename nor servname provided, or not known
at java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:292)
at java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:308)
at java.util.concurrent.CompletableFuture.uniApply(CompletableFuture.java:593)
at java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:577)
at java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:474)
.....
Any idea why is this?