public void addSnapshot( LogChannelInterface logChannel, MetricsSnapshotInterface snapshot ) { MetricsInterface metric = snapshot.getMetric(); String channelId = logChannel.getLogChannelId(); switch ( metric.getType() ) { case START: case STOP: Queue<MetricsSnapshotInterface> list = getSnapshotList( channelId ); list.add( snapshot ); break; case MIN: case MAX: case SUM: case COUNT: Map<String, MetricsSnapshotInterface> map = getSnapshotMap( channelId ); map.put( snapshot.getKey(), snapshot ); break; default: break; } }
metricsMap = metricsRegistry.getSnapshotMap( logChannelId ); snapshot = metricsMap.get( key ); if ( snapshot != null ) { metricsMap = metricsRegistry.getSnapshotMap( logChannelId ); snapshot = metricsMap.get( key ); if ( snapshot != null ) { metricsMap = metricsRegistry.getSnapshotMap( logChannelId ); snapshot = metricsMap.get( key ); if ( snapshot != null ) { metricsMap = metricsRegistry.getSnapshotMap( logChannelId ); snapshot = metricsMap.get( key ); if ( snapshot != null ) {