From 5baceff4e980a62ea027dbdbae713ce4d4a2c72d Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Tue, 2 Aug 2016 17:37:41 +0100 Subject: stop a spamming robust debug message --- OpenSim/Services/GridService/GridService.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Services/GridService/GridService.cs b/OpenSim/Services/GridService/GridService.cs index 6b2dddf..a11cae1 100644 --- a/OpenSim/Services/GridService/GridService.cs +++ b/OpenSim/Services/GridService/GridService.cs @@ -341,7 +341,7 @@ namespace OpenSim.Services.GridService return String.Empty; } - +/* /// /// Search the region map for regions conflicting with this region. /// The region to be added is passed and we look for any existing regions that are @@ -433,7 +433,7 @@ namespace OpenSim.Services.GridService // is the non-conflicting region found at the location being requested. return region; } - +*/ // String describing name and region location of passed region private String RegionString(RegionData reg) { @@ -548,8 +548,8 @@ namespace OpenSim.Services.GridService } else { - m_log.DebugFormat("{0} GetRegionByPosition. Did not find region in database. Pos=<{1},{2}>", - LogHeader, regionX, regionY); +// m_log.DebugFormat("{0} GetRegionByPosition. Did not find region in database. Pos=<{1},{2}>", +// LogHeader, regionX, regionY); return null; } } -- cgit v1.1 From a99df75a3009a839c36102a2625aed3c0fcd17c5 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Tue, 2 Aug 2016 17:45:06 +0100 Subject: (mantis 7983) update local cache when storing a baked tex on assets server --- .../Avatar/AvatarFactory/AvatarFactoryModule.cs | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'OpenSim') diff --git a/OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs b/OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs index 08b276d..41a3f52 100644 --- a/OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs +++ b/OpenSim/Region/CoreModules/Avatar/AvatarFactory/AvatarFactoryModule.cs @@ -288,23 +288,24 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory if (bakedTextures.Count == 0) return false; + IImprovedAssetCache cache = sp.Scene.RequestModuleInterface(); + if(cache == null) + return true; // no baked local caching so nothing to do + foreach (BakeType bakeType in bakedTextures.Keys) { Primitive.TextureEntryFace bakedTextureFace = bakedTextures[bakeType]; if (bakedTextureFace == null) - { - // This can happen legitimately, since some baked textures might not exist - //m_log.WarnFormat( - // "[AV FACTORY]: No texture ID set for {0} for {1} in {2} not found when trying to save permanently", - // bakeType, sp.Name, m_scene.RegionInfo.RegionName); continue; - } - AssetBase asset = m_scene.AssetService.Get(bakedTextureFace.TextureID.ToString()); + AssetBase asset = cache.Get(bakedTextureFace.TextureID.ToString()); - if (asset != null) + if (asset != null && asset.Local) { + // cache does not update asset contents + cache.Expire(bakedTextureFace.TextureID.ToString()); + // Replace an HG ID with the simple asset ID so that we can persist textures for foreign HG avatars asset.ID = asset.FullID.ToString(); @@ -312,7 +313,8 @@ namespace OpenSim.Region.CoreModules.Avatar.AvatarFactory asset.Local = false; m_scene.AssetService.Store(asset); } - else + + if (asset == null) { m_log.WarnFormat( "[AV FACTORY]: Baked texture id {0} not found for bake {1} for avatar {2} in {3} when trying to save permanently", -- cgit v1.1