keepAlive在阿波罗订阅方面遇到了一些麻烦。每当我将时间设置为秒或更多秒时,侦听订阅错误就会退出。
{
"error": "Could not connect to websocket endpoint ws://website.test:8000/graphql. Please check if the endpoint url is correct."
}
这是ApolloServer设置
const apollo = new ApolloServer({
introspection: true,
playground: true,
我正在使用akka-http websocket客户端与websocket服务器连接,用于发送和检索消息。
object WebSocketClientFlow {
def main(args: Array[String]) = {
implicit val system = ActorSystem()
implicit val materializer = ActorMaterializer()
import system.dispatcher
// Future[Done] is the materialized value of Sink.foreach,
// emitted whe
我有一个服务器,它监听套接字上的连接:
public class Server
{
private Socket _serverSocket;
public Server()
{
_serverSocket = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp);
_serverSocket.Bind(new IPEndPoint(IPAddress.Any, 1234));
_serverSocket.Listen(1)