Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Greyhound 102 posts 124 karma points
    Dec 28, 2010 @ 14:15
    Greyhound
    0

    UmbracoExamine & Examine.LuceneEngine

    Please could an expert clarify the following if possible as I've had a fruitless 3 days chasing my tail.

    I've looked at the examples of using Examine.LuceneEngine to create a custom index of data contained in a separate XML file (non Umbraco CMS data)

    The default Umbraco config is set to use UmbracoExamine.

    a. Am I correct in the assumption that UmbracoExamine is solely for Umbraco CMS data
    b. I am unable to use a combination of UmbracoExamine && Examine.LuceneEngine
    c. If I switch to Examine.LuceneEngine the internal back office search will be permanently broken
    d. If I switch to Examine.LuceneEngine, is it possible to create new indexes so I can at least get a working front end search up and running that will return results to users that contains Umbraco and non-Umbraco data

    I'd be so very grateful if someone could respond this.

  • Ismail Mayat 4511 posts 10092 karma points MVP 2x admin c-trib
    Dec 29, 2010 @ 09:20
    Ismail Mayat
    0

    GreyHound,

    a. Yes you are

    b. You should be able to use both you just need to create in the config files separate indexer and searcher (not tried it myself but in theory you should be able to)

    c. No as the internal index and searcher is separate in the configs so it should still work if you dont touch internal index and searcher

    d. Take around on forum about combining pdf and content search results becuase there was a similar issue there, one suggestion was you could combine the two result sets however you would lose ordering i.e. all umbraco results would be ordered and your custom results would also be ordered but as a combined result set they would not be ordered.

    Regards

    Ismail

  • Greyhound 102 posts 124 karma points
    Dec 29, 2010 @ 15:20
    Greyhound
    0

    Hi Ismail, thanks for getting back to me, this seems to be a very difficult area to get any kind of help on.

    My experience is contrary to all of the above. Nothing seems to work at all expect a default UmbracoExamine Index.

    Whenever I try to set up a custom index in the config then I get a value cannot be null (Parameter name : type) with the following highlighted:

    type="Examine.LuceneEngine.Providers.SimpleDataIndexer, Examine"

    It doesnt even get as far as looking at the dataService="ExamineDemos.CustomDataService, ExamineDemos" section.

    The internal search does break.

    There are absolutely no examples of regular and custom indexes running in an Umbraco instance.

    Having just spent a week integrating BlogEngine.Net cos a client wanted more functionality and due to this having to implement new search functionality I'm gonna have to port the whole thing across to DNN as I cant wrap it together. I genuinely feel like crying like a baby right now, I've been staring at this for a week.

    In my humble opinion I dont think this works properly and it would be of great help to get a definitive answer from slace or someone with advanced knowledge of this so I can at least put it down and forget it if it is not possible.

  • Thijs Kuipers 43 posts 66 karma points
    Jan 04, 2011 @ 13:52
    Thijs Kuipers
    0

    Hey Greyhound, I've been able to install Examine 1.0 RTM on an Umbraco 4.5.2 instance and am able to (at least) define one custom index and use the XSLT Extensions, without breaking the internal indexer. I've followed the instructions on this page: Examine v1.0 RTM and in this document: Release Notes.

    Here are my config files:

    config/xsltExtensions.config

    <?xml version="1.0" encoding="utf-8" ?>
    <XsltExtensions>
        <ext assembly="UmbracoExamine" type="UmbracoExamine.XsltExtensions" alias="Examine"/>
    </XsltExtensions>

    config/ExamineIndex.config

    <?xml version="1.0"?>
    <!-- 
    Umbraco examine is an extensible indexer and search engine.
    This configuration file can be extended to create your own index sets.
    Index/Search providers can be defined in the UmbracoSettings.config
    
    More information and documentation can be found on CodePlex: http://umbracoexamine.codeplex.com
    -->
    <ExamineLuceneIndexSets>
        <!-- The internal index set used by Umbraco back-office - DO NOT REMOVE -->
        <IndexSet SetName="InternalIndexSet" IndexPath="~/App_Data/TEMP/ExamineIndexes/Internal/">
          <IndexAttributeFields>
            <add Name="id" />
            <add Name="nodeName" />
            <add Name="updateDate" />
            <add Name="writerName" />
            <add Name="path" />
            <add Name="nodeTypeAlias" />
            <add Name="parentID" />
          </IndexAttributeFields>
          <IndexUserFields />
          <IncludeNodeTypes/>
          <ExcludeNodeTypes />
        </IndexSet>
    
        <!-- The internal index set used by Umbraco back-office for indexing members - DO NOT REMOVE -->
        <IndexSet SetName="InternalMemberIndexSet" IndexPath="~/App_Data/TEMP/ExamineIndexes/InternalMember/">
            <IndexAttributeFields>
                <add Name="id" />
                <add Name="nodeName"/>
                <add Name="updateDate" />
                <add Name="writerName" />
                <add Name="loginName" />
                <add Name="email" />
                <add Name="nodeTypeAlias" />
            </IndexAttributeFields>
            <IndexUserFields/>
            <IncludeNodeTypes/>
            <ExcludeNodeTypes />
        </IndexSet>
    
        <IndexSet SetName="SiteSearchIndexSet" IndexPath="~/App_Data/TEMP/ExamineIndexes/SiteSearch/">
            <IndexAttributeFields>
                <add Name="id" />
                <add Name="nodeName"/>
            </IndexAttributeFields>
            <IndexUserFields>
                <add Name="pageTitle"/>
                <add Name="pageBody"/>
                <add Name="pageSummary"/>
            </IndexUserFields>
            <IncludeNodeTypes>
                <add Name="Page"/>
                <add Name="NewsPost"/>
                <add Name="NewsOverview"/>
            </IncludeNodeTypes>
            <ExcludeNodeTypes>
                <!--<add Name="DateFolder"/>
                <add Name="NewsOverview"/>-->
            </ExcludeNodeTypes>
        </IndexSet>
    </ExamineLuceneIndexSets>

    config/ExamineSettings.config

    <?xml version="1.0"?>
    <!-- 
    Umbraco examine is an extensible indexer and search engine.
    This configuration file can be extended to add your own search/index providers.
    Index sets can be defined in the ExamineIndex.config if you're using the standard provider model.
    
    More information and documentation can be found on CodePlex: http://umbracoexamine.codeplex.com
    -->
    <Examine>
        <ExamineIndexProviders>
            <providers>
                <add name="InternalIndexer" type="UmbracoExamine.UmbracoContentIndexer, UmbracoExamine"
                     runAsync="true"
                     supportUnpublished="true"
                     supportProtected="true"
                     interval="10"
                     analyzer="Lucene.Net.Analysis.Standard.StandardAnalyzer, Lucene.Net"/>
                <add name="InternalMemberIndexer" type="UmbracoExamine.UmbracoMemberIndexer, UmbracoExamine"
                     runAsync="true"
                     supportUnpublished="true"
                     supportProtected="true"
                     interval="10"
                     analyzer="Lucene.Net.Analysis.Standard.StandardAnalyzer, Lucene.Net"/>
                <add name="SiteSearchIndexer" type="UmbracoExamine.UmbracoContentIndexer, UmbracoExamine"
                     runAsync="true"
                     supportUnpublished="false"
                     supportProtected="false"
                     interval="10"
                     analyzer="Lucene.Net.Analysis.Standard.StandardAnalyzer, Lucene.Net"/>
            </providers>
        </ExamineIndexProviders>
        <ExamineSearchProviders defaultProvider="SiteSearchSearcher">
            <providers>
                <add name="InternalSearcher" type="UmbracoExamine.UmbracoExamineSearcher, UmbracoExamine"
                     analyzer="Lucene.Net.Analysis.Standard.StandardAnalyzer, Lucene.Net"/>
                <add name="InternalMemberSearcher" type="UmbracoExamine.UmbracoExamineSearcher, UmbracoExamine"
                     analyzer="Lucene.Net.Analysis.Standard.StandardAnalyzer, Lucene.Net" enableLeadingWildcards="true"/>
                <add name="SiteSearchSearcher" type="UmbracoExamine.UmbracoExamineSearcher, UmbracoExamine"
                     analyzer="Lucene.Net.Analysis.Standard.StandardAnalyzer, Lucene.Net" enableLeadingWildcards="true"/>
            </providers>
        </ExamineSearchProviders>
    </Examine>
    

    web.config (first lines):

    <?xml version="1.0" encoding="utf-8"?>
    <configuration>
      <configSections>
        <section name="urlrewritingnet" restartOnExternalChanges="true" requirePermission="false" type="UrlRewritingNet.Configuration.UrlRewriteSection, UrlRewritingNet.UrlRewriter" />
        <section name="microsoft.scripting" type="Microsoft.Scripting.Hosting.Configuration.Section, Microsoft.Scripting, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" requirePermission="false" />
        <section name="clientDependency" type="ClientDependency.Core.Config.ClientDependencySection, ClientDependency.Core" />
        <section name="Examine" type="Examine.Config.ExamineSettings, Examine" />
        <section name="ExamineLuceneIndexSets" type="Examine.LuceneEngine.Config.IndexSets, Examine" />
      </configSections>
      <urlrewritingnet configSource="config\UrlRewriting.config" />
      <microsoft.scripting configSource="config\scripting.config" />
      <clientDependency configSource="config\ClientDependency.config" />
      <Examine configSource="config\ExamineSettings.config" />
      <ExamineLuceneIndexSets configSource="config\ExamineIndex.config" />
    <skip-the-rest/>

     

  • Thijs Kuipers 43 posts 66 karma points
    Jan 04, 2011 @ 13:54
    Thijs Kuipers
    0

    And I just realized my entire last post was BS as you're referring to reading an external XML file. My sincerest apologies.

  • Greyhound 102 posts 124 karma points
    Jan 04, 2011 @ 14:14
    Greyhound
    0

    lol - the whole incident has made me feel like crying into my coffee but at least your previous message made me laugh.

    Thanks for taking the time to have a look.

  • Thijs Kuipers 43 posts 66 karma points
    Jan 04, 2011 @ 14:26
    Thijs Kuipers
    0

    Did you try to build the example code on Using Examine to index & search with ANY data source with the latest binaries from Examine 1.0 RTM? (I presume that is where your SimpleDataIndexer and ExamineDemo.CustomDataService come from). Does it work as a stand-alone indexer?

  • Mounhim Tahtahi 41 posts 62 karma points
    Jan 17, 2011 @ 11:33
    Mounhim Tahtahi
    0

    Did anyone succeed in implementing search with a custom data source as layed out in the example of farmcode.org without breaking the internal search already. I am having the same problem as greyhound.

  • Tom Maton 387 posts 660 karma points
    Jan 31, 2011 @ 13:52
    Tom Maton
    0

    I would like to know this too as I've tried a number of things but cant get anything to work correctly.

    Thanks

    Tom

  • Ismail Mayat 4511 posts 10092 karma points MVP 2x admin c-trib
    Jan 31, 2011 @ 17:00
    Ismail Mayat
    1

    Are you using the latest version from codeplex?

    Regards

    Ismail

  • Tom Maton 387 posts 660 karma points
    Feb 02, 2011 @ 19:24
    Tom Maton
    0

    I can confirm that after downloading the latest version from codeplex has sorted my issue and now indexing my custom data

    Regards

    Tom

  • Kurniawan Kurniawan 202 posts 225 karma points
    Feb 21, 2011 @ 07:37
    Kurniawan Kurniawan
    0

    I still get error with this custom data indexing.

     

    It seems that IndexSets.Instatence is Null

     

    Anyone can help?

     

    Thanks

     

    System.TypeInitializationException: The type initializer for 'Examine.ExamineManager' threw an exception. ---> System.Configuration.ConfigurationErrorsException: Object reference not set to an instance of an object. (D:\DEV\config\ExamineSettings.config line 57) ---> System.NullReferenceException: Object reference not set to an instance of an object. at Examine.LuceneEngine.Providers.LuceneIndexer.Initialize(String name, NameValueCollection config) in D:\~CODEPLEXPROJECTS\UmbracoExamine\Examine.Lucene\Providers\LuceneIndexer.cs:line 85 at Examine.LuceneEngine.Providers.SimpleDataIndexer.Initialize(String name, NameValueCollection config) in D:\~CODEPLEXPROJECTS\UmbracoExamine\Examine.Lucene\Providers\SimpleDataIndexer.cs:line 66 at System.Web.Configuration.ProvidersHelper.InstantiateProvider(ProviderSettings providerSettings, Type providerType) --- End of inner exception stack trace --- at System.Web.Configuration.ProvidersHelper.InstantiateProvider(ProviderSettings providerSettings, Type providerType) at System.Web.Configuration.ProvidersHelper.InstantiateProviders(ProviderSettingsCollection configProviders, ProviderCollection providers, Type providerType) at Examine.ExamineManager.LoadProviders() at Examine.ExamineManager..ctor() at Examine.ExamineManager..cctor() --- End of inner exception stack trace --- at Examine.ExamineManager.get_Instance() at Usercontrols.CMS.Tree.ReindexSearchIndex.btnRebuildIndex_OnClick(Object sender, EventArgs e) in D:\DEV\usercontrols\CMS\Tree\ReindexSearchIndex.aspx.cs:line 172

  • Connie DeCinko 931 posts 1160 karma points
    May 11, 2011 @ 20:36
    Connie DeCinko
    0

    No one has answered the question...  do you put the provider information for the external datasource in ExamineSettings.config and ExamineIndex.config or should they be in a seperate file?

    I too agree, that documention is extremely lacking.  One blog post with one basic example does not make for good documentation.

     

  • James Woodmancy 6 posts 26 karma points
    Dec 16, 2011 @ 11:54
    James Woodmancy
    0

    I am having a simliar problem with umbraco version 4.7.1

     

    When I upload the Examine.LuceneEngine.dll it crashes my xlst files.  when I go into the save them I get the following error

     

    System.Exception: Unable to load one or more of the types in assembly 'Examine.LuceneEngine, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'. Exceptions were thrown:
    System.TypeLoadException: Method 'Range' in type 'Examine.LuceneEngine.SearchCriteria.LuceneQuery' from assembly 'Examine.LuceneEngine, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' does not have an implementation.
    System.TypeLoadException: Method 'Range' in type 'Examine.LuceneEngine.SearchCriteria.LuceneSearchCriteria' from assembly 'Examine.LuceneEngine, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' does not have an implementation.
    at umbraco.BusinessLogic.Utils.TypeFinder.FindClassesMarkedWithAttribute(Assembly assembly, Type attribute)
    at umbraco.BusinessLogic.Utils.TypeFinder.FindClassesMarkedWithAttribute(Type attribute)
    at umbraco.macro.GetXsltExtensionsImpl()
    at umbraco.cms.businesslogic.cache.Cache.GetCacheItem[TT](String cacheKey, Object syncLock, CacheItemPriority priority, CacheItemRemovedCallback refreshAction, CacheDependency cacheDependency, TimeSpan timeout, GetCacheItemDelegate`1 getCacheItem)
    at umbraco.macro.GetXsltExtensions()
    at umbraco.macro.AddMacroXsltExtensions()
    at umbraco.presentation.webservices.codeEditorSave.SaveXslt(String fileName, String oldName, String fileContents, Boolean ignoreDebugging)

     

    Did anyone successfully get this working with umbraco 4.7.1?

     

    Thanks

    James

Please Sign in or register to post replies

Write your reply to:

Draft