Media folder children issue (Seems to be an Examine issue)
I have a v7 site with a lot of media (~150 GB) these are mainly images.
A section of the site is a gallery, where the admin user process is:
Make a folder in the media section
Uploads all the images to this folder
Creates a child node of the gallery node and this has a picker to choose the media folder and also a featured main image
The gallery page shows the featured image and title but when clicked it is blank. If however I go into Developer > Examine Management > InternalIndexer > Index info & tools and click on the Rebuild index button to rebuild the index it shows again fine until either I deploy another code change or the site restarts for some reason?
I can also replicate this consistently by deleting the \ExamineIndexes\Internal\Index folder from disk.
To try and avoid this issue on deployment (as I purge the entire site root folder on deployment) this and the media folder is outside of the site root and has a virtual directory to link it back up to these persistent folders.
The view for the gallery page is :
<div class="gallery">
<p>@mediaFolder.Name</p>
@if (mediaFolder.Children.Any())
{
foreach (var mediaItem in mediaFolder.Children)
{
string mediaExtension = mediaItem.umbracoExtension;
if (mediaExtension == "jpg" || mediaExtension == "png")
{
<a href="@mediaItem.Url" class="itemFixHeightWrapper" title="@mediaItem.Name">
<img src="@mediaItem.Url?width=747&height=499" class="img-responsive" alt="@mediaItem.Name" />
</a>
counter++;
}
else
{
<!-- Item is a @(@mediaExtension == "" ? "Folder" : mediaExtension) -->
}
}
}
else
{
<!-- NO CHILDREN IN MEDIA FOLDER -->
}
</div>
It always returns <!-- NO CHILDREN IN MEDIA FOLDER --> if the Internal index is not rebuild.
Is there a way to either trigger this rebuild process on startup or stop this issue happening?
Media folder children issue (Seems to be an Examine issue)
I have a v7 site with a lot of media (~150 GB) these are mainly images.
A section of the site is a gallery, where the admin user process is:
The gallery page shows the featured image and title but when clicked it is blank. If however I go into
Developer > Examine Management > InternalIndexer > Index info & toolsand click on theRebuild indexbutton to rebuild the index it shows again fine until either I deploy another code change or the site restarts for some reason?I can also replicate this consistently by deleting the
\ExamineIndexes\Internal\Indexfolder from disk.To try and avoid this issue on deployment (as I purge the entire site root folder on deployment) this and the media folder is outside of the site root and has a virtual directory to link it back up to these persistent folders.
The view for the gallery page is :
It always returns
<!-- NO CHILDREN IN MEDIA FOLDER -->if the Internal index is not rebuild.Is there a way to either trigger this rebuild process on startup or stop this issue happening?
I am also not sure if this is similar to https://our.umbraco.com/forum/using-umbraco-and-getting-started/100280-moving-umbraco-project-require-rebuild-index-to-work
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.