UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'xx7yIsrlOqarLfLW5BEvg6CUw/hYOW6ZtB39SVDKiic=' 
WHERE 
  key_id = '03b93d1ea5efdaf42ced2656978bce4c5b067b86b2a0f7da13f5e089543c2455' 
  AND (
    token = 'xx7yIsrlOqarLfLW5BEvg6CUw/hYOW6ZtB39SVDKiic=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00035