diff --git a/src/Umbraco.Infrastructure/Examine/NoopBackOfficeExamineSearcher.cs b/src/Umbraco.Infrastructure/Examine/NoopBackOfficeExamineSearcher.cs new file mode 100644 index 0000000000..15ed8de389 --- /dev/null +++ b/src/Umbraco.Infrastructure/Examine/NoopBackOfficeExamineSearcher.cs @@ -0,0 +1,18 @@ +using System.Collections.Generic; +using System.Linq; +using Examine; +using Umbraco.Examine; +using Umbraco.Web.Models.ContentEditing; + +namespace Umbraco.Infrastructure.Examine +{ + public class NoopBackOfficeExamineSearcher : IBackOfficeExamineSearcher + { + public IEnumerable Search(string query, UmbracoEntityTypes entityType, int pageSize, long pageIndex, out long totalFound, + string searchFrom = null, bool ignoreUserStartNodes = false) + { + totalFound = 0; + return Enumerable.Empty(); + } + } +} diff --git a/src/Umbraco.Infrastructure/Examine/NoopUmbracoIndexesCreator.cs b/src/Umbraco.Infrastructure/Examine/NoopUmbracoIndexesCreator.cs new file mode 100644 index 0000000000..a6133a7e59 --- /dev/null +++ b/src/Umbraco.Infrastructure/Examine/NoopUmbracoIndexesCreator.cs @@ -0,0 +1,15 @@ +using System.Collections.Generic; +using System.Linq; +using Examine; +using Umbraco.Examine; + +namespace Umbraco.Infrastructure.Examine +{ + public class NoopUmbracoIndexesCreator : IUmbracoIndexesCreator + { + public IEnumerable Create() + { + return Enumerable.Empty(); + } + } +} diff --git a/src/Umbraco.Infrastructure/Runtime/CoreInitialComposer.cs b/src/Umbraco.Infrastructure/Runtime/CoreInitialComposer.cs index 4f1109a8cb..852c617750 100644 --- a/src/Umbraco.Infrastructure/Runtime/CoreInitialComposer.cs +++ b/src/Umbraco.Infrastructure/Runtime/CoreInitialComposer.cs @@ -30,6 +30,7 @@ using Umbraco.Core.Services.Implement; using Umbraco.Core.Strings; using Umbraco.Core.Sync; using Umbraco.Examine; +using Umbraco.Infrastructure.Examine; using Umbraco.Infrastructure.Media; using Umbraco.Web; using Umbraco.Web.Actions; @@ -365,7 +366,9 @@ namespace Umbraco.Core.Runtime composition.RegisterUnique(); - + // Register noop versions for examine to be overridden by examine + composition.RegisterUnique(); + composition.RegisterUnique(); } } } diff --git a/src/Umbraco.Web.BackOffice/Umbraco.Web.BackOffice.csproj b/src/Umbraco.Web.BackOffice/Umbraco.Web.BackOffice.csproj index 6711d507e8..0e98bc8cd7 100644 --- a/src/Umbraco.Web.BackOffice/Umbraco.Web.BackOffice.csproj +++ b/src/Umbraco.Web.BackOffice/Umbraco.Web.BackOffice.csproj @@ -32,7 +32,7 @@ - + diff --git a/src/Umbraco.Web.UI.NetCore/Umbraco.Web.UI.NetCore.csproj b/src/Umbraco.Web.UI.NetCore/Umbraco.Web.UI.NetCore.csproj index 79f05b939f..f832deea13 100644 --- a/src/Umbraco.Web.UI.NetCore/Umbraco.Web.UI.NetCore.csproj +++ b/src/Umbraco.Web.UI.NetCore/Umbraco.Web.UI.NetCore.csproj @@ -17,6 +17,7 @@ +