private Map < String , Map < String , Integer > > getLinkTargetShardNumbers ( DBObjectBatch dbObjBatch ) { Map < String , Map < String , Integer > > result = new HashMap <> ( ) ; Map < String , Set < String > > tableTargetObjIDMap = getAllLinkTargetObjIDs ( dbObjBatch ) ; for ( String targetTableName : tableTargetObjIDMap . keySet ( ) ) { Map < String , Integer > shardNoMap = getShardNumbers ( targetTableName , tableTargetObjIDMap . get ( targetTableName ) ) ; if ( shardNoMap . size ( ) > 0 ) { Map < String , Integer > tableShardNoMap = result . get ( targetTableName ) ; if ( tableShardNoMap == null ) { tableShardNoMap = new HashMap <> ( ) ; result . put ( targetTableName , tableShardNoMap ) ; } tableShardNoMap . putAll ( shardNoMap ) ; } } return result ; }
objects that have no sharding - field value .