commit d605e2616588fe26d08af9dd4e2eb7b87555dc3a
Author: Petr Pudlak <pudlak@google.com>
Date:   Fri Dec 6 09:50:37 2013 +0100

    Rename getClient/Server to getLuxiClient/Server
    
    Later they will be split into LUXI-specific and general parts.
    
    Signed-off-by: Petr Pudlak <pudlak@google.com>
    Reviewed-by: Klaus Aehlig <aehlig@google.com>

diff --git a/src/Ganeti/HTools/Backend/Luxi.hs b/src/Ganeti/HTools/Backend/Luxi.hs
index 2568edc..7370d85 100644
--- a/src/Ganeti/HTools/Backend/Luxi.hs
+++ b/src/Ganeti/HTools/Backend/Luxi.hs
@@ -272,7 +272,7 @@ readData :: String -- ^ Unix socket to use as source
          -> IO (Result JSValue, Result JSValue, Result JSValue, Result JSValue)
 readData master =
   E.bracket
-       (L.getClient master)
+       (L.getLuxiClient master)
        L.closeClient
        (\s -> do
           nodes <- queryNodes s
diff --git a/src/Ganeti/HTools/Program/Harep.hs b/src/Ganeti/HTools/Program/Harep.hs
index 5fdce8e..0bd2104 100644
--- a/src/Ganeti/HTools/Program/Harep.hs
+++ b/src/Ganeti/HTools/Program/Harep.hs
@@ -463,7 +463,7 @@ main opts args = do
   iniData <- exitIfBad "when parsing auto-repair tags" iniDataRes
 
   -- First step: check all pending repairs, see if they are completed.
-  iniData' <- bracket (L.getClient master) L.closeClient $
+  iniData' <- bracket (L.getLuxiClient master) L.closeClient $
               forM iniData . processPending
 
   -- Second step: detect any problems.
@@ -476,7 +476,7 @@ main opts args = do
                             ArHealthy _ -> doRepair c jobDelay i
                             _           -> const (return i)
 
-  repairDone <- bracket (L.getClient master) L.closeClient $
+  repairDone <- bracket (L.getLuxiClient master) L.closeClient $
                 forM (zip iniData' repairs) . maybeRepair
 
   -- Print some stats and exit.
diff --git a/src/Ganeti/HTools/Program/Hbal.hs b/src/Ganeti/HTools/Program/Hbal.hs
index 73fc6b4..a991134 100644
--- a/src/Ganeti/HTools/Program/Hbal.hs
+++ b/src/Ganeti/HTools/Program/Hbal.hs
@@ -192,7 +192,7 @@ execJobSet anno master nl il cref (js:jss) = do
       descr = map (\(_, idx, _, _) -> Container.nameOf il idx) js
       logfn = putStrLn . ("Got job IDs" ++) . commaJoin . map (show . fromJobId)
   putStrLn $ "Executing jobset for instances " ++ commaJoin descr
-  jrs <- bracket (L.getClient master) L.closeClient $
+  jrs <- bracket (L.getLuxiClient master) L.closeClient $
          Jobs.execJobsWait jobs logfn
   case jrs of
     Bad x -> return $ Bad x
diff --git a/src/Ganeti/JQueue.hs b/src/Ganeti/JQueue.hs
index 13e77e9..1d2cfb5 100644
--- a/src/Ganeti/JQueue.hs
+++ b/src/Ganeti/JQueue.hs
@@ -444,7 +444,7 @@ isQueueOpen = liftM not (jobQueueDrainFile >>= doesFileExist)
 startJobs :: [QueuedJob] -> IO ()
 startJobs jobs = do
   socketpath <- defaultMasterSocket
-  client <- getClient socketpath
+  client <- getLuxiClient socketpath
   pickupResults <- mapM (flip callMethod client . PickupJob . qjId) jobs
   let failures = map show $ justBad pickupResults
   unless (null failures)
diff --git a/src/Ganeti/Luxi.hs b/src/Ganeti/Luxi.hs
index ce9e61e..df25a50 100644
--- a/src/Ganeti/Luxi.hs
+++ b/src/Ganeti/Luxi.hs
@@ -34,8 +34,8 @@ module Ganeti.Luxi
   , makeJobId
   , RecvResult(..)
   , strOfOp
-  , getClient
-  , getServer
+  , getLuxiClient
+  , getLuxiServer
   , acceptClient
   , closeClient
   , closeServer
diff --git a/src/Ganeti/Query/Server.hs b/src/Ganeti/Query/Server.hs
index 1a6b9ed..92ddc06 100644
--- a/src/Ganeti/Query/Server.hs
+++ b/src/Ganeti/Query/Server.hs
@@ -369,7 +369,7 @@ prepMain _ _ = do
   socket_path <- Path.defaultQuerySocket
   cleanupSocket socket_path
   s <- describeError "binding to the Luxi socket"
-         Nothing (Just socket_path) $ getServer True socket_path
+         Nothing (Just socket_path) $ getLuxiServer True socket_path
   cref <- newIORef (Bad "Configuration not yet loaded")
   jq <- emptyJQStatus 
   return (socket_path, s, cref, jq)
diff --git a/src/Ganeti/UDSServer.hs b/src/Ganeti/UDSServer.hs
index 88b60fa..266ad6d 100644
--- a/src/Ganeti/UDSServer.hs
+++ b/src/Ganeti/UDSServer.hs
@@ -30,8 +30,8 @@ module Ganeti.UDSServer
   , RecvResult(..)
   , MsgKeys(..)
   , strOfKey
-  , getClient
-  , getServer
+  , getLuxiClient
+  , getLuxiServer
   , acceptClient
   , closeClient
   , closeServer
@@ -107,8 +107,8 @@ data Client = Client { socket :: Handle           -- ^ The socket of the client
                      }
 
 -- | Connects to the master daemon and returns a luxi Client.
-getClient :: String -> IO Client
-getClient path = do
+getLuxiClient :: String -> IO Client
+getLuxiClient path = do
   s <- S.socket S.AF_UNIX S.Stream S.defaultProtocol
   withTimeout luxiDefCtmo "creating luxi connection" $
               S.connect s (S.SockAddrUnix path)
@@ -117,8 +117,8 @@ getClient path = do
   return Client { socket=h, rbuf=rf }
 
 -- | Creates and returns a server endpoint.
-getServer :: Bool -> FilePath -> IO S.Socket
-getServer setOwner path = do
+getLuxiServer :: Bool -> FilePath -> IO S.Socket
+getLuxiServer setOwner path = do
   s <- S.socket S.AF_UNIX S.Stream S.defaultProtocol
   S.bindSocket s (S.SockAddrUnix path)
   when setOwner . setOwnerAndGroupFromNames path GanetiLuxid $
diff --git a/test/hs/Test/Ganeti/Luxi.hs b/test/hs/Test/Ganeti/Luxi.hs
index 26343ad..6c64c1c 100644
--- a/test/hs/Test/Ganeti/Luxi.hs
+++ b/test/hs/Test/Ganeti/Luxi.hs
@@ -131,7 +131,7 @@ prop_ClientServer dnschars = monadicIO $ do
   -- we need to create the server first, otherwise (if we do it in the
   -- forked thread) the client could try to connect to it before it's
   -- ready
-  server <- run $ Luxi.getServer False fpath
+  server <- run $ Luxi.getLuxiServer False fpath
   -- fork the server responder
   _ <- run . forkIO $
     bracket
@@ -140,7 +140,7 @@ prop_ClientServer dnschars = monadicIO $ do
       luxiServerPong
   replies <- run $
     bracket
-      (Luxi.getClient fpath)
+      (Luxi.getLuxiClient fpath)
       Luxi.closeClient
       (`luxiClientPong` msgs)
   stop $ replies ==? msgs
