haohao0103 opened a new issue, #2867:
URL: https://github.com/apache/incubator-hugegraph/issues/2867

   ### Bug Type (问题类型)
   
   other exception / error (其他异常报错)
   
   ### Before submit
   
   - [x] 我已经确认现有的 [Issues](https://github.com/apache/hugegraph/issues) 与 
[FAQ](https://hugegraph.apache.org/docs/guides/faq/) 中没有相同 / 重复问题 (I have 
confirmed and searched that there are no similar problems in the historical 
issue and documents)
   
   ### Environment (环境信息)
   
   - Server Version: 1.5.0 (master)
   
   
   
   
   ### Expected & Actual behavior (期望与实际表现)
   
   There is a reflection call error in the getState method of the PD  
RaftEngine.java file. This method attempts to retrieve the state field value of 
a Replicator object through reflection, but incorrectly uses this.raftNode as 
the parameter instead of the passed Replicator r parameter.
   
   ```
   private Replicator.State getState(Replicator r) {
       var clz = r.getClass();
       try {
           var f = clz.getDeclaredField("state");
           f.setAccessible(true);
           var state = (Replicator.State) f.get(this.raftNode); // Error: 
should use r instead of this.raftNode
           f.setAccessible(false);
           return state;
       } catch (NoSuchFieldException | IllegalAccessException e) {
           log.info("getReplicatorGroup: error {}", e.getMessage());
           return null;
       }
   }
   
   ```
   
   ### Vertex/Edge example (问题点 / 边数据举例)
   
   ```javascript
   
   ```
   
   ### Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)
   
   ```javascript
   
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@hugegraph.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to