From be043c68edd3360168817817268571fbbd6bd26b Mon Sep 17 00:00:00 2001 From: Rick Falkvinge Date: Sat, 18 Feb 2017 01:38:37 +0100 Subject: [PATCH] Slight refactoring --- FrontSocket/Frontend-Socket.csproj | 2 +- FrontSocket/FrontendLoop.cs | 2 +- FrontSocket/{MasterServices.cs => FrontendServices.cs} | 4 ++-- Site/Scripts/Swarmops-v5.js | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) rename FrontSocket/{MasterServices.cs => FrontendServices.cs} (96%) diff --git a/FrontSocket/Frontend-Socket.csproj b/FrontSocket/Frontend-Socket.csproj index 69fa01ef..d585daa2 100644 --- a/FrontSocket/Frontend-Socket.csproj +++ b/FrontSocket/Frontend-Socket.csproj @@ -56,7 +56,7 @@ - + diff --git a/FrontSocket/FrontendLoop.cs b/FrontSocket/FrontendLoop.cs index 753887cf..3210b364 100644 --- a/FrontSocket/FrontendLoop.cs +++ b/FrontSocket/FrontendLoop.cs @@ -56,7 +56,7 @@ namespace Swarmops.Frontend.Socket OutboundComm.CreateNotification(null, NotificationResource.System_Startup_Frontend); _socketServer = new WebSocketServer (SystemSettings.WebsocketPortFrontend); - _socketServer.AddWebSocketService ("/Master"); + _socketServer.AddWebSocketService ("/Front"); // _socketServer.KeepClean = false; // as per the author's recommendation - this may be bad in the long run _socketServer.Start(); diff --git a/FrontSocket/MasterServices.cs b/FrontSocket/FrontendServices.cs similarity index 96% rename from FrontSocket/MasterServices.cs rename to FrontSocket/FrontendServices.cs index 8cb93985..f79cde8d 100644 --- a/FrontSocket/MasterServices.cs +++ b/FrontSocket/FrontendServices.cs @@ -11,9 +11,9 @@ using WebSocketSharp.Server; namespace Swarmops.Frontend.Socket { - internal class MasterServices: WebSocketBehavior + internal class FrontendServices: WebSocketBehavior { - public MasterServices() + public FrontendServices() { base.IgnoreExtensions = true; // Necessary to suppress a Deflate exception that kills server otherwise } diff --git a/Site/Scripts/Swarmops-v5.js b/Site/Scripts/Swarmops-v5.js index e346989d..a8d4366b 100644 --- a/Site/Scripts/Swarmops-v5.js +++ b/Site/Scripts/Swarmops-v5.js @@ -47,10 +47,10 @@ function _masterInitializeSocket(authenticationTicket) { function getMasterSocketAddress() { if (location.host.indexOf ("localhost") >= 0) { // Assume dev environment, go for sandbox socket - return 'ws://sandbox.swarmops.com/ws/Master'; + return 'ws://sandbox.swarmops.com/ws/Front'; } else { var protocol = ('https:' == document.location.protocol ? 'wss://' : 'ws://'); - return protocol + location.host + "/ws/Master"; + return protocol + location.host + "/ws/Front"; } }