diff options
Diffstat (limited to 'OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid')
-rw-r--r-- | OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/LocalGridServiceConnector.cs | 17 | ||||
-rw-r--r-- | OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/RemoteGridServiceConnector.cs | 5 |
2 files changed, 2 insertions, 20 deletions
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/LocalGridServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/LocalGridServiceConnector.cs index 1b00c8a..b2e3f4f 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/LocalGridServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/LocalGridServiceConnector.cs | |||
@@ -181,22 +181,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid | |||
181 | 181 | ||
182 | public List<GridRegion> GetNeighbours(UUID scopeID, UUID regionID) | 182 | public List<GridRegion> GetNeighbours(UUID scopeID, UUID regionID) |
183 | { | 183 | { |
184 | if (m_LocalCache.ContainsKey(regionID)) | 184 | return m_GridService.GetNeighbours(scopeID, regionID); |
185 | { | ||
186 | List<GridRegion> neighbours = m_LocalCache[regionID].GetNeighbours(); | ||
187 | if (neighbours.Count == 0) | ||
188 | // try the DB | ||
189 | neighbours = m_GridService.GetNeighbours(scopeID, regionID); | ||
190 | return neighbours; | ||
191 | } | ||
192 | else | ||
193 | { | ||
194 | m_log.WarnFormat("[LOCAL GRID CONNECTOR]: GetNeighbours: Requested region {0} is not on this sim", regionID); | ||
195 | return new List<GridRegion>(); | ||
196 | } | ||
197 | |||
198 | // Don't go to the DB | ||
199 | //return m_GridService.GetNeighbours(scopeID, regionID); | ||
200 | } | 185 | } |
201 | 186 | ||
202 | public GridRegion GetRegionByUUID(UUID scopeID, UUID regionID) | 187 | public GridRegion GetRegionByUUID(UUID scopeID, UUID regionID) |
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/RemoteGridServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/RemoteGridServiceConnector.cs index 46741a5..16e25e6 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/RemoteGridServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Grid/RemoteGridServiceConnector.cs | |||
@@ -153,12 +153,9 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Grid | |||
153 | return false; | 153 | return false; |
154 | } | 154 | } |
155 | 155 | ||
156 | // Let's override GetNeighbours completely -- never go to the grid server | ||
157 | // Neighbours are/should be cached locally | ||
158 | // For retrieval from the DB, caller should call GetRegionByPosition | ||
159 | public override List<GridRegion> GetNeighbours(UUID scopeID, UUID regionID) | 156 | public override List<GridRegion> GetNeighbours(UUID scopeID, UUID regionID) |
160 | { | 157 | { |
161 | return m_LocalGridService.GetNeighbours(scopeID, regionID); | 158 | return base.GetNeighbours(scopeID, regionID); |
162 | } | 159 | } |
163 | 160 | ||
164 | public override GridRegion GetRegionByUUID(UUID scopeID, UUID regionID) | 161 | public override GridRegion GetRegionByUUID(UUID scopeID, UUID regionID) |