diff options
Some more refactoring of GridServer.
Diffstat (limited to 'OpenSim/Grid/GridServer/GridDBService.cs')
-rw-r--r-- | OpenSim/Grid/GridServer/GridDBService.cs | 25 |
1 files changed, 3 insertions, 22 deletions
diff --git a/OpenSim/Grid/GridServer/GridDBService.cs b/OpenSim/Grid/GridServer/GridDBService.cs index 389cf69..94c8dcd 100644 --- a/OpenSim/Grid/GridServer/GridDBService.cs +++ b/OpenSim/Grid/GridServer/GridDBService.cs | |||
@@ -197,14 +197,13 @@ namespace OpenSim.Grid.GridServer | |||
197 | return regions; | 197 | return regions; |
198 | } | 198 | } |
199 | 199 | ||
200 | public void LoginRegion(RegionProfileData sim, RegionProfileData existingSim) | 200 | public DataResponse LoginRegion(RegionProfileData sim, RegionProfileData existingSim) |
201 | { | 201 | { |
202 | DataResponse insertResponse = DataResponse.RESPONSE_ERROR; | ||
202 | foreach (IGridDataPlugin plugin in _plugins) | 203 | foreach (IGridDataPlugin plugin in _plugins) |
203 | { | 204 | { |
204 | try | 205 | try |
205 | { | 206 | { |
206 | DataResponse insertResponse; | ||
207 | |||
208 | if (existingSim == null) | 207 | if (existingSim == null) |
209 | { | 208 | { |
210 | insertResponse = plugin.AddProfile(sim); | 209 | insertResponse = plugin.AddProfile(sim); |
@@ -213,25 +212,6 @@ namespace OpenSim.Grid.GridServer | |||
213 | { | 212 | { |
214 | insertResponse = plugin.UpdateProfile(sim); | 213 | insertResponse = plugin.UpdateProfile(sim); |
215 | } | 214 | } |
216 | |||
217 | switch (insertResponse) | ||
218 | { | ||
219 | case DataResponse.RESPONSE_OK: | ||
220 | m_log.Info("[LOGIN END]: " + (existingSim == null ? "New" : "Existing") + " sim login successful: " + sim.regionName); | ||
221 | break; | ||
222 | case DataResponse.RESPONSE_ERROR: | ||
223 | m_log.Warn("[LOGIN END]: Sim login failed (Error): " + sim.regionName); | ||
224 | break; | ||
225 | case DataResponse.RESPONSE_INVALIDCREDENTIALS: | ||
226 | m_log.Warn("[LOGIN END]: " + | ||
227 | "Sim login failed (Invalid Credentials): " + sim.regionName); | ||
228 | break; | ||
229 | case DataResponse.RESPONSE_AUTHREQUIRED: | ||
230 | m_log.Warn("[LOGIN END]: " + | ||
231 | "Sim login failed (Authentication Required): " + | ||
232 | sim.regionName); | ||
233 | break; | ||
234 | } | ||
235 | } | 215 | } |
236 | catch (Exception e) | 216 | catch (Exception e) |
237 | { | 217 | { |
@@ -240,6 +220,7 @@ namespace OpenSim.Grid.GridServer | |||
240 | m_log.Warn("[LOGIN END]: " + e.ToString()); | 220 | m_log.Warn("[LOGIN END]: " + e.ToString()); |
241 | } | 221 | } |
242 | } | 222 | } |
223 | return insertResponse; | ||
243 | } | 224 | } |
244 | 225 | ||
245 | public DataResponse DeleteRegion(string uuid) | 226 | public DataResponse DeleteRegion(string uuid) |