6 months ago
I'm trying to get 2 services to communicate with each other via websockets. One is at chain.domain.tld, and the other doesn't really need a url because it's connecting to the first. The problem I'm running into while starting the first server is this:
Error: getaddrinfo ENOTFOUND chain.domain.tld
and this is despite the fact that I already successfully added the domain to that server's config
what's going on?
1 Replies
I'm not sure what's going on. It works on localhost and I just want it to work
6 months ago
can you give the actual error please
Failed to start lead validator node: Error: getaddrinfo ENOTFOUND chain.uranus.computer
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:107:26) {
errno: -3008,
code: 'ENOTFOUND',
syscall: 'getaddrinfo',
hostname: 'chain.uranus.computer'
}
6 months ago
first can you get grand-endurance into an active state?
and now the domain says this:
Incorrect value "corrugated-tundra-w2mwht6y97yot99flzuvtgyd.herokudns.com"
when I reboot it up
6 months ago
how are you doing the dns lookup
6 months ago
getaddrinfo is a dns lookup
6 months ago
of course not, its internal to node
literally just this I'm pretty sure?
const app = express();
const httpServer = createServer(app);
// Create a single WebSocketServer from our HTTP server
const wss = new WebSocketServer({ server: httpServer });
nobody is looking up anything
6 months ago
Failed to start lead validator node: Error: Unexpected server response: 503
6 months ago
its an issue at the application level, its not something we could help with unfortunately
it runs on localhost and breaks as soon as it gets deployed on railway so how could it be an application level error
6 months ago
working locally does not mean its not an issue with the code
so if the code is working, it doesn't mean it's not an issue with the code not working?
dude could you just help me get it working? It's literally 2 servers that want to talk to each other through websockets. It really shouldn't be this hard. I built an entire blockchain and none of it was as hard as getting 2 websocket servers talking to each other. This is retorded.
6 months ago
im sorry but the error doesn't pertain to the Railway platform or product so we wouldn't be able to offer support, I'll have to step out here and let the community members help if they so choose
This literally pertains to the railway platform to the maximum. Are you going to tell your investors that it's node's fault when your revenue goes down $5/month when I cancel?
This error usually means:
Node.js attempted to resolve the hostname chain.uranus.computer, but DNS resolution failed. In other words, the DNS lookup returned "hostname not found."
That can happen if:
The domain name truly doesn’t exist or has no DNS record.
The DNS record is too new, and some hosts or providers haven’t recognized it yet.
The DNS record is correct, but the environment (in this case, Railway) cannot reach that domain from its network or Docker container.
A misspelling or incomplete domain name.
So railway's dns service doesn't work
6 months ago
dns is working fine on our side -
I'm using internal railway urls now and I CANNOT get this shit to work no matter what:
Failed to start lead validator node: Error: connect ECONNREFUSED fd12:43b0:f15a::25:d83:39cb:8545
at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1555:16) {
errno: -111,
code: 'ECONNREFUSED',
syscall: 'connect',
address: 'fd12:43b0:f15a::25:d83:39cb',
port: 8545
}
6 months ago
please see our docs on this topic -
6 months ago
cc @xxxxx - I find you a bit funny so will offer my two cents, the issue is that the validator isn't running, so it will fail regardless
6 months ago
The error I am seeing is:
Failed to start lead validator node: Error: write EPROTO 40FC0480A47F0000:error:0A0000C6:SSL routines:tls_get_more_records:packet length too long:ssl/record/methods/tls_common.c:662:
at WriteWrap.onWriteComplete [as oncomplete] (node:internal/stream_base_commons:94:16) {
errno: -71,
code: 'EPROTO',
syscall: 'write'
}
6 months ago
So it may be a node version issue if the one on your machine is different than the one we are loading
I have written an entire blockchain from scratch and the only time I've had issues is when I've had to deal with websockets. Node's implementation of websockets is re-tarded, and I'm going to rip it out and replace it with libp2p or something.
6 months ago
its less the websocket impl- its the crashes
6 months ago
so if you are trying to connect to a crashed service, it's going to fail 😢
works on localhost dawg
6 months ago
yes-
6 months ago
so my question stands, do you know if we are working with the same node version or something?
6 months ago
We only support tha LTS I think
6 months ago
that would cause problems
6 months ago
One thing that would work is dockerizing
6 months ago
you can claude up a image ez
Also I don't understand why you are saying that it's two internal services if your chain Uranus whatever is hosted on render and not railway
5 months ago
Hey i got it working using the TCP proxy in the settings under networking. I couldnt get it working with the railway private domain <service-name>.railway.internal had to use the TCP proxy, not sure why.