Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions 02.restful-web-services/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,13 @@
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
</dependency>


</dependencies>

<build>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import java.util.Locale;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.MessageSource;
import org.springframework.context.i18n.LocaleContextHolder;
Expand All @@ -11,6 +12,7 @@
import org.springframework.web.bind.annotation.RestController;

//Controller
@Slf4j
@RestController
public class HelloWorldController {

Expand All @@ -30,6 +32,7 @@ public HelloWorldBean helloWorldBean() {
///hello-world/path-variable/in28minutes
@GetMapping(path = "/hello-world/path-variable/{name}")
public HelloWorldBean helloWorldPathVariable(@PathVariable String name) {
log.info("Hello Word with PathVariable");
return new HelloWorldBean(String.format("Hello World, %s", name));
}

Expand Down