use of org.talend.dataprep.info.BuildDetails in project data-prep by Talend.
the class VersionServiceAPI method allVersions.
/**
* Returns all the versions of the different services (api, dataset, preparation and transformation) and the global
* application version.
*
* @return an array of service versions
*/
@RequestMapping(value = "/api/version", method = GET)
@ApiOperation(value = "Get the version of all services (including underlying low level services)", produces = MediaType.APPLICATION_JSON_VALUE)
@Timed
@PublicAPI
public BuildDetails allVersions() {
List<Version> versions = new ArrayList<>();
for (VersionsSupplier versionsSupplier : versionsSuppliers) {
versions.addAll(versionsSupplier.getVersions());
}
CollectionUtils.filter(versions, PredicateUtils.notNullPredicate());
return new BuildDetails(applicationVersion, versions.toArray(new Version[versions.size()]));
}
Aggregations