Repository: openshift/insights-runtime-extractor
Pull request #39: SB 3.4.3 test app and 3.1.4 app simplified
Author: login: liborfuka
Labels: name: lgtm
description: Indicates that a PR is ready to be merged.
name: approved
description: Indicates a PR has been approved by an approver from all required OWNERS files.
Created: 2025-03-13T08:34:09Z | Merged: 2025-03-18T09:24:56Z

I created SB 3.4.3 test app, add new extractor config for spring boot war packaging and simplified 3.1.4 test app.


Diff:
diff --git a/exporter/test/e2e/spring_boot_test.go b/exporter/test/e2e/spring_boot_test.go
index f203060a..dd59324c 100644
--- a/exporter/test/e2e/spring_boot_test.go
+++ b/exporter/test/e2e/spring_boot_test.go
@@ -8,7 +8,7 @@ import (
 	"sigs.k8s.io/e2e-framework/pkg/features"
 )
 
-func TestSpringBoot(t *testing.T) {
+func TestSpringBootJar_3_1_4(t *testing.T) {
 
 	appName := "spring-boot"
 	containerName := "main"
@@ -34,3 +34,30 @@ func TestSpringBoot(t *testing.T) {
 		}))
 	_ = testenv.Test(t, feature.Feature())
 }
+
+func TestSpringBootWar_3_4_3(t *testing.T) {
+
+	appName := "spring-boot"
+	containerName := "main"
+	image := "quay.io/insights-runtime-extractor-samples/spring-boot:3.4.3"
+	deployment := newAppDeployment(namespace, appName, 1, containerName, image)
+
+	feature := features.New("Spring Boot from "+image).
+		Setup(deployTestResource(deployment, appName)).
+		Teardown(undeployTestResource(deployment, appName)).
+		Assess("runtime info extracted", checkExtractedRuntimeInfo(namespace, "app="+appName, containerName, func(g *Ω.WithT, runtimeInfo types.ContainerRuntimeInfo) {
+			expected := types.ContainerRuntimeInfo{
+				Os:              "rhel",
+				OsVersion:       "8.10",
+				Kind:            "Java",
+				KindVersion:     "21.0.6",
+				KindImplementer: "Red Hat, Inc.",
+				Runtimes: []types.RuntimeComponent{{
+					Name:    "Spring Boot",
+					Version: "3.4.3",
+				}},
+			}
+			g.Expect(runtimeInfo).Should(Ω.Equal(expected))
+		}))
+	_ = testenv.Test(t, feature.Feature())
+}
diff --git a/extractor/config/config.toml b/extractor/config/config.toml
index d49dc8f9..c00b4eec 100644
--- a/extractor/config/config.toml
+++ b/extractor/config/config.toml
@@ -21,6 +21,12 @@ main-class = "org.springframework.boot.loader.JarLauncher"
 read-manifest-of-executable-jar = true
 jar-version-manifest-entry = "Spring-Boot-Version"
 
+[[fingerprints.java]]
+runtime-name = "Spring Boot"
+main-class = "org.springframework.boot.loader.launch.WarLauncher"
+read-manifest-of-executable-jar = true
+jar-version-manifest-entry = "Spring-Boot-Version"
+
 [[fingerprints.java]]
 runtime-name = "Apache Tomcat"
 main-class = "org.apache.catalina.startup.Bootstrap"
diff --git a/fingerprints/pkg/utils/config_test.go b/fingerprints/pkg/utils/config_test.go
index 24ed5643..303fb491 100644
--- a/fingerprints/pkg/utils/config_test.go
+++ b/fingerprints/pkg/utils/config_test.go
@@ -13,5 +13,5 @@ func TestReadConfig(t *testing.T) {
 	}
 
 	assert.Equal(t, 2, len(config.Fingerprints.VersionExecutables))
-	assert.Equal(t, 3, len(config.Fingerprints.Java))
+	assert.Equal(t, 4, len(config.Fingerprints.Java))
 }
diff --git a/runtime-samples/Makefile b/runtime-samples/Makefile
index 9a40fd28..d9c0c364 100644
--- a/runtime-samples/Makefile
+++ b/runtime-samples/Makefile
@@ -1,6 +1,6 @@
-.PHONY: golang-app quarkus-3.13.0 quarkus-3.15.1 spring-boot RHBQ plain-java
+.PHONY: golang-app quarkus-3.13.0 quarkus-3.15.1 spring-boot-3.1.4 spring-boot-3.4.3 RHBQ plain-java
 
-all: quarkus-3.13.0 quarkus-3.15.1 spring-boot golang-app RHBQ plain-java
+all: quarkus-3.13.0 quarkus-3.15.1 spring-boot-3.1.4 spring-boot-3.4.3 golang-app RHBQ plain-java
 
 golang-app:
 	cd ./golang-app && make
@@ -11,8 +11,11 @@ quarkus-3.13.0:
 quarkus-3.15.1:
 	cd ./quarkus/3.15.1 && make
 
-spring-boot:
-	cd ./spring-boot && make
+spring-boot-3.1.4:
+	cd ./spring-boot/3.1.4 && make
+
+spring-boot-3.4.3:
+	cd ./spring-boot/3.4.3 && make
 
 RHBQ:
 	cd ./RHBQ && make
diff --git a/runtime-samples/spring-boot/Containerfile b/runtime-samples/spring-boot/3.1.4/Containerfile
similarity index 51%
rename from runtime-samples/spring-boot/Containerfile
rename to runtime-samples/spring-boot/3.1.4/Containerfile
index 121745d7..95ce610e 100644
--- a/runtime-samples/spring-boot/Containerfile
+++ b/runtime-samples/spring-boot/3.1.4/Containerfile
@@ -1,6 +1,5 @@
 # corresponded to 17-jdk-focal
 FROM eclipse-temurin@sha256:d23172f5284c289d5250564ace7be94189c1003af45e6db7b3855d016b61c8a1
-ARG JAR_FILE=target/*.jar
-COPY ${JAR_FILE} app.jar
-ENTRYPOINT ["java","-jar","/app.jar"]
-WORKDIR /app
\ No newline at end of file
+WORKDIR /app
+COPY target/rest-service-complete-0.0.1-SNAPSHOT.jar app.jar
+ENTRYPOINT ["java","-jar","/app/app.jar"]
diff --git a/runtime-samples/spring-boot/Makefile b/runtime-samples/spring-boot/3.1.4/Makefile
similarity index 100%
rename from runtime-samples/spring-boot/Makefile
rename to runtime-samples/spring-boot/3.1.4/Makefile
diff --git a/runtime-samples/spring-boot/README.md b/runtime-samples/spring-boot/3.1.4/README.md
similarity index 100%
rename from runtime-samples/spring-boot/README.md
rename to runtime-samples/spring-boot/3.1.4/README.md
diff --git a/runtime-samples/spring-boot/deploy.sh b/runtime-samples/spring-boot/3.1.4/deploy.sh
similarity index 100%
rename from runtime-samples/spring-boot/deploy.sh
rename to runtime-samples/spring-boot/3.1.4/deploy.sh
diff --git a/runtime-samples/spring-boot/pom.xml b/runtime-samples/spring-boot/3.1.4/pom.xml
similarity index 100%
rename from runtime-samples/spring-boot/pom.xml
rename to runtime-samples/spring-boot/3.1.4/pom.xml
diff --git a/runtime-samples/spring-boot/src/main/java/com/example/demo/DemoApplication.java b/runtime-samples/spring-boot/3.1.4/src/main/java/com/example/demo/DemoApplication.java
similarity index 100%
rename from runtime-samples/spring-boot/src/main/java/com/example/demo/DemoApplication.java
rename to runtime-samples/spring-boot/3.1.4/src/main/java/com/example/demo/DemoApplication.java
diff --git a/runtime-samples/spring-boot/3.1.4/src/main/java/com/example/demo/web/SampleController.java b/runtime-samples/spring-boot/3.1.4/src/main/java/com/example/demo/web/SampleController.java
new file mode 100644
index 00000000..ace6dffc
--- /dev/null
+++ b/runtime-samples/spring-boot/3.1.4/src/main/java/com/example/demo/web/SampleController.java
@@ -0,0 +1,16 @@
+package com.example.demo;
+
+import org.springframework.stereotype.Controller;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.ResponseBody;
+
+@Controller
+public class SampleController {
+
+	@GetMapping("/ping")
+	@ResponseBody
+	public String ping() {
+		return "pong";
+	}
+
+}
diff --git a/runtime-samples/spring-boot/3.4.3/Containerfile b/runtime-samples/spring-boot/3.4.3/Containerfile
new file mode 100644
index 00000000..f07570a4
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/Containerfile
@@ -0,0 +1,6 @@
+# Red Hat OpenJDK 21
+FROM registry.access.redhat.com/ubi8/openjdk-21@sha256:7aaabadcb6bbcc3783d3f5d0685037797efbb7a590088dafab7927414fe93a37
+WORKDIR /app
+COPY target/tomcat-jsp-3.4.3.war sb-343.war
+ENTRYPOINT ["java","-jar","/app/sb-343.war"]
+
diff --git a/runtime-samples/spring-boot/3.4.3/Makefile b/runtime-samples/spring-boot/3.4.3/Makefile
new file mode 100644
index 00000000..9f985f09
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/Makefile
@@ -0,0 +1,7 @@
+.DEFAULT_GOAL = push
+
+build:
+	mvn install
+
+push: build
+	./deploy.sh
diff --git a/runtime-samples/spring-boot/3.4.3/README.md b/runtime-samples/spring-boot/3.4.3/README.md
new file mode 100644
index 00000000..aa83e8ec
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/README.md
@@ -0,0 +1,29 @@
+# spring-boot
+
+# Runtime sample for the insights-runtime-extractor
+
+To build the container image and make it available to the OpenShift internal image
+registry, run:
+
+```shell script
+make
+```
+
+# Workload Runtime Information:
+
+
+```json
+"runtimeInfo": {
+  "os": "ubuntu",
+  "osVersion": "20.04",
+  "kind": "Java",
+  "kindVersion": "17.0.12",
+  "kindImplementer": "Eclipse Adoptium",
+  "runtimes": [
+    {
+      "name": "Spring Boot",
+      "version": "3.4.3"
+    }
+  ]
+}
+```
\ No newline at end of file
diff --git a/runtime-samples/spring-boot/3.4.3/deploy.sh b/runtime-samples/spring-boot/3.4.3/deploy.sh
new file mode 100755
index 00000000..fbe693c3
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/deploy.sh
@@ -0,0 +1,7 @@
+#!/bin/bash
+
+IMAGE=quay.io/insights-runtime-extractor-samples/spring-boot:3.4.3
+
+echo "Building & pushing ${IMAGE}"
+podman build --platform linux/amd64 -t ${IMAGE} .
+podman push ${IMAGE}
\ No newline at end of file
diff --git a/runtime-samples/spring-boot/3.4.3/pom.xml b/runtime-samples/spring-boot/3.4.3/pom.xml
new file mode 100644
index 00000000..f33a793d
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/pom.xml
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.springframework.boot</groupId>
+    <artifactId>spring-boot-starter-parent</artifactId>
+    <version>3.4.3</version>
+    <relativePath/> <!-- lookup parent from repository -->
+  </parent>
+  <artifactId>tomcat-jsp</artifactId>
+  <packaging>war</packaging>
+  <name>Spring Boot Tomcat JSP Sample</name>
+  <description>Spring Boot Tomcat JSP Sample</description>
+  <url>http://projects.spring.io/spring-boot/</url>
+  <dependencies>
+    <dependency>
+      <groupId>org.springframework.boot</groupId>
+      <artifactId>spring-boot-starter-web</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.glassfish.web</groupId>
+      <artifactId>jakarta.servlet.jsp.jstl</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.tomcat.embed</groupId>
+      <artifactId>tomcat-embed-jasper</artifactId>
+    </dependency>
+  </dependencies>
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.springframework.boot</groupId>
+        <artifactId>spring-boot-maven-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>repackage</id>
+              <goals>
+                <goal>repackage</goal>
+              </goals>
+          </execution>
+        </executions>
+      </plugin>      
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-war-plugin</artifactId>
+        <version>3.4.0</version>
+        <configuration>
+          <failOnMissingWebXml>false</failOnMissingWebXml>
+          <archive>
+            <manifest>
+              <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
+            </manifest>
+          </archive>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+</project>
diff --git a/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/MyException.java b/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/MyException.java
new file mode 100644
index 00000000..fd4c88a3
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/MyException.java
@@ -0,0 +1,25 @@
+/*
+ * Copyright 2012-2015 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package sample.tomcat.jsp;
+
+public class MyException extends RuntimeException {
+
+	public MyException(String message) {
+		super(message);
+	}
+
+}
diff --git a/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/MyRestResponse.java b/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/MyRestResponse.java
new file mode 100644
index 00000000..72ea6479
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/MyRestResponse.java
@@ -0,0 +1,31 @@
+/*
+ * Copyright 2012-2015 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package sample.tomcat.jsp;
+
+public class MyRestResponse {
+
+	private String message;
+
+	public MyRestResponse(String message) {
+		this.message = message;
+	}
+
+	public String getMessage() {
+		return this.message;
+	}
+
+}
diff --git a/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/SampleTomcatJspApplication.java b/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/SampleTomcatJspApplication.java
new file mode 100644
index 00000000..8eaef4d6
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/SampleTomcatJspApplication.java
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2012-2016 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package sample.tomcat.jsp;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+import org.springframework.boot.builder.SpringApplicationBuilder;
+import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
+
+@SpringBootApplication
+public class SampleTomcatJspApplication extends SpringBootServletInitializer {
+
+	@Override
+	protected SpringApplicationBuilder configure(SpringApplicationBuilder application) {
+		return application.sources(SampleTomcatJspApplication.class);
+	}
+
+	public static void main(String[] args) throws Exception {
+		SpringApplication.run(SampleTomcatJspApplication.class, args);
+	}
+
+}
diff --git a/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/WelcomeController.java b/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/WelcomeController.java
new file mode 100644
index 00000000..8a56d9b4
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/src/main/java/sample/tomcat/jsp/WelcomeController.java
@@ -0,0 +1,60 @@
+/*
+ * Copyright 2012-2016 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package sample.tomcat.jsp;
+
+import java.util.Date;
+import java.util.Map;
+
+import org.springframework.beans.factory.annotation.Value;
+import org.springframework.http.HttpStatus;
+import org.springframework.stereotype.Controller;
+import org.springframework.web.bind.annotation.ExceptionHandler;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.ResponseBody;
+import org.springframework.web.bind.annotation.ResponseStatus;
+
+@Controller
+public class WelcomeController {
+
+	@Value("${application.message:Hello World}")
+	private String message = "Hello World";
+
+	@GetMapping("/")
+	public String welcome(Map<String, Object> model) {
+		model.put("time", new Date());
+		model.put("message", this.message);
+		return "welcome";
+	}
+
+	@RequestMapping("/fail")
+	public String fail() {
+		throw new MyException("Oh dear!");
+	}
+
+	@RequestMapping("/fail2")
+	public String fail2() {
+		throw new IllegalStateException();
+	}
+
+	@ExceptionHandler(MyException.class)
+	@ResponseStatus(HttpStatus.BAD_REQUEST)
+	public @ResponseBody MyRestResponse handleMyRuntimeException(MyException exception) {
+		return new MyRestResponse("Some data I want to send back to the client.");
+	}
+
+}
diff --git a/runtime-samples/spring-boot/3.4.3/src/main/resources/application.properties b/runtime-samples/spring-boot/3.4.3/src/main/resources/application.properties
new file mode 100644
index 00000000..2af7f6e2
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/src/main/resources/application.properties
@@ -0,0 +1,3 @@
+spring.mvc.view.prefix: /WEB-INF/jsp/
+spring.mvc.view.suffix: .jsp
+application.message: Hello Phil
\ No newline at end of file
diff --git a/runtime-samples/spring-boot/3.4.3/src/main/webapp/WEB-INF/jsp/welcome.jsp b/runtime-samples/spring-boot/3.4.3/src/main/webapp/WEB-INF/jsp/welcome.jsp
new file mode 100644
index 00000000..63ba9af1
--- /dev/null
+++ b/runtime-samples/spring-boot/3.4.3/src/main/webapp/WEB-INF/jsp/welcome.jsp
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+
+<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
+<%@ taglib prefix="c" uri="jakarta.tags.core"%>
+
+<html lang="en">
+
+<body>
+	<c:url value="/resources/text.txt" var="url"/>
+	<spring:url value="/resources/text.txt" htmlEscape="true" var="springUrl" />
+	Spring URL: ${springUrl} at ${time}
+	<br>
+	JSTL URL: ${url}
+	<br>
+	Message: ${message}
+</body>
+
+</html>
diff --git a/runtime-samples/spring-boot/HELP.md b/runtime-samples/spring-boot/HELP.md
deleted file mode 100644
index cafad1f5..00000000
--- a/runtime-samples/spring-boot/HELP.md
+++ /dev/null
@@ -1,9 +0,0 @@
-# Getting Started
-
-### Reference Documentation
-For further reference, please consider the following sections:
-
-* [Official Apache Maven documentation](https://maven.apache.org/guides/index.html)
-* [Spring Boot Maven Plugin Reference Guide](https://docs.spring.io/spring-boot/docs/3.1.4/maven-plugin/reference/html/)
-* [Create an OCI image](https://docs.spring.io/spring-boot/docs/3.1.4/maven-plugin/reference/html/#build-image)
-
diff --git a/runtime-samples/spring-boot/main/java/com/example/restservice/Greeting.java b/runtime-samples/spring-boot/main/java/com/example/restservice/Greeting.java
deleted file mode 100644
index 6b152c20..00000000
--- a/runtime-samples/spring-boot/main/java/com/example/restservice/Greeting.java
+++ /dev/null
@@ -1,3 +0,0 @@
-package com.example.restservice;
-
-public record Greeting(long id, String content) { }
diff --git a/runtime-samples/spring-boot/main/java/com/example/restservice/GreetingController.java b/runtime-samples/spring-boot/main/java/com/example/restservice/GreetingController.java
deleted file mode 100644
index 36e3aab1..00000000
--- a/runtime-samples/spring-boot/main/java/com/example/restservice/GreetingController.java
+++ /dev/null
@@ -1,19 +0,0 @@
-package com.example.restservice;
-
-import java.util.concurrent.atomic.AtomicLong;
-
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.RequestParam;
-import org.springframework.web.bind.annotation.RestController;
-
-@RestController
-public class GreetingController {
-
-	private static final String template = "Hello, %s!";
-	private final AtomicLong counter = new AtomicLong();
-
-	@GetMapping("/greeting")
-	public Greeting greeting(@RequestParam(value = "name", defaultValue = "World") String name) {
-		return new Greeting(counter.incrementAndGet(), String.format(template, name));
-	}
-}
diff --git a/runtime-samples/spring-boot/main/java/com/example/restservice/RestServiceApplication.java b/runtime-samples/spring-boot/main/java/com/example/restservice/RestServiceApplication.java
deleted file mode 100644
index caa988a6..00000000
--- a/runtime-samples/spring-boot/main/java/com/example/restservice/RestServiceApplication.java
+++ /dev/null
@@ -1,13 +0,0 @@
-package com.example.restservice;
-
-import org.springframework.boot.SpringApplication;
-import org.springframework.boot.autoconfigure.SpringBootApplication;
-
-@SpringBootApplication
-public class RestServiceApplication {
-
-	public static void main(String[] args) {
-		SpringApplication.run(RestServiceApplication.class, args);
-	}
-
-}
diff --git a/runtime-samples/spring-boot/src/main/resources/application.properties b/runtime-samples/spring-boot/src/main/resources/application.properties
deleted file mode 100644
index 8b137891..00000000
--- a/runtime-samples/spring-boot/src/main/resources/application.properties
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/runtime-samples/spring-boot/src/test/java/com/example/demo/DemoApplicationTests.java b/runtime-samples/spring-boot/src/test/java/com/example/demo/DemoApplicationTests.java
deleted file mode 100644
index 2778a6a7..00000000
--- a/runtime-samples/spring-boot/src/test/java/com/example/demo/DemoApplicationTests.java
+++ /dev/null
@@ -1,13 +0,0 @@
-package com.example.demo;
-
-import org.junit.jupiter.api.Test;
-import org.springframework.boot.test.context.SpringBootTest;
-
-@SpringBootTest
-class DemoApplicationTests {
-
-	@Test
-	void contextLoads() {
-	}
-
-}
diff --git a/runtime-samples/spring-boot/test/java/com/example/restservice/GreetingControllerTests.java b/runtime-samples/spring-boot/test/java/com/example/restservice/GreetingControllerTests.java
deleted file mode 100644
index 6ce07c2c..00000000
--- a/runtime-samples/spring-boot/test/java/com/example/restservice/GreetingControllerTests.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright 2016 the original author or authors.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *	  https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package com.example.restservice;
-
-import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
-import static org.springframework.test.web.servlet.result.MockMvcResultHandlers.print;
-import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.jsonPath;
-import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
-
-import org.junit.jupiter.api.Test;
-
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc;
-import org.springframework.boot.test.context.SpringBootTest;
-import org.springframework.test.web.servlet.MockMvc;
-
-@SpringBootTest
-@AutoConfigureMockMvc
-public class GreetingControllerTests {
-
-	@Autowired
-	private MockMvc mockMvc;
-
-	@Test
-	public void noParamGreetingShouldReturnDefaultMessage() throws Exception {
-
-		this.mockMvc.perform(get("/greeting")).andDo(print()).andExpect(status().isOk())
-				.andExpect(jsonPath("$.content").value("Hello, World!"));
-	}
-
-	@Test
-	public void paramGreetingShouldReturnTailoredMessage() throws Exception {
-
-		this.mockMvc.perform(get("/greeting").param("name", "Spring Community"))
-				.andDo(print()).andExpect(status().isOk())
-				.andExpect(jsonPath("$.content").value("Hello, Spring Community!"));
-	}
-
-}


Reviews:
user: login: jmesnil
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-03-13T12:01:49Z
user: login: liborfuka
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-03-13T12:03:12Z
user: login: jmesnil
state: APPROVED
author_association: CONTRIBUTOR
submitted_at: 2025-03-18T09:23:00Z

Review comments:
diff_hunk: @@ -21,6 +21,12 @@ main-class = "org.springframework.boot.loader.JarLauncher"
 read-manifest-of-executable-jar = true
 jar-version-manifest-entry = "Spring-Boot-Version"
 
+[[fingerprints.java]]
+runtime-name = "Spring Boot"
+main-class = "org.springframework.boot.loader.WarLauncher"
path: extractor/config/config.toml
user: login: jmesnil
body: this is not correct: it should be `org.springframework.boot.loader.launch.WarLauncher`
created_at: 2025-03-13T12:01:49Z
author_association: CONTRIBUTOR
diff_hunk: @@ -21,6 +21,12 @@ main-class = "org.springframework.boot.loader.JarLauncher"
 read-manifest-of-executable-jar = true
 jar-version-manifest-entry = "Spring-Boot-Version"
 
+[[fingerprints.java]]
+runtime-name = "Spring Boot"
+main-class = "org.springframework.boot.loader.WarLauncher"
path: extractor/config/config.toml
user: login: liborfuka
body: yes, You are right. I will update it.
created_at: 2025-03-13T12:03:12Z
author_association: CONTRIBUTOR

PR comments:
user: login: liborfuka
created_at: 2025-03-13T11:09:48Z
body: /retest
author_association: CONTRIBUTOR
user: login: liborfuka
created_at: 2025-03-13T13:48:40Z
body: /retest
author_association: CONTRIBUTOR
user: login: jmesnil
created_at: 2025-03-14T07:35:30Z
body: /retest

author_association: CONTRIBUTOR
user: login: liborfuka
created_at: 2025-03-14T12:08:01Z
body: /retest
author_association: CONTRIBUTOR
user: login: liborfuka
created_at: 2025-03-17T06:58:07Z
body: /retest
author_association: CONTRIBUTOR
user: login: liborfuka
created_at: 2025-03-17T09:01:45Z
body: /retest
author_association: CONTRIBUTOR
user: login: liborfuka
created_at: 2025-03-18T06:27:23Z
body: /test okd-scos-e2e-aws-ovn
author_association: CONTRIBUTOR
user: login: openshift-ci[bot]
created_at: 2025-03-18T08:28:27Z
body: @liborfuka: The following test **failed**, say `/retest` to rerun all failed tests or `/retest-required` to rerun all mandatory failed tests:

Test name | Commit | Details | Required | Rerun command
--- | --- | --- | --- | ---
ci/prow/okd-scos-e2e-aws-ovn | 841af593ae2707a357efd17f5a909054fdf12d8b | [link](https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_insights-runtime-extractor/39/pull-ci-openshift-insights-runtime-extractor-main-okd-scos-e2e-aws-ovn/1901883118231490560) | false | `/test okd-scos-e2e-aws-ovn`

[Full PR test history](https://prow.ci.openshift.org/pr-history?org=openshift&repo=insights-runtime-extractor&pr=39). [Your PR dashboard](https://prow.ci.openshift.org/pr?query=is:pr+state:open+author:liborfuka).

<details>

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md).  If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes-sigs/prow](https://github.com/kubernetes-sigs/prow/issues/new?title=Prow%20issue:) repository. I understand the commands that are listed [here](https://go.k8s.io/bot-commands).
</details>
<!-- test report -->
author_association: NONE
user: login: openshift-ci[bot]
created_at: 2025-03-18T09:24:15Z
body: [APPROVALNOTIFIER] This PR is **APPROVED**

This pull-request has been approved by: *<a href="https://github.com/openshift/insights-runtime-extractor/pull/39#pullrequestreview-2693633084" title="Approved">jmesnil</a>*, *<a href="https://github.com/openshift/insights-runtime-extractor/pull/39#" title="Author self-approved">liborfuka</a>*

The full list of commands accepted by this bot can be found [here](https://go.k8s.io/bot-commands?repo=openshift%2Finsights-runtime-extractor).

The pull request process is described [here](https://git.k8s.io/community/contributors/guide/owners.md#the-code-review-process)

<details >
Needs approval from an approver in each of these files:

- ~~[OWNERS](https://github.com/openshift/insights-runtime-extractor/blob/main/OWNERS)~~ [jmesnil]

Approvers can indicate their approval by writing `/approve` in a comment
Approvers can cancel approval by writing `/approve cancel` in a comment
</details>
<!-- META={"approvers":[]} -->
author_association: NONE
user: login: openshift-bot
created_at: 2025-03-18T12:46:09Z
body: **[ART PR BUILD NOTIFIER]**

Distgit: ose-insights-runtime-exporter
This PR has been included in build [ose-insights-runtime-exporter-container-v4.19.0-202503181210.p0.g05aff6a.assembly.stream.el9](https://brewweb.engineering.redhat.com/brew/buildinfo?buildID=3561719).
All builds following this will include this PR.
author_association: NONE
user: login: openshift-bot
created_at: 2025-03-18T12:49:14Z
body: **[ART PR BUILD NOTIFIER]**

Distgit: ose-insights-runtime-extractor
This PR has been included in build [ose-insights-runtime-extractor-container-v4.19.0-202503181210.p0.g05aff6a.assembly.stream.el9](https://brewweb.engineering.redhat.com/brew/buildinfo?buildID=3561711).
All builds following this will include this PR.
author_association: NONE