UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'eaVFT2R2kLFYq32twOgRslrkYvZTvJmAXIQ8ZjYgMy0=' 
WHERE 
  key_id = '6d6273366f90929541589f1f496189dc07981cd9ac4553fbe72681300dd2ceb0' 
  AND (
    token = 'eaVFT2R2kLFYq32twOgRslrkYvZTvJmAXIQ8ZjYgMy0=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00028