NationalPlayer { public BigInteger getId() { return id; }  BigInteger getId(); String getFirstName(); String getLastName(); Country getCountry(); int getCareerGoals(); int getWorldRanking(); NationalPlayer withCountry(Country country); NationalPlayer withCareerGoals(int careerGoals); NationalPlayer withWorldRanking(int worldRanking); NationalPlayer withFirstName(String firstName); NationalPlayer withLastName(String lastName); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj);  }
@Test public void testShardingPersistence() { BigInteger indiaPlayerId = null; BigInteger usaPlayerId = null; BigInteger italyPlayerId = null; savePlayer(indiaPlayer); savePlayer(usaPlayer); savePlayer(italyPlayer); indiaPlayerId = indiaPlayer.getId(); System.out.println("Indian Player Id:" + indiaPlayerId); usaPlayerId = usaPlayer.getId(); System.out.println("Usa Player Id:" + usaPlayerId); italyPlayerId = italyPlayer.getId(); System.out.println("Italy Player Id:" + italyPlayerId); assertNotNull("Indian Player must have been persisted", getShardPlayer(indiaPlayerId)); assertNotNull("Usa Player must have been persisted", getShardPlayer(usaPlayerId)); assertNotNull("Italy Player must have been persisted", getShardPlayer(italyPlayerId)); assertExistsOnlyOnShard("Indian Player should have existed on only shard 0", 0, indiaPlayerId); assertExistsOnlyOnShard("Usa Player should have existed only on shard 1", 1, usaPlayerId); assertExistsOnlyOnShard("Italian Player should have existed only on shard 2", 2, italyPlayerId); }