UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = '/hhOH4NTtJu8sRpWUtE5n6XDf4/CZjJahRPJv5bI75c=' 
WHERE 
  key_id = 'c60b5d2781f85a4e634a8fa493a134e7f69aeacdf33ba9a86435f8da64bfd545' 
  AND (
    token = '/hhOH4NTtJu8sRpWUtE5n6XDf4/CZjJahRPJv5bI75c=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00058