public static synchronized void updateTokens ( Collection < Token > tokens ) { assert ! tokens . isEmpty ( ) : "removeEndpoint should be used instead" ; String req = "INSERT INTO system.%s (key, tokens) VALUES ('%s', ?)" ; executeInternal ( String . format ( req , LOCAL_CF , LOCAL_KEY ) , tokensAsSet ( tokens ) ) ; forceBlockingFlush ( LOCAL_CF ) ; }
This method is used to update the System Keyspace with the new tokens for this node