If you attack a player and lose, that player's island stays on your map. This way the game makes it possible for you to attack the same player as much and as often as you want until one of the attacks is successful.
On the other hand, sometimes you will notice in your attack history that the same player has successfully attacked you several times in a row. This is also possible, although it is quite rare. It happens when, for whatever reason, you end up on several of a player's islands at the same time or over a short period of time. This kind of situation sometimes arises because the matchmaking system searches for opponents randomly and does not filter out "repeats."