Abstract
Anomaly detection is crucial for ensuring the stability and reliability of web service systems. Logs and metrics contain multiple information that can reflect the system's operational state and potential anomalies. Thus, existing anomaly detection methods use logs and metrics to detect web service systems' anomalies through data fusion approaches. They associate logs and metrics using coarse-grained time window alignment and capture the normal patterns of system operation through reconstruction. However, these methods have two issues that limit their performance in anomaly detection. First, due to asynchrony between logs and metrics, coarse-grained time window alignment cannot achieve a precise association between the two modalities. Second, reconstruction-based methods suffer from severe overgeneralization problems, resulting in anomalies being accurately reconstructed. In this paper, we propose a novel anomaly detection method named FFAD to address these two issues. On the one hand, FFAD employs graph-based alignment to mine and extract associations between the modalities from the constructed log-metric relation graph, achieving precise associations between logs and metrics. On the other hand, we improve the model's fit to normal data distributions through Fourier Frequency Focus, thereby enhancing the effectiveness of anomaly detection. We validated the effectiveness of our model on two real-world industrial datasets and one open-source dataset. The results show that our method achieves an average anomaly detection F1-score of 93.6%, representing an 8.8% improvement over previous state-of-the-art methods.
Introduction
Modern web services are complex, generating two main types of data: metrics (continuous performance data like CPU usage) and logs (discrete event records). To catch system failures, engineers usually combine both. However, existing "multi-modal" detection methods face two major hurdles:
- The Asynchrony Gap: Logs and metrics are often out of sync due to network delays or processing lags. Standard methods group them into "time windows," but this is often too coarse to capture the exact relationship between a specific log event and a corresponding metric spike.
- The Overgeneralization Trap: Most detection models work by learning to "reconstruct" normal system behavior. If the model is too powerful, it accidentally learns how to reconstruct anomalies as well. When the "reconstruction error" is low for both normal and abnormal data, the anomalies become invisible.
The FFAD Framework
To address these challenges, we propose FFAD (Fine-grained multi-modal Association and Frequency Domain Analysis). The architecture is designed to bridge the asynchrony gap and prevent overgeneralization through several novel components.
Key Components
- Temporal Feature Retention (TFR): The system uses 1D convolutions to ensure the chronological order of the data is preserved before fusion.
- Dual Noise Injection (DNI): To prevent the model from over-relying on a single data-rich modality, FFAD injects Gaussian noise into metrics and Poisson noise into logs. This balances the learning difficulty between the two sources.
- Fully-Connected Fusion Graph: Instead of simple time-binning, FFAD treats every data point as a node in a graph. This allows the model to discover fine-grained associations between logs and metrics regardless of slight timing offsets.
- Fourier Frequency Focus (FFF): This is the core innovation for the overgeneralization problem. Anomalies typically appear as high-energy signals in the frequency domain. FFF dynamically scales down these high-energy components during training, forcing the model to focus on low-energy "normal" patterns. Consequently, when an anomaly occurs, the reconstruction error is significantly higher and easier to detect.
Experimental Evaluation
We evaluated FFAD on three distinct datasets: a public in-lab dataset (Dataset A), a simulated complex dataset (Dataset B), and a massive real-world industrial dataset from Alibaba (Dataset C).
Key Results
- Superior Accuracy: FFAD achieved an average F1-score of 93.6%, outperforming previous state-of-the-art models by 8.8%.
- Perfect Recall: On the industrial and simulated datasets (B and C), the model achieved a 100% recall rate. In production environments, missing a "system down" event is far more costly than a few false alarms.
- Real-World Deployment: The system has been successfully deployed in Alibaba’s production environment (serving Taobao) since September 2023.
Conclusion
FFAD demonstrates that treating multi-modal data as a fully connected graph effectively bypasses the asynchrony problem inherent in web service logs and metrics. Furthermore, by intentionally suppressing high-energy signals during training via Fourier Frequency Focus, we can mitigate the overgeneralization trap common in reconstruction-based models. While the system currently relies on external log parsers like "Drain," its performance gains and real-world deployment highlight its potential as a robust solution for industrial-scale anomaly detection.
Summary updated