public class SliderVersionInfo extends Object
application.name=${pom.name}
application.version=${pom.version}
application.build=${buildNumber}
application.build.java.version=${java.version}
application.build.info=${pom.name}-${pom.version} Built against ${buildNumber} on ${java.version} by ${user.name}
the mvn process-resources target will expand the properties
and add the resources to target/classes, which will then look something like
application.name=Slider Core application.version=0.7.1-SNAPSHOT application.build=1dd69 application.build.java.version=1.7.0_45 application.build.user=stevel application.build.info=Slider Core-0.7.1-SNAPSHOT Built against 1dd69 on 1.7.0_45 by stevelNote: the values will change and more properties added.
| Modifier and Type | Field and Description |
|---|---|
static String |
APP_BUILD |
static String |
APP_BUILD_INFO |
static String |
APP_BUILD_JAVA_VERSION |
static String |
APP_BUILD_USER |
static String |
APP_NAME |
static String |
APP_VERSION |
static String |
HADOOP_BUILD_INFO |
static String |
HADOOP_DEPLOYED_INFO |
static String |
VERSION_RESOURCE
Name of the resource containing the filled-in-at-runtime props
|
| Constructor and Description |
|---|
SliderVersionInfo() |
| Modifier and Type | Method and Description |
|---|---|
static String |
getHadoopVersionString() |
static void |
loadAndPrintVersionInfo(org.slf4j.Logger logger)
Load the version info and print it
|
static Properties |
loadVersionProperties() |
public static final String VERSION_RESOURCE
public static final String APP_NAME
public static final String APP_VERSION
public static final String APP_BUILD
public static final String APP_BUILD_JAVA_VERSION
public static final String APP_BUILD_USER
public static final String APP_BUILD_INFO
public static final String HADOOP_BUILD_INFO
public static final String HADOOP_DEPLOYED_INFO
public static Properties loadVersionProperties()
public static void loadAndPrintVersionInfo(org.slf4j.Logger logger)
logger - loggerpublic static String getHadoopVersionString()
Copyright © 2014–2015 The Apache Software Foundation. All rights reserved.