This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%@ Page Language="c#" EnableEventValidation="false" AutoEventWireup="true" EnableViewState="false" %> | |
<%@ Import Namespace="System.Data" %> | |
<%@ Import Namespace="Sitecore.Links" %> | |
<%@ Import Namespace="Sitecore.SecurityModel" %> | |
<%@ Import Namespace="Sitecore.StringExtensions" %> | |
<%@ Import Namespace="Sitecore.Collections" %> | |
<%@ Import Namespace="Sitecore.Configuration" %> | |
<%@ Import Namespace="Sitecore.Data" %> | |
<%@ Import Namespace="Sitecore.Data.DataProviders.Sql" %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private int FixBrokenLinksInDatabase(Database database, bool serializeItem) | |
{ | |
Globals.LinkDatabase.Rebuild(database); | |
ItemLink[] brokenLinks = Globals.LinkDatabase.GetBrokenLinks(database); | |
ItemLink[] itemLinkArray = new BrokenLinksFilter().ExcludeSystemItemLinks(database, (IReadOnlyCollection<ItemLink>) brokenLinks); | |
foreach (ItemLink itemLink in itemLinkArray) | |
{ | |
Item sourceItem = itemLink.GetSourceItem(); | |
if (sourceItem != null) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/"> | |
<sitecore> | |
<pipelines> | |
<updateMongoDriverSettings> | |
<processor type="MySite.Foundation.SitecoreExtensions.Pipelines.UpdateMongoDriverSettings.CustomMongoDriverSettings, MySite.Foundation.SitecoreExtensions"> | |
<param desc="maxConnectionPoolSize">150</param> | |
<param desc="minConnectionPoolSize">20</param> | |
<param desc="maxConnectionIdleTimeSeconds">1500</param> | |
<param desc="maxConnectionLifeTimeSeconds">0</param> | |
</processor> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using Sitecore.Analytics.Pipelines.UpdateMongoDriverSettings; | |
using Sitecore.Diagnostics; | |
namespace MySite.Foundation.SitecoreExtensions.Pipelines.UpdateMongoDriverSettings | |
{ | |
public class CustomMongoDriverSettings : UpdateMongoDriverSettingsProcessor | |
{ | |
private readonly string _maxConnectionPoolSize; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<configuration xmlns:patch="http://www.sitecore.net/xmlconfig/" xmlns:set="http://www.sitecore.net/xmlconfig/set/"> | |
<sitecore> | |
<sc.variable name="environment" value="martin_dev_" /> | |
<contentSearch> | |
<configuration> | |
<indexes> | |
<index id="sitecore_master_index" type="Sitecore.ContentSearch.Azure.CloudSearchProviderIndex, Sitecore.ContentSearch.Azure"> | |
<param desc="name" patch:instead="param[@desc='name']">$(environment)$(id)</param> | |
</index> | |
<index id="sitecore_web_index" type="Sitecore.ContentSearch.Azure.CloudSearchProviderIndex, Sitecore.ContentSearch.Azure"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
.SYNOPSIS | |
Script targets a CSV file in the media library and creates simple redirect items for each data record | |
.NOTES | |
Martin English | |
#> | |
#Target csv file in media library | |
$media = "/sitecore/media library/import-data" |
NewerOlder