Fix Github error override commit [952a5bd87c
]
This commit is contained in:
parent
5466bd1d68
commit
320c68c88e
@ -123,7 +123,13 @@ export class SocketManager implements ZoneEventListener {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
.on("end", () => {
|
.on("end", () => {
|
||||||
console.warn("Admin connection lost to back server");
|
console.warn(
|
||||||
|
"Admin connection lost to back server '" +
|
||||||
|
apiClient.getChannel().getTarget() +
|
||||||
|
"' for room '" +
|
||||||
|
roomId +
|
||||||
|
"'"
|
||||||
|
);
|
||||||
// Let's close the front connection if the back connection is closed. This way, we can retry connecting from the start.
|
// Let's close the front connection if the back connection is closed. This way, we can retry connecting from the start.
|
||||||
if (!client.disconnecting) {
|
if (!client.disconnecting) {
|
||||||
this.closeWebsocketConnection(client, 1011, "Admin Connection lost to back server");
|
this.closeWebsocketConnection(client, 1011, "Admin Connection lost to back server");
|
||||||
@ -131,7 +137,14 @@ export class SocketManager implements ZoneEventListener {
|
|||||||
console.log("A user left");
|
console.log("A user left");
|
||||||
})
|
})
|
||||||
.on("error", (err: Error) => {
|
.on("error", (err: Error) => {
|
||||||
console.error("Error in connection to back server:", err);
|
console.error(
|
||||||
|
"Error in connection to back server '" +
|
||||||
|
apiClient.getChannel().getTarget() +
|
||||||
|
"' for room '" +
|
||||||
|
roomId +
|
||||||
|
"':",
|
||||||
|
err
|
||||||
|
);
|
||||||
if (!client.disconnecting) {
|
if (!client.disconnecting) {
|
||||||
this.closeWebsocketConnection(client, 1011, "Error while connecting to back server");
|
this.closeWebsocketConnection(client, 1011, "Error while connecting to back server");
|
||||||
}
|
}
|
||||||
@ -188,7 +201,7 @@ export class SocketManager implements ZoneEventListener {
|
|||||||
joinRoomMessage.addCharacterlayer(characterLayerMessage);
|
joinRoomMessage.addCharacterlayer(characterLayerMessage);
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log("Calling joinRoom");
|
console.log("Calling joinRoom '" + client.roomId + "'");
|
||||||
const apiClient = await apiClientRepository.getClient(client.roomId);
|
const apiClient = await apiClientRepository.getClient(client.roomId);
|
||||||
const streamToPusher = apiClient.joinRoom();
|
const streamToPusher = apiClient.joinRoom();
|
||||||
clientEventsEmitter.emitClientJoin(client.userUuid, client.roomId);
|
clientEventsEmitter.emitClientJoin(client.userUuid, client.roomId);
|
||||||
@ -216,7 +229,13 @@ export class SocketManager implements ZoneEventListener {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
.on("end", () => {
|
.on("end", () => {
|
||||||
console.warn("Connection lost to back server");
|
console.warn(
|
||||||
|
"Connection lost to back server '" +
|
||||||
|
apiClient.getChannel().getTarget() +
|
||||||
|
"' for room '" +
|
||||||
|
client.roomId +
|
||||||
|
"'"
|
||||||
|
);
|
||||||
// Let's close the front connection if the back connection is closed. This way, we can retry connecting from the start.
|
// Let's close the front connection if the back connection is closed. This way, we can retry connecting from the start.
|
||||||
if (!client.disconnecting) {
|
if (!client.disconnecting) {
|
||||||
this.closeWebsocketConnection(client, 1011, "Connection lost to back server");
|
this.closeWebsocketConnection(client, 1011, "Connection lost to back server");
|
||||||
@ -224,7 +243,14 @@ export class SocketManager implements ZoneEventListener {
|
|||||||
console.log("A user left");
|
console.log("A user left");
|
||||||
})
|
})
|
||||||
.on("error", (err: Error) => {
|
.on("error", (err: Error) => {
|
||||||
console.error("Error in connection to back server:", err);
|
console.error(
|
||||||
|
"Error in connection to back server '" +
|
||||||
|
apiClient.getChannel().getTarget() +
|
||||||
|
"' for room '" +
|
||||||
|
client.roomId +
|
||||||
|
"':",
|
||||||
|
err
|
||||||
|
);
|
||||||
if (!client.disconnecting) {
|
if (!client.disconnecting) {
|
||||||
this.closeWebsocketConnection(client, 1011, "Error while connecting to back server");
|
this.closeWebsocketConnection(client, 1011, "Error while connecting to back server");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user