In Scala, a compiled .class file may not directly correspond to its source filename. For example, Hello.scala can produce both Hello.class and World.class.
Use case
Project: pekko-cluster-sharding-typed
source: https://repo1.maven.org/maven2/org/apache/pekko/pekko-cluster-sharding-typed_3/1.2.0/pekko-cluster-sharding-typed_3-1.2.0-sources.jar
binary: https://repo1.maven.org/maven2/org/apache/pekko/pekko-cluster-sharding-typed_3/1.2.0/pekko-cluster-sharding-typed_3-1.2.0.jar
With filename mapping:
source
from/org/apache/pekko/cluster/sharding/typed/ClusterShardingQuery.scala
binary
to/org/apache/pekko/cluster/sharding/typed/ClusterShardingQuery.class
to/org/apache/pekko/cluster/sharding/typed/GetClusterShardingStats.class
to/org/apache/pekko/cluster/sharding/typed/GetShardRegionState.class
Only the to/org/apache/pekko/cluster/sharding/typed/ClusterShardingQuery.class are considered mapped.
GetClusterShardingStats.class and GetShardRegionState.class will be considered as "missing source".
However, if look into the ClusterShardingQuery.scala,
final case class GetShardRegionState(...)
.
.
.
final case class GetClusterShardingStats(...)
GetClusterShardingStats.class and GetShardRegionState.class are inner class and should be treated as compiled from ClusterShardingQuery.scala
In Scala, a compiled
.classfile may not directly correspond to its source filename. For example,Hello.scalacan produce bothHello.classandWorld.class.Use case
Project: pekko-cluster-sharding-typed
source: https://repo1.maven.org/maven2/org/apache/pekko/pekko-cluster-sharding-typed_3/1.2.0/pekko-cluster-sharding-typed_3-1.2.0-sources.jar
binary: https://repo1.maven.org/maven2/org/apache/pekko/pekko-cluster-sharding-typed_3/1.2.0/pekko-cluster-sharding-typed_3-1.2.0.jar
With filename mapping:
source
binary
Only the
to/org/apache/pekko/cluster/sharding/typed/ClusterShardingQuery.classare considered mapped.GetClusterShardingStats.classandGetShardRegionState.classwill be considered as "missing source".However, if look into the
ClusterShardingQuery.scala,GetClusterShardingStats.classandGetShardRegionState.classare inner class and should be treated as compiled fromClusterShardingQuery.scala