Commit Graph

2332 Commits (ab59c0a658c25f129255198f27704cdbbcb13d6b)

Author SHA1 Message Date
Justin Clark-Casey (justincc) ab59c0a658 on agent cross, remove from physics scene after its been placed in transit, not before. 2012-05-25 03:39:10 +01:00
Justin Clark-Casey (justincc) 888210ea4a refactor: make ETM.CrossAgentToNewRegionAsync neighbourRegion == null check return earlier to simplify method 2012-05-25 03:06:26 +01:00
Justin Clark-Casey (justincc) 96cde407ab Fix bug where a failed QueryAccess to a remove region would always have the reason "Communications failure" no matter what the destination region actually returned 2012-05-25 02:37:22 +01:00
Justin Clark-Casey (justincc) 40c78b0624 Stop it being possible for an agent to teleport back to its source region before the source region has finished cleaning up old agent data and structures.
If this is allowed, then the client usually gets forcibly logged out and data structures might be put into bad states.
To prevent this, the binary state machine of EMT.m_agentsInTransit is replaced with a 4 state machine (Preparing, Transferring, ReceivedAtDestination, CleaningUp).
This is necessary because the source region needs to know when the destination region has received the user but a teleport back cannot happen until the source region has cleaned up.
Tested on standalone, grid and with v1 and v3 clients.
2012-05-25 02:02:53 +01:00
Justin Clark-Casey (justincc) 93ff27053a Don't actually proceed on a within-region teleport if another is already taking place, rather than just (falsely) logging that we're not going to proceed.
An oversight from recent commit 9ab0c81
2012-05-24 22:59:52 +01:00
Justin Clark-Casey (justincc) cc53d91d2f On inter-region teleport, only stand the avatar up if the QueryAccess call to the destination scene actually succeeds. 2012-05-24 22:46:45 +01:00
Justin Clark-Casey (justincc) cd225215b1 Now that the EntityTransferModule is per-region, fetch the event queue module once rather than repeatedly via scene presences 2012-05-24 22:40:24 +01:00
Justin Clark-Casey (justincc) 5c9086ade6 Fix issue where a dns resolution failure on the final destination might leave the user unable to teleport since the transit flag was not being reset.
This moves the 'already in transit' check further up and resets the flag if dns resolution fails and in the new required places.
2012-05-24 22:26:02 +01:00
Justin Clark-Casey (justincc) f4cd4c8e28 Comment out accidentally left in log line that was printing out the control file on OAR save 2012-05-24 04:33:36 +01:00
Justin Clark-Casey (justincc) 38ce9d45a5 Make ISimulationScene.GetScene() used the more efficient region id for lookup rather than the region handle. 2012-05-24 01:00:18 +01:00
Justin Clark-Casey (justincc) 459c7635af If an agent is still registered as 'in transit' by the source region, don't allow an immediate teleport back.
This is to help relieve a race condition when an agent teleports then immediately attempts to teleport back before the source region has properly cleaned up/demoted the old ScenePresence.
This is rare in viewers but much more possible via scripting or region module.
However, more needs to be done since virtually all clean up happens after the transit flag is cleared .
Possibly need to add a 'cleaning up' state to in transit.
This change required making the EntityTransferModule and HGEntityTransferModule per-region rather than shared, in order to allow separate transit lists.
Changes were also required in LocalSimulationConnector.
Tested in standalone, grid and with local and remote region crossings with attachments.
2012-05-24 00:31:14 +01:00
PixelTomsen bc543c1797 Environment Module - allows Environment settings for Viewer3 warning: includes database region store migrations for mssql, mysql, sqlite
enable/disable this module:
Cap_EnvironmentSettings = "localhost" (for enable)
Cap_EnvironmentSettings = "" (for disable) at ClientStack.LindenCaps section (OpenSimDefaults.ini file)
 or owerwrite in OpenSim.ini

mantis: http://opensimulator.org/mantis/view.php?id=5860

Signed-off-by: BlueWall <jamesh@bluewallgroup.com>
2012-05-23 17:04:19 -04:00
BlueWall 682d4075e3 Fix llGetSimulatorHostname to return configured hostname 2012-05-23 15:08:39 -04:00
Justin Clark-Casey (justincc) 4d1986c0e4 minor: Change [OBJECT COMMANDS MODULE] log strings to [REGION COMMANDS MODULE] strings, though all these are currently commented out anyway 2012-05-23 04:20:54 +01:00
Justin Clark-Casey (justincc) ee98b9c394 Add "show scene" command which lists stats for the currently selected console scene(s)
This includes prim count, script count, avatar count, etc.
Information is currently the same as "show stats", though show stats can only show one scene at a time because it listens for the latest outgoing stats packet (a bad approach that needs to change).
Might be better to tie this module into the other stats module to display arbitrary stats rather than fetching directly from scene.SimStatsReporter.
Console command is "show scene" because "show region" already exists for the grid service, which is unfortunate.
Might need to make a distinction between "scene" relating to a live scene and "region" relating to more static region data (url, coords, etc.)
2012-05-23 04:10:45 +01:00
Justin Clark-Casey (justincc) 68918d632f Fetch the dialog module reference in AttachmentsModule in RegionLoaded() not AddRegion()
The reference is not guaranteed to be there when AddRegion() is called but will definitely be present at RegionLoaded() if it's going to be present at all.
2012-05-23 02:09:31 +01:00
Justin Clark-Casey (justincc) ec8745cf51 minor: Make log class names in InventoryAccessModule uniform 2012-05-23 02:05:48 +01:00
Justin Clark-Casey (justincc) ff429a259b Fix bug where an avatar that had an object they owned attached through llAttachToAvatar() or osForceAttachToAvatar() would wrongly have next permissions come into play when they detached that object and rezzed it in scene.
This is because the attachments module code was setting the 'object slam' bit by using PermissionMask.All
Solution here is to route the attachment item creation call through the existing inventory code in BasicInventoryAccessModule rather than copy/pasted code in AttachmentsModule itself.
2012-05-23 01:58:10 +01:00
Justin Clark-Casey (justincc) 9ab0c81c1d Setting 'in transit' on a local teleport as well as inter-region teleports.
This is to eliminate possible race conditions if two teleport calls are made concurrently, where at least one is a local teleport.
This is pretty much impossible on a manual user teleport but can happen on script-invoked teleports.
2012-05-21 21:33:59 +01:00
Justin Clark-Casey (justincc) 5759313f7f Add size of region to OAR control file. Megaregions (sw root OARs when saved) will have a size larger than 256x256
Not yet read.  Do not rely on this information yet, it may change.
2012-05-19 04:56:47 +01:00
Justin Clark-Casey (justincc) 3f2a727b6d Remove recent IRegionCombinerModule.IsMegaregion(). In theory, there can be more than one megaregion in a simulator, separated by water.
Rename IsRootRegion() to IsRootForMegaregion()
2012-05-19 03:17:21 +01:00
Justin Clark-Casey (justincc) 2b60a5c5d6 Add is_megaregion flag into oar control file. Not currently read - for future use. Please do not rely on this remaining here.
An adaptation of part of Garmin's patch from http://opensimulator.org/mantis/view.php?id=5975, thanks!
Flag only written if the SW corner OAR is saved - this is the only one that captures object data presently (though not land or terrain data).
This adds an IRegionCombinerModule interface and the necessary methods on RegionCombinerModule
2012-05-19 02:45:17 +01:00
Justin Clark-Casey (justincc) 6b6a00a3d5 minor: Remove redundant EstateOwner != UUID.Zero check in IsAdministrator because checking EstateOwner == user
Due to an earlier check we already know that user != UUID.Zero so if EstateOwner == UUID.Zero, EstateOwner == user can never be true
2012-05-17 01:30:50 +01:00
Justin Clark-Casey (justincc) e444cb9da4 Remove redundant "Teleport failed:" from reason when QueryAccess fails for the destination simulator. This part of the string is already provided by the viewer.
Also adds more reason logging for diagnostics when teleports are refused/fail.
2012-05-17 00:33:04 +01:00
Justin Clark-Casey (justincc) 23ae24b406 Route OAR SOG loading through the common SceneObjectSerializer.FromXml2Format() rather than the functionally identical but buggy Xml2ToSOG().
Remove buggy Xml2ToSOG().
2012-05-16 00:10:42 +01:00
Justin Clark-Casey (justincc) 1b5ce8c10e Fix issue where loading OARs could sometimes result in link numbers being reordered.
This was because the parts in scene objects were sometimes not serialized in link order.
This is perfectly fine since the parts still have the right link numbers, but an extra fix to adjust for this
had not been done in the SerialiserModule methods that OAR loading used.
Add regression test for same.
Addresses http://opensimulator.org/mantis/view.php?id=5948, http://opensimulator.org/mantis/view.php?id=5749
2012-05-15 23:43:59 +01:00
Justin Clark-Casey (justincc) 02f3b116c6 Allow use of regular expressions in "show object name", "show part name" and "delete object name" console commands if --regex switch is used.
Deleteing objects by name, creator uuid or owner uuid now requires confirmation to avoid accidental deletion.
2012-05-15 23:42:49 +01:00
Oren Hurvitz 52a32878a9 Save the Telehub and its Spawn Points in the OAR 2012-05-14 19:59:45 +01:00
Justin Clark-Casey (justincc) af6c85308a minor: add explanative comment to 'missing baked texture' logging commonly seen on inter-simulator teleports where avatar baked textures are not available from the asset service. 2012-05-14 18:57:42 +01:00
Justin Clark-Casey (justincc) c2aa3b90d9 Set the agent in transit teleport flag at the first available opportunity (i.e. when IsInTransit() was being checked) to close down a race condition.
On EntityTransferModule.DoTeleport() there was an IsInTransit() check to prevent multiple simultaneous teleport attempts.
However, the SetInTransit() was only performed later on, which left a window in which multiple threads could pass the IsInTransit() check.
This has been seen in the field and the results aren't pretty.
This commit effectively combines the IsInTransit() and SetInTransit() checks so there is no such window.
More failure cases are made to to call ResetInTransit() to adjust to this move.
2012-05-14 18:36:26 +01:00
Justin Clark-Casey (justincc) 42557d7d4c Merge branch 'master' of ssh://opensimulator.org/var/git/opensim 2012-05-14 18:33:20 +01:00
Justin Clark-Casey (justincc) fad557485c Add more region information to some teleport related logging 2012-05-14 18:06:48 +01:00
Chris Koeritz 30a272ba31 Modifications for SMTP in OpenSimulator. Email size limit was fixed (was out of step with documentation at 1024, so boosted to 4096). Added configuration item for maximum email size. Redundant sleep inside email module was fixed (LSL Api was already sleeping). Added sleep time configuration item for snooze between email sending for LSL Api. Added two new configuration items (email_max_size and email_pause_time) into the example OpenSim.ini, plus fixed a spelling error (llimits) and odd tabbing.
Signed-off-by: BlueWall <jamesh@bluewallgroup.com>
2012-05-13 17:34:20 -04:00
Justin Clark-Casey (justincc) 8b958e7e74 Revert "Save the Telehub and its Spawn Points in the OAR"
This reverts commit b0b7b45b94.

Sorry BlueWall, I wanted to discuss an aspect of the data storage but I couldn't assign bugs in 'patch included' state to myself until I changed mantis just now and I forgot to mention it on irc.
I wouldn't normally revert but thinks get tricky when it comes to data formats.
Essentially, I would like to see the Yaw, Pitch and Distance values as separate XML entities (as used in other aspects such as vectors, quaternions) rather than as a . delimited string
We can discuss this more with Oren in opensimulator.org/mantis/view.php?id=6008
2012-05-12 02:36:56 +01:00
Oren Hurvitz b0b7b45b94 Save the Telehub and its Spawn Points in the OAR
Signed-off-by: BlueWall <jamesh@bluewallgroup.com>
2012-05-10 22:56:37 -04:00
Dan Lake f374b63ac8 Add even for terrain tainting and synchronize terrain module with physics scene before physics simulation step rather than after 2012-05-10 14:42:46 -07:00
Justin Clark-Casey (justincc) 5d1d47e1f9 Revert "Better error handling if Load OAR or Save OAR fail"
This reverts commit 65c88b2ff4.

Yet again I accidentally committed something whilst evaluating it.
2012-05-07 20:01:17 +01:00
Oren Hurvitz 65c88b2ff4 Better error handling if Load OAR or Save OAR fail 2012-05-07 19:07:38 +01:00
Justin Clark-Casey (justincc) 5053506d88 refactor: Instead of performing a ScenePresence lookup twice over LocateClientObject() and GetClientScene(), do the lookup just once in LocateClientObject() 2012-05-07 18:27:33 +01:00
Justin Clark-Casey (justincc) cdf97ab3a6 Fix a bug in FriendsModule.StatusNotify() where all subsequent friends would not be notified once a non-local friend was found. 2012-05-07 17:21:45 +01:00
Justin Clark-Casey (justincc) 01b00ad0d5 Fire the scripting changed event with CHANGED_OWNER when an object that has changed owners is rezzed.
This needs to occur after the script is resumed rather than before, when the event is just dropped.
Addresses http://opensimulator.org/mantis/view.php?id=5890 and http://opensimulator.org/mantis/view.php?id=5952
2012-05-05 00:29:14 +01:00
Justin Clark-Casey (justincc) e18686528e Use the more efficient HashSet instead of List for FlotasmAssetCache.m_CurrentlyWriting 2012-05-04 23:03:33 +01:00
Justin Clark-Casey (justincc) dec6ad2933 Don't try and update the access time of a file that is actively being cached.
This may cause IOErrors on Windows.
Aims to help with http://opensimulator.org/mantis/view.php?id=6003
2012-05-04 22:57:33 +01:00
Justin Clark-Casey (justincc) da4819a170 Temporarily add debug log lines to lsl url request and release
To help with http://opensimulator.org/mantis/view.php?id=5993
2012-05-04 22:11:25 +01:00
Talun 92fde6ed26 Mantis 60004 problems with damage and llSetDamage. In damage enabled areas this patch - Deletes any objects that have damage set > 0 that deliver that damage to an avatar Stops Gods receiving damage, Stops volume detect objects causing damage Deletes NPCS when their helth reduces to zero Gradually "heals" damage to an avatar Resets health on going to a non damage area 2012-05-04 21:01:09 +01:00
Justin Clark-Casey (justincc) fcd5b0817b Reinsert a 2000ms delay before closing a no longer required agent on the source region after teleport to resolve Imprudence teleport problems.
Viewers 1 and 3 are fine with doing this immediately.  However, Imprudence has a small delay (<200ms, >500ms) after receiving the AgentCompleteMovement reply packet on the destination region before regarding that region as the currnet region.
If Imprudence receives a DisableSimulator in this period, it quits.
We are not restoring the full 5000ms delay since this brings back a bug where teleports permanently fail if an avatar tries to teleport back too quickly.
This commit also sends the AgentCompleteMovement packet to the client before telling the source region to release its old agent, in order to further cut down any possibility of the DisableSimulator being recieved before the AgentMovementComplete.
2012-05-03 22:30:36 +01:00
Justin Clark-Casey (justincc) 9ffc2c1062 minor: resolve some mono compiler warnings 2012-05-03 01:56:24 +01:00
Justin Clark-Casey (justincc) 231a3bf147 Implement optional name and description on http stream handlers so that we can relate a slow request to what the handler actually does and the agent it serves, if applicable.
This is most useful for capabilities where the url is not self-describing.
2012-05-03 01:45:49 +01:00
Justin Clark-Casey (justincc) 40f3c24562 Comment out the five second sleep in etm.DoTeleport() if the old agent needs to be closed because it is no longer in the child's view distance.
This sleep appears unnecessary since a sleep has already occurred in WaitForCallback() whilst waiting for the destination region to notify of teleport success.
There are no async operations between this sleep and the WaitForCallback()
If this sleep is present, then teleporting back to the source region within 5 seconds results in a disconnection.
If this sleep is commented out then teleporting quickly back and forth between two simulators appears to work without issue.
Tested on standalone, local grid and distributed grid.
Please revert if there's something that I've missed.
2012-05-01 23:49:02 +01:00
Justin Clark-Casey (justincc) a29f7f7551 Remove some test code that accidentally crept in with 9d2e1c67 2012-05-01 23:25:30 +01:00