Advanced monitoring systems for primary and secondary drying phases of a freeze-drying process