[Trunk | Orcid Service]:
1. pom.xml: Updated version of "uoa-authorization-library" from 1.0.0 to 2.0.1. 2. GlobalVars.java: Added field "version" (version of project in pom). 3. OrcidServiceCheckDeployController.java: Expose globalBars.version in /health_check/advanced. 4. orcidservice.properties: Added orcidservice.globalVars.version=@version@ (initialized by pom version).
This commit is contained in:
parent
b1dadbb11d
commit
dad296a633
2
pom.xml
2
pom.xml
|
@ -101,7 +101,7 @@
|
|||
<dependency>
|
||||
<groupId>eu.dnetlib</groupId>
|
||||
<artifactId>uoa-authorization-library</artifactId>
|
||||
<version>1.0.0</version>
|
||||
<version>2.0.1</version>
|
||||
</dependency>
|
||||
|
||||
<!-- <dependency>-->
|
||||
|
|
|
@ -8,6 +8,7 @@ import java.util.Date;
|
|||
public class GlobalVars {
|
||||
public static Date date = new Date();
|
||||
private Date buildDate;
|
||||
private String version;
|
||||
|
||||
public String getBuildDate() {
|
||||
if(buildDate == null) {
|
||||
|
@ -19,4 +20,12 @@ public class GlobalVars {
|
|||
public void setBuildDate(Date buildDate) {
|
||||
this.buildDate = buildDate;
|
||||
}
|
||||
|
||||
public String getVersion() {
|
||||
return version;
|
||||
}
|
||||
|
||||
public void setVersion(String version) {
|
||||
this.version = version;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -102,6 +102,9 @@ public class OrcidServiceCheckDeployController {
|
|||
if(globalVars.getBuildDate() != null) {
|
||||
response.put("Date of build", globalVars.getBuildDate());
|
||||
}
|
||||
if(globalVars.getVersion() != null) {
|
||||
response.put("Version", globalVars.getVersion());
|
||||
}
|
||||
return response;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,6 +8,7 @@ orcidservice.orcid.tokenURL=https://sandbox.orcid.org/oauth/token
|
|||
orcidservice.orcid.clientId=APP-A5M3KTX6NCN67L91
|
||||
orcidservice.orcid.clientSecret=96b20d71-ae06-4286-bb00-9172536c1ad4
|
||||
orcidservice.globalVars.buildDate=@timestamp@
|
||||
orcidservice.globalVars.version=@version@
|
||||
|
||||
#orcidservice.encryption.password=...
|
||||
|
||||
|
|
Loading…
Reference in New Issue