Failure detection is essential in optical networks as a result of the huge amount of traffic that optical connections support. Additionally, the cause of failure needs to be identified so failed resources can be excluded from the computation of restoration paths. In the case of soft-failures, their prompt detection, identification, and localization make that recovery can be triggered before excessive errors in optical connections translate into errors on the supported services or even become disrupted. Therefore, Monitoring and Data Analytics (MDA) become of paramount importance in the case of soft-failures. In this paper, we review a MDA architecture that reduces remarkably detection and identification times, while facilitating failure localization. In addition, we rely on Optical Spectrum Analyzers (OSA) deployed in the optical nodes as monitoring devices acquiring the optical spectrum of outgoing links. Analyzing the optical spectrum of optical connections, specific soft-failures that affect the shape of the spectrum can be detected. A workflow consisting of machine learning algorithms, designed to be integrated in the aforementioned MDA architecture, will be studied to analyze the optical spectrum of a given optical connection acquired in a node and to determine whether a filter failure is affecting it, and in such case, what is the type of filter failure and its magnitude. Exhaustive results are presented allowing to evaluate the proposed method.