解决方法:
1)使用
mvn war:manifest
2)在webapp文件夹中创建meta-INF MANIFEST.MF
version = getClass().getPackage().getImplementationVersion(); if (version==null) { Properties prop = new Properties(); try { prop.load(getServletContext().getResourceAsStream("/meta-INF/MANIFEST.MF")); version = prop.getProperty("Implementation-Version"); } catch (IOException e) { logger.error(e.toString()); }}logger.info("Starting App version "+version);
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)