No, it is not mandatory. However, it is recommended in order to avoid long queues and to better organize your visit.