aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2011-07-01 21:25:40 +0100
committerJustin Clark-Casey (justincc)2011-07-01 21:25:40 +0100
commit9f72fbcb7533bd960c38082cbd6956cd01fa6919 (patch)
tree3f2da22ae0a05d76753ab25ae3849ef66b25ccb6 /OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
parentMerge branch 'master' of ssh://opensimulator.org/var/git/opensim (diff)
downloadopensim-SC_OLD-9f72fbcb7533bd960c38082cbd6956cd01fa6919.zip
opensim-SC_OLD-9f72fbcb7533bd960c38082cbd6956cd01fa6919.tar.gz
opensim-SC_OLD-9f72fbcb7533bd960c38082cbd6956cd01fa6919.tar.bz2
opensim-SC_OLD-9f72fbcb7533bd960c38082cbd6956cd01fa6919.tar.xz
Add an async inventory details sender to respond to FetchInventory packets.
If a user with a very large inventory right-clicks on their "My Inventory" folder, viewer 1 code will send a massive number of Fetchinventory requests. Even though each is handled asynchronously via a pool thread, the sheer frequency of requests overwhelms the pool and freezes inbound packet handling. This change makes the first Fetchinventory thread also handle subsequent requests, freeing up the other threads. Further efficiencies could be made by handling all the items in a particular FetchInventory request together, rather than separately.
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs25
1 files changed, 0 insertions, 25 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
index e2d7208..44472b2 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs
@@ -461,31 +461,6 @@ namespace OpenSim.Region.Framework.Scenes
461 } 461 }
462 ); 462 );
463 } 463 }
464
465
466 /// <summary>
467 /// Handle a fetch inventory request from the client
468 /// </summary>
469 /// <param name="remoteClient"></param>
470 /// <param name="itemID"></param>
471 /// <param name="ownerID"></param>
472 public void HandleFetchInventory(IClientAPI remoteClient, UUID itemID, UUID ownerID)
473 {
474 if (LibraryService != null && LibraryService.LibraryRootFolder != null && ownerID == LibraryService.LibraryRootFolder.Owner)
475 {
476 //m_log.Debug("request info for library item");
477 return;
478 }
479
480 InventoryItemBase item = new InventoryItemBase(itemID, remoteClient.AgentId);
481 item = InventoryService.GetItem(item);
482
483 if (item != null)
484 {
485 remoteClient.SendInventoryItemDetails(ownerID, item);
486 }
487 // else shouldn't we send an alert message?
488 }
489 464
490 /// <summary> 465 /// <summary>
491 /// Tell the client about the various child items and folders contained in the requested folder. 466 /// Tell the client about the various child items and folders contained in the requested folder.