All Downloads are FREE. Search and download functionalities are using the official Maven repository.

cf.dropsonde.metron.Time Maven / Gradle / Ivy

Go to download

Java support for Cloud Foundry's Loggregator using the Dropsonde protocol.

There is a newer version: 0.5
Show newest version
package cf.dropsonde.metron;

import java.time.Instant;

/**
 * @author Mike Heath
 */
class Time {
	static long timestamp() {
		return timestamp(Instant.now());
	}

	static long timestamp(Instant timestamp) {
		return timestamp.getEpochSecond() * 1_000_000_000 + timestamp.getNano();
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy