[ https://issues.apache.org/jira/browse/SOLR-16470?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17884444#comment-17884444 ]
Matthew Biscocho commented on SOLR-16470: ----------------------------------------- [~gerlowskija] Started to look into the filecontent API and noticed it was failing with a stack trace. Doing some digging, I believe I found a regression due to this [commit.|https://github.com/apache/solr/pull/1867] Don't fully understand what this does yet but was probably not caught because there are no tests around the filecontent command on this replication API. This will probably need a fix before migrating this API over to V2 {code:java} { "error":{ "msg":"java.lang.IllegalAccessException: access violation: class org.apache.solr.handler.ReplicationHandler$DirectoryFileStream, from public Lookup", "trace":"java.lang.RuntimeException: java.lang.IllegalAccessException: access violation: class org.apache.solr.handler.ReplicationHandler$DirectoryFileStream, from public Lookup\n\tat org.apache.solr.common.util.Utils.getReflectWriter(Utils.java:928)\n\tat org.apache.solr.common.util.TextWriter.writeVal(TextWriter.java:114)\n\tat org.apache.solr.response.TextResponseWriter.writeVal(TextResponseWriter.java:213)\n\tat org.apache.solr.common.util.TextWriter.writeVal(TextWriter.java:48)\n\tat org.apache.solr.common.util.JsonTextWriter.writeNamedListAsMapWithDups(JsonTextWriter.java:404)\n\tat org.apache.solr.common.util.JsonTextWriter.writeNamedList(JsonTextWriter.java:312)\n\tat org.apache.solr.response.JacksonJsonWriter$WriterImpl.writeResponse(JacksonJsonWriter.java:88)\n\tat org.apache.solr.response.JacksonJsonWriter.write(JacksonJsonWriter.java:50)\n\tat org.apache.solr.response.QueryResponseWriterUtil.writeQueryResponse(QueryResponseWriterUtil.java:55)\n\tat org.apache.solr.servlet.HttpSolrCall.writeResponse(HttpSolrCall.java:1012)\n\tat org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:600)\n\tat org.apache.solr.servlet.SolrDispatchFilter.dispatch(SolrDispatchFilter.java:243)\n\tat org.apache.solr.servlet.SolrDispatchFilter.lambda$doFilter$0(SolrDispatchFilter.java:204)\n\tat org.apache.solr.servlet.ServletUtils.traceHttpRequestExecution2(ServletUtils.java:241)\n\tat org.apache.solr.servlet.ServletUtils.rateLimitRequest(ServletUtils.java:209)\n\tat org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:198)\n\tat org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:181)\n\tat org.eclipse.jetty.servlet.FilterHolder.doFilter(FilterHolder.java:210)\n\tat org.eclipse.jetty.servlet.ServletHandler$Chain.doFilter(ServletHandler.java:1635)\n\tat org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:527)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:131)\n\tat org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:598)\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:223)\n\tat org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1580)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:221)\n\tat org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1384)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:176)\n\tat org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:484)\n\tat org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1553)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:174)\n\tat org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1306)\n\tat org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:129)\n\tat org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:149)\n\tat org.eclipse.jetty.server.handler.InetAccessHandler.handle(InetAccessHandler.java:228)\n\tat org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:141)\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)\n\tat org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler.java:301)\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)\n\tat org.eclipse.jetty.server.handler.gzip.GzipHandler.handle(GzipHandler.java:822)\n\tat org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:122)\n\tat org.eclipse.jetty.server.Server.handle(Server.java:563)\n\tat org.eclipse.jetty.server.HttpChannel$RequestDispatchable.dispatch(HttpChannel.java:1598)\n\tat org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:753)\n\tat org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:501)\n\tat org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:287)\n\tat org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:314)\n\tat org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:100)\n\tat org.eclipse.jetty.io.SelectableChannelEndPoint$1.run(SelectableChannelEndPoint.java:53)\n\tat org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.runTask(AdaptiveExecutionStrategy.java:421)\n\tat org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.consumeTask(AdaptiveExecutionStrategy.java:390)\n\tat org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.tryProduce(AdaptiveExecutionStrategy.java:277)\n\tat org.eclipse.jetty.util.thread.strategy.AdaptiveExecutionStrategy.produce(AdaptiveExecutionStrategy.java:193)\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:969)\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.doRunJob(QueuedThreadPool.java:1194)\n\tat org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1149)\n\tat java.base/java.lang.Thread.run(Thread.java:829)\nCaused by: java.lang.IllegalAccessException: access violation: class org.apache.solr.handler.ReplicationHandler$DirectoryFileStream, from public Lookup\n\tat java.base/java.lang.invoke.MemberName.makeAccessException(MemberName.java:942)\n\tat java.base/java.lang.invoke.MethodHandles$Lookup.accessClass(MethodHandles.java:1312)\n\tat org.apache.solr.common.util.Utils.addTraditionalFieldWriters(Utils.java:1021)\n\tat org.apache.solr.common.util.Utils.getReflectData(Utils.java:980)\n\tat org.apache.solr.common.util.Utils.getReflectWriter(Utils.java:915)\n\t... 56 more\n", "code":500 } }% {code} > Create V2 equivalent of V1 Replication: Get IndexVersion, Get FileStream, Get > File List > --------------------------------------------------------------------------------------- > > Key: SOLR-16470 > URL: https://issues.apache.org/jira/browse/SOLR-16470 > Project: Solr > Issue Type: Sub-task > Components: v2 API > Affects Versions: 9.2 > Reporter: Sanjay Dutt > Priority: Major > Labels: V2, newdev > Time Spent: 4h 20m > Remaining Estimate: 0h > > Replication Handler has no v2 equivalent. This ticket is covering few > endpoints from ReplicationHandler such as Get IndexVersion, Get FileStream, > Get File List. > Existing V1 > |-GET /solr/collName/replication?command=indexversion-| > |GET /solr/collName/replication?command=filecontent| > |-GET /solr/collName/replication?command=filelist-| > Proposed API design > |-GET /api/cores/coreName/replication/indexversion-| > |GET /api/cores/coreName/replication/files/filePath| > |-GET /api/cores/coreName/replication/files-| > few other pointers that might be helpful, especially for newcomers: > * The v1 logic for this API lives in ReplicationHandler > * [Some discussion of how APIs work in Solr (Particularly the "APIs in Solr" > section.)|https://github.com/apache/solr/blob/main/dev-docs/apis.adoc#apis-in-solr] > * [A step-by-step guide to creating APIs using the preferred v2 API > framework|https://github.com/apache/solr/blob/main/dev-docs/apis.adoc#writing-jax-rs-apis] > * [A recent PR that adds a v2 API, as an > example|https://github.com/apache/solr/pull/2144] > -- This message was sent by Atlassian Jira (v8.20.10#820010) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org