dosubot[bot] commented on issue #2667:
URL: 
https://github.com/apache/incubator-hugegraph/issues/2667#issuecomment-2365581755

   <!-- Answer -->
   To disable the legacy master-worker mechanism in a multi-server setup using 
Apache HugeGraph, you need to set the `server.role` configuration option to 
"computer". This can be done in your configuration file as follows:
   
   ```properties
   server.role=computer
   ```
   
   This setting ensures that the `RoleElectionStateMachine` is not initialized, 
effectively disabling the legacy master-worker mechanism. Here is the relevant 
configuration option:
   
   ```java
   public static final ConfigOption<String> SERVER_ROLE =
           new ConfigOption<>(
                   "server.role",
                   "The role of nodes in the cluster, available types are " +
                   "[master, worker, computer]",
                   allowValues("master", "worker", "computer"),
                   "master"
           );
   ```
   
   By setting `server.role` to "computer", the `supportRoleElection` will be 
false, and the role state machine will not be initialized 
<sup>[[1]](https://github.com/apache/incubator-hugegraph/blob/master/hugegraph-server/hugegraph-api/src/main/java/org/apache/hugegraph/config/ServerOptions.java)</sup><sup>[[2]](https://github.com/apache/incubator-hugegraph/blob/master/hugegraph-server/hugegraph-api/src/main/java/org/apache/hugegraph/core/GraphManager.java)</sup>.
   
   
   <!-- Dosu Comment Footer -->
   *To continue talking to [Dosu](https://dosu.dev), mention @dosu.*
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to