UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'IuiXoVn2QVLHGEBlHvx/w/aO1jBLYXrfrqwxKS5ReUI=' 
WHERE 
  key_id = '43e26963b5a20458f1bc57588d049037f7b11a79d8f03847862617779dbec24b' 
  AND (
    token = 'IuiXoVn2QVLHGEBlHvx/w/aO1jBLYXrfrqwxKS5ReUI=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00022