Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Index rebuild won't finish successfully #138

Open
githoober opened this issue Mar 21, 2023 · 6 comments
Open

Index rebuild won't finish successfully #138

githoober opened this issue Mar 21, 2023 · 6 comments

Comments

@githoober
Copy link

githoober commented Mar 21, 2023

After requesting the rebuilding composer-hosted index, the scheduled process failed to succeed with an error No facet of type ContentFacet attached to repository composer-hosted

2023-03-21 01:26:28,176+0000 INFO  [qtp379212480-786]  admin org.sonatype.nexus.quartz.internal.task.QuartzTaskInfo - Task 'Repair - Rebuild repository search' [repository.rebuild-index] : state=RUNNING
2023-03-21 01:26:28,180+0000 INFO  [qtp379212480-786]  admin org.sonatype.nexus.scheduling.TaskSchedulerImpl - Task 'Repair - Rebuild repository search' [repository.rebuild-index] scheduled: now
2023-03-21 01:26:28,190+0000 INFO  [quartz-12-thread-20]  *SYSTEM org.sonatype.nexus.repository.search.index.RebuildIndexTask - Task log: /nexus-data/log/tasks/repository.rebuild-index-20230321012628187.log
2023-03-21 01:26:28,190+0000 INFO  [quartz-12-thread-20]  *SYSTEM org.sonatype.nexus.repository.content.search.elasticsearch.SearchFacetImpl - Rebuilding index of repository composer-hosted
2023-03-21 01:26:28,206+0000 INFO  [elasticsearch[07F99811-705924FF-7743F00F-F183D49A-CA3B7148][clusterService#updateTask][T#1]]  *SYSTEM org.elasticsearch.cluster.metadata - [07F99811-705924FF-7743F00F-F183D49A-CA3B7148] [18ffb221aedff62e98e358427548207a2dbfebc7] creating index, cause [api], templates [], shards [1]/[0], mappings [component]
2023-03-21 01:26:28,218+0000 ERROR [quartz-12-thread-20]  *SYSTEM org.sonatype.nexus.repository.content.search.elasticsearch.SearchFacetImpl - Unable to rebuild search index for repository composer-hosted
org.sonatype.nexus.repository.MissingFacetException: No facet of type ContentFacet attached to repository composer-hosted
	at org.sonatype.nexus.repository.manager.internal.RepositoryImpl.facet(RepositoryImpl.java:327)
	at org.sonatype.nexus.repository.content.search.elasticsearch.SearchFacetImpl.rebuildComponentIndex(SearchFacetImpl.java:156)
	at org.sonatype.nexus.repository.content.search.elasticsearch.SearchFacetImpl.rebuildIndex(SearchFacetImpl.java:147)
	at org.sonatype.nexus.repository.content.search.elasticsearch.SearchFacetImpl$$EnhancerByGuice$$436432073.GUICE$TRAMPOLINE(<generated>)
	at com.google.inject.internal.InterceptorStackCallback$InterceptedMethodInvocation.proceed(InterceptorStackCallback.java:74)
	at org.sonatype.nexus.common.stateguard.MethodInvocationAction.run(MethodInvocationAction.java:39)
	at org.sonatype.nexus.common.stateguard.StateGuard$GuardImpl.run(StateGuard.java:272)
	at org.sonatype.nexus.common.stateguard.GuardedInterceptor.invoke(GuardedInterceptor.java:54)
	at com.google.inject.internal.InterceptorStackCallback$InterceptedMethodInvocation.proceed(InterceptorStackCallback.java:75)
	at com.google.inject.internal.InterceptorStackCallback.invoke(InterceptorStackCallback.java:55)
	at org.sonatype.nexus.repository.content.search.elasticsearch.SearchFacetImpl$$EnhancerByGuice$$436432073.rebuildIndex(<generated>)
	at org.sonatype.nexus.repository.search.index.RebuildIndexTask.execute(RebuildIndexTask.java:33)
	at org.sonatype.nexus.repository.RepositoryTaskSupport.execute(RepositoryTaskSupport.java:79)
	at org.sonatype.nexus.scheduling.TaskSupport.call(TaskSupport.java:100)
	at org.sonatype.nexus.quartz.internal.task.QuartzTaskJob.doExecute(QuartzTaskJob.java:143)
	at org.sonatype.nexus.quartz.internal.task.QuartzTaskJob.execute(QuartzTaskJob.java:106)
	at org.quartz.core.JobRunShell.run(JobRunShell.java:202)
	at org.sonatype.nexus.quartz.internal.QuartzThreadPool.lambda$0(QuartzThreadPool.java:145)
	at org.sonatype.nexus.thread.internal.MDCAwareRunnable.run(MDCAwareRunnable.java:40)
	at org.apache.shiro.subject.support.SubjectRunnable.doRun(SubjectRunnable.java:120)
	at org.apache.shiro.subject.support.SubjectRunnable.run(SubjectRunnable.java:108)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:750)
2023-03-21 01:26:28,220+0000 INFO  [quartz-12-thread-20]  *SYSTEM org.sonatype.nexus.quartz.internal.task.QuartzTaskInfo - Task 'Repair - Rebuild repository search' [repository.rebuild-index] state change RUNNING -> OK
2023-03-21 01:26:28,228+0000 INFO  [elasticsearch[07F99811-705924FF-7743F00F-F183D49A-CA3B7148][clusterService#updateTask][T#1]]  *SYSTEM org.elasticsearch.cluster.routing.allocation - [07F99811-705924FF-7743F00F-F183D49A-CA3B7148] Cluster health status changed from [RED] to [GREEN] (reason: [shards started [[18ffb221aedff62e98e358427548207a2dbfebc7][0]] ...]).
  • What are you trying to do?
    I want to rebuild the composer-hosted index

  • What feature or behavior is this required for?
    Background tasks

  • How could we solve this issue? (Not knowing is okay!)

@bsnarski-CKPL
Copy link

I have the same problem. Did you manage to solve this problem? @githoober

@githoober
Copy link
Author

githoober commented May 22, 2023

@bsnarski

No, unfortunately, I could not find a solution to this problem.

A few tickets describe different problems related to the missing ContentFacet facet implementation. The only solution is to implement this missing functionality.

#131, #117, #109

@bsnarski-CKPL
Copy link

@githoober
Do you have implementations of this functionality ?You could share this code?

@githoober
Copy link
Author

githoober commented May 22, 2023

@bsnarski I don't.

Whoever created the plugin has a profound knowledge of the plugin and the Nexus application to make such an improvement.

Unfortunately, I don't have time to investigate and implement it right now.

@githoober
Copy link
Author

Even if I find time and try to improve this plugin, it's not clear if there will be anyone who can approve and merge it. The development here seems dead.

@pju51
Copy link

pju51 commented Jan 17, 2024

hello
any news on this issue ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants