To be sure you should ask your DBA’s because they know best how your RAC is configured and how it behaves.
Usually the databases in a RAC behave like one, so every command is replicated to all nodes. Properly configured you should not even need to care which node you connect. Aplying a command to both sides is like doing the same command twice.
I used
jdbc:wm:oracle://server1:port1;ServiceName=XXXXX;AlternateServers=(server2:port2);AlternateServers=(server3:port3);AlternateServers=(server4:port4)