UPDATE 
  cscart_lock_keys 
SET 
  expiry_at = UNIX_TIMESTAMP(NOW()) + 30, 
  token = 'eev+xyoPLugPkCOBNYZ1RoafRt0H/82UQTGxmdD1R/Q=' 
WHERE 
  key_id = '2bbf6a9b4ef227490edae39a0997accb8d9f2e203a3b449caf0c0b5e5efe97fa' 
  AND (
    token = 'eev+xyoPLugPkCOBNYZ1RoafRt0H/82UQTGxmdD1R/Q=' 
    OR expiry_at <= UNIX_TIMESTAMP(NOW())
  )

Query time 0.00037