diff --git a/gradle.properties b/gradle.properties index 53d386c18ac488e951ce6d1a31cdb55af0e007c8..b2126d4fdfb2c6eab01804ab7f6fe4f817cfac24 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,4 @@ -awsVersion = 2.29.52 +awsSsmVersion = 2.29.52 githooksVersion = 1.2.0 gitVersionVersion = 0.15.0 grgitVersion = 4.1.1 diff --git a/gradle/dependencies.gradle b/gradle/dependencies.gradle index b02ef3ffe8b76497f7232949ac43093a552f21f2..b1a32d9ec88a43ac67e8ca337f0af7bc540c378d 100644 --- a/gradle/dependencies.gradle +++ b/gradle/dependencies.gradle @@ -12,7 +12,7 @@ dependencies { implementation "org.eclipse.jgit:org.eclipse.jgit:${jgitVersion}" // AWS - implementation "software.amazon.awssdk:ssm:${awsVersion}" + implementation "software.amazon.awssdk:ssm:${awsSsmVersion}" // Micronaut annotationProcessor("io.micronaut:micronaut-http-validation") diff --git a/src/main/java/gov/usgs/earthquake/nshmp/www/hazard/HazardService.java b/src/main/java/gov/usgs/earthquake/nshmp/www/hazard/HazardService.java index 1696f48757f557f979347a8bd51548e7c6d02d53..f36cd7984287d7e7af3f2e85abcf43728e7ba56b 100644 --- a/src/main/java/gov/usgs/earthquake/nshmp/www/hazard/HazardService.java +++ b/src/main/java/gov/usgs/earthquake/nshmp/www/hazard/HazardService.java @@ -64,16 +64,14 @@ public final class HazardService { public static HttpResponse<String> getMetadata(HttpRequest<?> request) { var url = request.getUri().getPath(); - var model = ServletUtil.model(); - + var usage = new Metadata(ServletUtil.model()); var body = ResponseBody.usage() .name(NAME) .url(url) .metadata(new ResponseMetadata(HazVersion.appVersions(ServletUtil.model().root()))) .request(url) - .response(new Metadata(model)) + .response(usage) .build(); - var json = ServletUtil.GSON2.toJson(body); return HttpResponse.ok(json); } @@ -138,16 +136,19 @@ public final class HazardService { Metadata(HazardModel model) { this.model = new SourceModel(model); + longitude = new DoubleParameter( "Longitude", "°", model.bounds().min.longitude, model.bounds().max.longitude); + latitude = new DoubleParameter( "Latitude", "°", model.bounds().min.latitude, model.bounds().max.latitude); + vs30 = new DoubleParameter( "Vs30", "m/s",