mimaison commented on code in PR #15786:
URL: https://github.com/apache/kafka/pull/15786#discussion_r1577491649


##########
core/src/main/scala/kafka/server/SharedServer.scala:
##########
@@ -107,16 +107,16 @@ class SharedServer(
   @volatile var brokerMetrics: BrokerServerMetrics = _
   @volatile var controllerServerMetrics: ControllerMetadataMetrics = _
   @volatile var loader: MetadataLoader = _
-  val snapshotsDisabledReason = new AtomicReference[String](null)
+  private val snapshotsDisabledReason = new AtomicReference[String](null)
   @volatile var snapshotEmitter: SnapshotEmitter = _
-  @volatile var snapshotGenerator: SnapshotGenerator = _
-  @volatile var metadataLoaderMetrics: MetadataLoaderMetrics = _
+  @volatile private var snapshotGenerator: SnapshotGenerator = _
+  @volatile private var metadataLoaderMetrics: MetadataLoaderMetrics = _
 
   def clusterId: String = metaPropsEnsemble.clusterId().get()
 
-  def nodeId: Int = metaPropsEnsemble.nodeId().getAsInt()
+  def nodeId: Int = metaPropsEnsemble.nodeId().getAsInt
 
-  def isUsed(): Boolean = synchronized {
+  private def isUsed(): Boolean = synchronized {

Review Comment:
   Yeah Scala seems to favor not using braces for 0 arguments getters. I've not 
made that change as we have a lot of instances of these and that would make a 
huge diff. 



-- 
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: jira-unsubscr...@kafka.apache.org

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

Reply via email to