Query: When did construction of the fortress finish?
Context: An observation post at this location was first built by the Spanish in the late 18th century. In 1802, a beacon replaced the observation post; construction of the fortress began in 1809 and was completed in 1839. It has been involved in many historical developments and has been repeatedly taken over by various sides.