aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs')
-rw-r--r--OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs47
1 files changed, 25 insertions, 22 deletions
diff --git a/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs b/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs
index eb118ae..470eccd 100644
--- a/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs
+++ b/OpenSim/Services/Connectors/SimianGrid/SimianInventoryServiceConnector.cs
@@ -88,7 +88,7 @@ namespace OpenSim.Services.Connectors.SimianGrid
88 88
89 public SimianInventoryServiceConnector(IConfigSource source) 89 public SimianInventoryServiceConnector(IConfigSource source)
90 { 90 {
91 Initialise(source); 91 CommonInit(source);
92 } 92 }
93 93
94 public void Initialise(IConfigSource source) 94 public void Initialise(IConfigSource source)
@@ -98,36 +98,39 @@ namespace OpenSim.Services.Connectors.SimianGrid
98 { 98 {
99 string name = moduleConfig.GetString("InventoryServices", ""); 99 string name = moduleConfig.GetString("InventoryServices", "");
100 if (name == Name) 100 if (name == Name)
101 CommonInit(source);
102 }
103 }
104
105 private void CommonInit(IConfigSource source)
106 {
107 IConfig gridConfig = source.Configs["InventoryService"];
108 if (gridConfig != null)
109 {
110 string serviceUrl = gridConfig.GetString("InventoryServerURI");
111 if (!String.IsNullOrEmpty(serviceUrl))
101 { 112 {
102 IConfig gridConfig = source.Configs["InventoryService"]; 113 if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("="))
114 serviceUrl = serviceUrl + '/';
115 m_serverUrl = serviceUrl;
116
117 gridConfig = source.Configs["UserAccountService"];
103 if (gridConfig != null) 118 if (gridConfig != null)
104 { 119 {
105 string serviceUrl = gridConfig.GetString("InventoryServerURI"); 120 serviceUrl = gridConfig.GetString("UserAccountServerURI");
106 if (!String.IsNullOrEmpty(serviceUrl)) 121 if (!String.IsNullOrEmpty(serviceUrl))
107 { 122 {
108 if (!serviceUrl.EndsWith("/") && !serviceUrl.EndsWith("=")) 123 m_userServerUrl = serviceUrl;
109 serviceUrl = serviceUrl + '/'; 124 m_Enabled = true;
110 m_serverUrl = serviceUrl;
111
112 gridConfig = source.Configs["UserAccountService"];
113 if (gridConfig != null)
114 {
115 serviceUrl = gridConfig.GetString("UserAccountServerURI");
116 if (!String.IsNullOrEmpty(serviceUrl))
117 {
118 m_userServerUrl = serviceUrl;
119 m_Enabled = true;
120 }
121 }
122 } 125 }
123 } 126 }
124
125 if (String.IsNullOrEmpty(m_serverUrl))
126 m_log.Info("[SIMIAN INVENTORY CONNECTOR]: No InventoryServerURI specified, disabling connector");
127 else if (String.IsNullOrEmpty(m_userServerUrl))
128 m_log.Info("[SIMIAN INVENTORY CONNECTOR]: No UserAccountServerURI specified, disabling connector");
129 } 127 }
130 } 128 }
129
130 if (String.IsNullOrEmpty(m_serverUrl))
131 m_log.Info("[SIMIAN INVENTORY CONNECTOR]: No InventoryServerURI specified, disabling connector");
132 else if (String.IsNullOrEmpty(m_userServerUrl))
133 m_log.Info("[SIMIAN INVENTORY CONNECTOR]: No UserAccountServerURI specified, disabling connector");
131 } 134 }
132 135
133 /// <summary> 136 /// <summary>