Issue Details (XML | Word | Printable)

Key: LIBOMV-394
Type: Improvement Improvement
Status: Resolved Resolved
Resolution: Fixed
Priority: Minor Minor
Assignee: Unassigned
Reporter: Tim Hart
Votes: 1
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
libopenmetaverse

Huge difference in performance between 0.5.0 and latest trunk (r2272)

Created: 07/Oct/08 06:20 AM   Updated: 14/Jan/09 11:36 AM
Component/s: Networking
Affects Version/s: None
Fix Version/s: 0.6.0

Issue Links:
Related
 

Environment: .NET / Windows32


 Description  « Hide
I upgraded my bot from version 0.5.0 to the latest trunk (r2272) and I noticed a huge difference in speed between version 0.5.0 and trunk.

The latest version of trunk is several times slower with requesting/receiving ObjectProperties packets and requesting/receiving avatar names.

In order to demonstrate, I created a zip package containing two versions of a small test program. One version is build for 0.5.0 and the other for latest trunk. I also included that compiled exe's and libraries for easier testing if needed.

What this program does is request a lot of ObjectProperties packets and requesting avatar names. When a key is pressed, a list of all root prims is shown, including the full names of the creator, owner and prim name. Much of this data is only known after an ObjectProperties packet for the prim is received.

The program based on latest trunk is several times slower with populating the data dictionaries than version 0.5.0, which has the ObjectProperties and names almost immediately after requested.

I have no idea why this is happening. I'll have a look at the svn logs to get an idea...

EDIT: see comment below. I removed the attachment with the test program since it doesn't make much sense anymore. It's still available on request.



 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Tim Hart added a comment - 07/Oct/08 06:57 AM - edited
I hereby officially declare myself an idiot.

I should have checked the svn logs much sooner, because the change between r2047-r2048 should have given me a clue. LIBOMV-343 caused the change.

Is there an easy way to get the outgoing packet rate changed to levels more like 0.5.0? Or is that not advised?


John Hurliman added a comment - 07/Oct/08 12:22 PM
The new version has a packet throttle. This is important for keeping most clients alive while sending out bulk packets, but it's definitely something that should be tunable. If you want to experiment, look at NetworkManager.cs:707:

if (ms < 75)
{
//Logger.DebugLog(String.Format("Rate limiting, last packet was {0}ms ago", ms));
Thread.Sleep(75 - ms);
}

Comment that entire part out to revert back to the old behavior, or try changing both instances of 75 to a smaller number to find a happy medium.


Tim Hart added a comment - 08/Oct/08 02:57 AM
Thanks John, I made some changes and I was able to get the same good results as before. I never noticed any disconnects with my projects, so I guess I'm still not torturing the sims enough!

It would be nice to have an option in Settings.cs for this. The hard coded default of 75 was too long for the amount of packets I was generating, causing noticeable delays when requesting data. It would be great to be able to change this setting on the fly.

I'm changing this Issue Type from Bug to Improvement!


Nicolas Leonard added a comment - 13/Oct/08 09:25 AM
Hi,

I had exactly the same performance issue, and resolve it by commenting the incriminated code.
So I agree with Tim, it would be perfect to have an option, I can provide a patch if you want.


Latif Khalifa added a comment - 14/Jan/09 11:36 AM
You can now disable package throttling altogether by setting THROTTLE_OUTGOING_PACKETS to false in settings.