diff options
author | Melanie | 2019-09-04 11:01:27 +0100 |
---|---|---|
committer | Melanie | 2019-09-04 11:01:27 +0100 |
commit | 3d019323e822c7c051e54ff9ff6b6c138566e0fe (patch) | |
tree | b0539d713f97df3f4dfef34d69008315e1107e09 /OpenSim/Services | |
parent | fix the fix (diff) | |
download | opensim-SC-3d019323e822c7c051e54ff9ff6b6c138566e0fe.zip opensim-SC-3d019323e822c7c051e54ff9ff6b6c138566e0fe.tar.gz opensim-SC-3d019323e822c7c051e54ff9ff6b6c138566e0fe.tar.bz2 opensim-SC-3d019323e822c7c051e54ff9ff6b6c138566e0fe.tar.xz |
Cache assets even in cases where the upload fails. That helps in asset upload debugging because the asset can be examined
Diffstat (limited to 'OpenSim/Services')
-rw-r--r-- | OpenSim/Services/Connectors/Asset/AssetServicesConnector.cs | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/OpenSim/Services/Connectors/Asset/AssetServicesConnector.cs b/OpenSim/Services/Connectors/Asset/AssetServicesConnector.cs index b12ea62..1bcc368 100644 --- a/OpenSim/Services/Connectors/Asset/AssetServicesConnector.cs +++ b/OpenSim/Services/Connectors/Asset/AssetServicesConnector.cs | |||
@@ -539,11 +539,11 @@ namespace OpenSim.Services.Connectors | |||
539 | // SynchronousRestObjectRequester returns somethins that is not an empty string | 539 | // SynchronousRestObjectRequester returns somethins that is not an empty string |
540 | 540 | ||
541 | asset.ID = newID; | 541 | asset.ID = newID; |
542 | |||
543 | if (m_Cache != null) | ||
544 | m_Cache.Cache(asset); | ||
545 | } | 542 | } |
546 | } | 543 | } |
544 | if (m_Cache != null) | ||
545 | m_Cache.Cache(asset); | ||
546 | |||
547 | return asset.ID; | 547 | return asset.ID; |
548 | } | 548 | } |
549 | 549 | ||
@@ -573,8 +573,8 @@ namespace OpenSim.Services.Connectors | |||
573 | if (newID == null || newID == String.Empty || newID == stringUUIDZero) | 573 | if (newID == null || newID == String.Empty || newID == stringUUIDZero) |
574 | { | 574 | { |
575 | if(nextRetryLevel >= MAXSENDRETRIESLEN) | 575 | if(nextRetryLevel >= MAXSENDRETRIESLEN) |
576 | m_log.WarnFormat("[Assets] Upload giveup after several retries id: {0} type {1}", | 576 | m_log.WarnFormat("[Assets] Giving up on uploading after {2} retries id: {0} type {1}", |
577 | asset.ID.ToString(), asset.Type.ToString()); | 577 | asset.ID.ToString(), asset.Type.ToString(), MAXSENDRETRIESLEN); |
578 | else | 578 | else |
579 | { | 579 | { |
580 | lock(m_sendRetries) | 580 | lock(m_sendRetries) |
@@ -596,11 +596,11 @@ namespace OpenSim.Services.Connectors | |||
596 | if (newID != asset.ID) | 596 | if (newID != asset.ID) |
597 | { | 597 | { |
598 | asset.ID = newID; | 598 | asset.ID = newID; |
599 | |||
600 | if (m_Cache != null) | ||
601 | m_Cache.Cache(asset); | ||
602 | } | 599 | } |
603 | } | 600 | } |
601 | |||
602 | if (m_Cache != null) | ||
603 | m_Cache.Cache(asset); | ||
604 | } | 604 | } |
605 | 605 | ||
606 | public bool UpdateContent(string id, byte[] data) | 606 | public bool UpdateContent(string id, byte[] data) |