UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'OAJM2PAnUz9qKCQ1Xk/juPZv+iuxFigQsrefawI0BCA=' 
WHERE 
  key_id = '11409f380342d657192670c972bea0e0771fcae03d52b6840dacdf5f42a6e118' 
  AND (
    token = 'OAJM2PAnUz9qKCQ1Xk/juPZv+iuxFigQsrefawI0BCA=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00029