class ClusterNodeMetrics implements Serializable {
    /** */
    private static final long serialVersionUID = 0L;

    /** */
    private final byte[] metrics;

    /** */
    private final Map<Integer, CacheMetrics> cacheMetrics;

    /**
     * @param metrics Metrics.
     * @param cacheMetrics Cache metrics.
     */
    ClusterNodeMetrics(ClusterMetrics metrics, Map<Integer, CacheMetrics> cacheMetrics) {
        this.metrics = ClusterMetricsSnapshot.serialize(metrics);
        this.cacheMetrics = cacheMetrics;
    }

    /**
     * @return Metrics.
     */
    byte[] metrics() {
        return metrics;
    }

    /**
     * @return Cache metrics.
     */
    Map<Integer, CacheMetrics> cacheMetrics() {<FILL_FUNCTION_BODY>}
}

        return cacheMetrics != null ? cacheMetrics : Collections.<Integer, CacheMetrics>emptyMap();
    
<no_super_class>