Skip to content

Commit 2860fa6

Browse files
dloetzkeBuzzardo
authored andcommitted
Add link to and code of RestServiceApplication.java to the README
1 parent aead5a3 commit 2860fa6

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

README.adoc

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,20 @@ https://github.com/FasterXML/jackson[Jackson 2] is on the classpath, Spring's
152152
https://docs.spring.io/spring/docs/{spring_version}/javadoc-api/org/springframework/http/converter/json/MappingJackson2HttpMessageConverter.html[`MappingJackson2HttpMessageConverter`]
153153
is automatically chosen to convert the `Greeting` instance to JSON.
154154

155+
== Run the Service
156+
157+
The Spring Initializr creates an application class for you. In this case, you do not need
158+
to further modify the class. The following listing
159+
(from src/main/java/com/example/restservice/RestServiceApplication.java) shows the
160+
application class:
161+
162+
====
163+
[source,java]
164+
----
165+
include::complete/src/main/java/com/example/restservice/RestServiceApplication.java[]
166+
----
167+
====
168+
155169
include::https://raw.githubusercontent.com/spring-guides/getting-started-macros/main/spring-boot-application-new-path.adoc[]
156170

157171
include::https://raw.githubusercontent.com/spring-guides/getting-started-macros/main/build_an_executable_jar_subhead.adoc[]

0 commit comments

Comments
 (0)