Copied to clipboard

Flag this post as spam?

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


  • Skippy 10 posts 57 karma points
    Sep 18, 2017 @ 15:14
    Skippy
    0

    Examine - no indexes showing up in backoffice

    I've run into an odd issue with Examine. I noticed there were no search results being returned anywhere throughout the site (!). Couldn't see anything obviously weird happening, so I (physically) deleted the examine cache, restarted the web app and it rebuilt successfully - search now works again.

    I went into the backoffice to check on the status of the new index, but apparently there are no indexes:

    Examine backoffice

    I know this is not the case because search works. There's nothing untoward in the error log.

    2017-09-18 15:58:03,353 [P3792/D2/T1] INFO  Umbraco.Web.Search.ExamineEvents - Initializing Examine and binding to business logic events
    2017-09-18 15:58:03,353 [P3792/D2/T1] INFO  Umbraco.Web.Search.ExamineEvents - Adding examine event handlers for index providers: 3
    2017-09-18 15:58:03,392 [P3792/D2/T1] INFO  Umbraco.Core.CoreBootManager - Umbraco application startup complete (took 2453ms)
    

    I'm not sure where to go with this because Examine has always been pretty much plug and play.

    We're on Umbraco 7.5.9, with Examine 1.80.

  • Craig Mayers 164 posts 508 karma points
    Sep 18, 2017 @ 23:18
    Craig Mayers
    0

    Hi Skippy,

    Have you checked the permissions on the App_Data folder and its child folders?

    It should have Modify/Full Control.

    See the link below:

    https://our.umbraco.org/documentation/getting-started/setup/install/permissions

    Craig

  • Skippy 10 posts 57 karma points
    Sep 19, 2017 @ 08:58
    Skippy
    0

    Hi Craig,

    thanks for the suggestion but that's not the issue - this is a fully working install & the indexes are being built successfully. When I open 'Developer' page in the back office, I can inspect the responses from:

    /umbraco/BackOffice/Api/ExamineManagementApi/GetIndexerDetails
    

    and

    /umbraco/BackOffice/Api/ExamineManagementApi/GetSearcherDetails
    

    And they look sane, for instance the internal indexer reports:

    {
      "$type": "Umbraco.Web.Search.ExamineIndexerModel, umbraco",
      "indexCriteria": {
        ... loads of objects ...
      },
      "documentCount": 346,
      "fieldCount": 131,
      "deletionCount": 36,
      "isOptimized": false,
      "isLuceneIndex": true,
      "name": "InternalIndexer",
      "providerProperties": {
        "$type": "System.Collections.Generic.Dictionary`2[[System.String, mscorlib],[System.String, mscorlib]], mscorlib",
        "AutomaticallyOptimize": "False",
        "CommitCount": "0",
        "DataService": "UmbracoExamine.DataServices.UmbracoDataService",
        "DirectoryFactory": "",
        "DisableXmlDocumentLookup": "False",
        "EnableDefaultEventHandler": "True",
        "IndexingAnalyzer": "Lucene.Net.Analysis.WhitespaceAnalyzer",
        "IndexSetName": "InternalIndexSet",
        "LuceneIndexFolder": "...location on disk...\\App_Data\\TEMP\\ExamineIndexes\\Internal\\Index",
        "Name": "InternalIndexer",
        "OptimizationCommitThreshold": "100",
        "RunAsync": "True",
        "SupportProtectedContent": "True",
        "SupportUnpublishedContent": "True",
        "TempStorageLocation": "",
        "UseTempStorage": "False"
      }
    }
    

    ... yet nothing is shown in the Examine management page in the back office.

    Search works both in the back office, and externally using the ezSearch package, but the index cannot be interrogated or refreshed using the pages in the back office.

    I now need to extend Examine (plugging in another document management system), but clearly something is wrong here and I'm not able to start until this is resolved.

  • Ismail Mayat 4511 posts 10090 karma points MVP 2x admin c-trib
    Sep 19, 2017 @ 10:50
    Ismail Mayat
    0

    Skippy,

    Fire up chrome inspector when viewing the dashboard in developer section i reckon there may be a javascript error.

    Regards

    Ismail

  • Skippy 10 posts 57 karma points
    Sep 19, 2017 @ 12:34
    Skippy
    0

    Hi Ismail,

    I thought so too - it seems like the angular components aren't rendering correctly, but there's nothing showing up in the console whatsoever. I've added an angular inspector to Chrome and nothing jumps out at me (but then I know nothing about angular).

    It's as if there's an error being caught somewhere. This is incredibly odd, because there is a second site built from largely the same codebase which is unaffected by this. An empty console Craig, you're right - I'm trying to work backwards but Examine hasn't been touched for a long time, so unfortunately I have no idea when this issue first arose. It could be months. There is another, possibly related issue with Redirect URL management, in that the symptom is the same; the json is returned to the front end, but not quite everything is being rendered in the page (the pager is there, but no content). Again, this is a feature that 'just works' and we don't check routinely. It does appear, however, that redirects are no longer being added correctly. No redirect URLs?! I've done a diff on the /umbraco/ directory across a working, and an affected site, and there is nothing to report.

    The sites are managed by content editors and published to a live site via Courier.

    I'll get down to some more serious debugging, I had hoped this would be an issue someone would have seen before!

    Cheers, Ben.

  • Ismail Mayat 4511 posts 10090 karma points MVP 2x admin c-trib
    Sep 19, 2017 @ 13:30
    Ismail Mayat
    0

    just check if in web.config you have debug = false if so then try setting it to true and see if that gets things working.

    Regards

    Ismail

  • Skippy 10 posts 57 karma points
    Sep 19, 2017 @ 13:40
    Skippy
    0

    Hi Ismail,

    was in debug mode throughout. Setting to false, back to true - no change.

    I'm going to take a copy of the site & database and cut it right back, it's pretty unwieldy trying to debug something of this scale. I'll update if there's anything new.

    Cheers, Ben.

  • Craig Mayers 164 posts 508 karma points
    Sep 19, 2017 @ 13:56
    Craig Mayers
    0

    Hi Skippy,

    Sorry, I can't be of more assistance.

    I was going to suggest doing a full diff on the whole solution folder...

    Since you mentioned using Courier, which I haven't used for some time now... but it used to be super buggy and it had a tendency to miss certain files when copying between sites.

    I tend to use Beyond Compare for any diffs: https://www.scootersoftware.com/

    You can get a 30-day free trial.

    Let me know how it goes, good luck!

    Craig

  • Skippy 10 posts 57 karma points
    Sep 19, 2017 @ 14:14
    Skippy
    0

    Thanks Craig, your help is much appreciated anyway. I have done a full diff between the sites, and again nothing immediately jumped out - so it's time to take it line by line.

    I can target the 'known working' database with the 'problematic' web application, and the issue persists; the inverse is also true - so it's clearly an issue in the web app somewhere.

    The site which is showing issues has had a lot more use, and there have been a lot more Courier runs, but we'll see.

    Cheers, Ben.

  • Craig Mayers 164 posts 508 karma points
    Sep 19, 2017 @ 11:37
    Craig Mayers
    0

    Hi, Skippy

    OK, so it must be a conflict somewhere... as the indexes seem to be working fine.

    Did this ever work for you? If so, do you know what changed before it stopped working (i.e. did you install any packages etc.)?

    Like Ismail said, can you check the developer console for any js errors?

    Craig

  • Skippy 10 posts 57 karma points
    Sep 19, 2017 @ 15:10
    Skippy
    0

    Found it! We've been using some legacy code for certain parts of the site which relied upon .net type names coming through in JSON.

    The culprit was this:

    protected override void ApplicationInitialized(UmbracoApplicationBase umbracoApplication, ApplicationContext applicationContext)
    {
    
        base.ApplicationInitialized(umbracoApplication, applicationContext);
    
        var jsonSettings = GlobalConfiguration.Configuration.Formatters.JsonFormatter.SerializerSettings;
        jsonSettings.TypeNameHandling = Newtonsoft.Json.TypeNameHandling.All;
    
    }
    

    This was in turn making some endpoints in the Umbraco backoffice produce malformed json, including those for Examine and URL management.

    The angular code was failing silently when it encountered these malformed responses.

    Now, to rewrite the legacy code. Delightful. Thanks Ismail and Craig for your thoughtful responses.

    Regards, Ben.

  • Craig Mayers 164 posts 508 karma points
    Sep 19, 2017 @ 15:37
    Craig Mayers
    0

    Excellent news!

    Happy you found it and can now continue coding :-)

    Regards

    Craig

Please Sign in or register to post replies

Write your reply to:

Draft