File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
entities/src/main/scala/com/devsisters/shardcake Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -108,8 +108,8 @@ class Sharding private (
108108 pod = shards.get(shardId)
109109 } yield pod.contains(address)
110110
111- def getNumberOfPods : UIO [Int ] =
112- shardAssignments.get.map(_.values.toSet.size )
111+ def getPods : UIO [Set [ PodAddress ] ] =
112+ shardAssignments.get.map(_.values.toSet)
113113
114114 private [shardcake] val refreshAssignments : ZManaged [Clock , Nothing , Unit ] = {
115115 val assignmentStream =
@@ -387,8 +387,8 @@ object Sharding {
387387 ZIO .service[Sharding ].map(_.messenger(entityType))
388388
389389 /**
390- * Get the number of pods currently registered to the Shard Manager
390+ * Get the list of pods currently registered to the Shard Manager
391391 */
392- def getNumberOfPods : RIO [Has [Sharding ], Int ] =
393- ZIO .serviceWith[Sharding ](_.getNumberOfPods )
392+ def getPods : RIO [Has [Sharding ], Set [ PodAddress ] ] =
393+ ZIO .serviceWith[Sharding ](_.getPods )
394394}
You can’t perform that action at this time.
0 commit comments