diff --git a/portal-impl/src/com/liferay/portlet/wiki/util/WikiPageIndexer.java b/portal-impl/src/com/liferay/portlet/wiki/util/WikiPageIndexer.java
index 6171dd176a4d50c106949a03590ba150fff2f3e4..19344b223c59c7fc4dd671d2c8f057af9b869134 100644
--- a/portal-impl/src/com/liferay/portlet/wiki/util/WikiPageIndexer.java
+++ b/portal-impl/src/com/liferay/portlet/wiki/util/WikiPageIndexer.java
@@ -18,9 +18,10 @@ import com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery;
 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
 import com.liferay.portal.kernel.dao.orm.Property;
 import com.liferay.portal.kernel.dao.orm.PropertyFactoryUtil;
-import com.liferay.portal.kernel.dao.orm.QueryUtil;
 import com.liferay.portal.kernel.exception.PortalException;
 import com.liferay.portal.kernel.exception.SystemException;
+import com.liferay.portal.kernel.log.Log;
+import com.liferay.portal.kernel.log.LogFactoryUtil;
 import com.liferay.portal.kernel.search.BaseIndexer;
 import com.liferay.portal.kernel.search.BooleanClauseOccur;
 import com.liferay.portal.kernel.search.BooleanQuery;
@@ -28,7 +29,6 @@ import com.liferay.portal.kernel.search.BooleanQueryFactoryUtil;
 import com.liferay.portal.kernel.search.Document;
 import com.liferay.portal.kernel.search.DocumentImpl;
 import com.liferay.portal.kernel.search.Field;
-import com.liferay.portal.kernel.search.Hits;
 import com.liferay.portal.kernel.search.SearchContext;
 import com.liferay.portal.kernel.search.SearchEngineUtil;
 import com.liferay.portal.kernel.search.Summary;
@@ -77,21 +77,26 @@ public class WikiPageIndexer extends BaseIndexer {
 
 		WikiPage page = null;
 
-		if (obj instanceof DLFileEntry) {
-			DLFileEntry dlFileEntry = (DLFileEntry)obj;
+		try {
+			if (obj instanceof DLFileEntry) {
+				DLFileEntry dlFileEntry = (DLFileEntry)obj;
 
-			page = WikiPageAttachmentsUtil.getPage(
-				dlFileEntry.getFileEntryId());
+				page = WikiPageAttachmentsUtil.getPage(
+					dlFileEntry.getFileEntryId());
 
-			document.addKeyword(
-				Field.CLASS_NAME_ID,
-				PortalUtil.getClassNameId(WikiPage.class.getName()));
-			document.addKeyword(Field.CLASS_PK, page.getResourcePrimKey());
-		}
-		else if (obj instanceof MBMessage) {
-			MBMessage message = (MBMessage)obj;
+				document.addKeyword(
+					Field.CLASS_NAME_ID,
+					PortalUtil.getClassNameId(WikiPage.class.getName()));
+				document.addKeyword(Field.CLASS_PK, page.getResourcePrimKey());
+			}
+			else if (obj instanceof MBMessage) {
+				MBMessage message = (MBMessage)obj;
 
-			page = WikiPageLocalServiceUtil.getPage(message.getClassPK());
+				page = WikiPageLocalServiceUtil.getPage(message.getClassPK());
+			}
+		}
+		catch (Exception e) {
+			return;
 		}
 
 		document.addKeyword(Field.NODE_ID, page.getNodeId());
@@ -121,6 +126,13 @@ public class WikiPageIndexer extends BaseIndexer {
 	}
 
 	@Override
+	public boolean isVisible(long classPK, int status) throws Exception {
+		WikiPage page = WikiPageLocalServiceUtil.getPage(classPK);
+
+		return isVisible(page.getStatus(), status);
+	}
+
+	@Override
 	public void postProcessContextQuery(
 			BooleanQuery contextQuery, SearchContext searchContext)
 		throws Exception {
@@ -138,6 +150,10 @@ public class WikiPageIndexer extends BaseIndexer {
 					WikiNodeServiceUtil.getNode(nodeId);
 				}
 				catch (Exception e) {
+					if (_log.isDebugEnabled()) {
+						_log.debug("Unable to get wiki node " + nodeId, e);
+					}
+
 					continue;
 				}
 
@@ -168,38 +184,10 @@ public class WikiPageIndexer extends BaseIndexer {
 			SearchEngineUtil.deleteDocument(
 				getSearchEngineId(), companyId, document.get(Field.UID));
 		}
-		else if (obj instanceof WikiNode) {
-			WikiNode node = (WikiNode)obj;
-
-			BooleanQuery booleanQuery = BooleanQueryFactoryUtil.create(
-				searchContext);
-
-			booleanQuery.addRequiredTerm(Field.PORTLET_ID, PORTLET_ID);
-
-			booleanQuery.addRequiredTerm("nodeId", node.getNodeId());
-
-			Hits hits = SearchEngineUtil.search(
-				getSearchEngineId(), node.getCompanyId(), booleanQuery,
-				QueryUtil.ALL_POS, QueryUtil.ALL_POS);
-
-			for (int i = 0; i < hits.getLength(); i++) {
-				Document document = hits.doc(i);
-
-				SearchEngineUtil.deleteDocument(
-					getSearchEngineId(), node.getCompanyId(),
-					document.get(Field.UID));
-			}
-		}
 		else if (obj instanceof WikiPage) {
 			WikiPage page = (WikiPage)obj;
 
-			Document document = new DocumentImpl();
-
-			document.addUID(PORTLET_ID, page.getNodeId(), page.getTitle());
-
-			SearchEngineUtil.deleteDocument(
-				getSearchEngineId(), page.getCompanyId(),
-				document.get(Field.UID));
+			deleteDocument(page.getCompanyId(), page.getResourcePrimKey());
 		}
 	}
 
@@ -209,7 +197,7 @@ public class WikiPageIndexer extends BaseIndexer {
 
 		Document document = getBaseModelDocument(PORTLET_ID, page);
 
-		document.addUID(PORTLET_ID, page.getNodeId(), page.getTitle());
+		document.addUID(PORTLET_ID, page.getResourcePrimKey());
 
 		String content = HtmlUtil.extractText(
 			WikiUtil.convert(page, null, null, null));
@@ -246,7 +234,7 @@ public class WikiPageIndexer extends BaseIndexer {
 	protected void doReindex(Object obj) throws Exception {
 		WikiPage page = (WikiPage)obj;
 
-		if (!page.isApproved() && !page.isInTrash()) {
+		if (!page.isHead() || (!page.isApproved() && !page.isInTrash())) {
 			return;
 		}
 
@@ -262,7 +250,11 @@ public class WikiPageIndexer extends BaseIndexer {
 
 	@Override
 	protected void doReindex(String className, long classPK) throws Exception {
-		WikiPage page = WikiPageLocalServiceUtil.getPage(classPK);
+		WikiPage page = WikiPageLocalServiceUtil.fetchWikiPage(classPK);
+
+		if (page == null) {
+			page = WikiPageLocalServiceUtil.getPage(classPK, (Boolean)null);
+		}
 
 		doReindex(page);
 	}
@@ -319,12 +311,21 @@ public class WikiPageIndexer extends BaseIndexer {
 			}
 
 			@Override
-			protected void performAction(Object object) throws PortalException {
+			protected void performAction(Object object) {
 				WikiPage page = (WikiPage)object;
 
-				Document document = getDocument(page);
+				try {
+					Document document = getDocument(page);
 
-				addDocument(document);
+					addDocument(document);
+				}
+				catch (PortalException pe) {
+					if (_log.isWarnEnabled()) {
+						_log.warn(
+							"Unable to index wiki page " + page.getPageId(),
+							pe);
+					}
+				}
 			}
 
 		};
@@ -336,4 +337,6 @@ public class WikiPageIndexer extends BaseIndexer {
 		actionableDynamicQuery.performActions();
 	}
 
+	private static Log _log = LogFactoryUtil.getLog(WikiPageIndexer.class);
+
 }
\ No newline at end of file
