[BAEL-18367] Moving articles from rest-spring-** pt 4

This commit is contained in:
Sjmillington 2019-12-08 10:42:40 +00:00
parent 8de37745a1
commit 05c5002b73
35 changed files with 190 additions and 562 deletions

View File

@ -805,7 +805,7 @@
<module>spring-reactive-kotlin</module>
<module>spring-reactor</module>
<module>spring-remoting</module>
<module>spring-rest</module>
<module>spring-rest-http</module>
<module>spring-rest-angular</module>
<module>spring-rest-compress</module>
<module>spring-rest-testing</module>
@ -1411,7 +1411,7 @@
<module>spring-reactive-kotlin</module>
<module>spring-reactor</module>
<module>spring-remoting</module>
<module>spring-rest</module>
<module>spring-rest-http</module>
<module>spring-rest-angular</module>
<module>spring-rest-compress</module>
<module>spring-rest-testing</module>

View File

@ -0,0 +1,14 @@
## Spring REST HTTP
This module contains articles about HTTP in REST APIs with Spring
### The Course
The "REST With Spring" Classes: http://bit.ly/restwithspring
### Relevant Articles:
- [Guide to UriComponentsBuilder in Spring](https://www.baeldung.com/spring-uricomponentsbuilder)
- [How to Set a Header on a Response with Spring 5](https://www.baeldung.com/spring-response-header) - The tests contained for this article rely on the sample application within the [spring-resttemplate](/spring-resttemplate) module
- [Returning Custom Status Codes from Spring Controllers](https://www.baeldung.com/spring-mvc-controller-custom-http-status-code)
- [Spring @RequestMapping](https://www.baeldung.com/spring-requestmapping)
- [Guide to DeferredResult in Spring](https://www.baeldung.com/spring-deferred-result)

52
spring-rest-http/pom.xml Normal file
View File

@ -0,0 +1,52 @@
<?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>
<artifactId>spring-rest-http</artifactId>
<version>0.1-SNAPSHOT</version>
<name>spring-rest-http</name>
<packaging>war</packaging>
<parent>
<groupId>com.baeldung</groupId>
<artifactId>parent-boot-2</artifactId>
<version>0.0.1-SNAPSHOT</version>
<relativePath>../parent-boot-2</relativePath>
</parent>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-oxm</artifactId>
</dependency>
<dependency>
<groupId>com.thoughtworks.xstream</groupId>
<artifactId>xstream</artifactId>
<version>${xstream.version}</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
</dependency>
</dependencies>
<properties>
<xstream.version>1.4.9</xstream.version>
</properties>
</project>

View File

@ -0,0 +1,51 @@
package com.baeldung.config;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.http.MediaType;
import org.springframework.http.converter.HttpMessageConverter;
import org.springframework.http.converter.json.Jackson2ObjectMapperBuilder;
import org.springframework.oxm.xstream.XStreamMarshaller;
import org.springframework.web.servlet.config.annotation.ContentNegotiationConfigurer;
import org.springframework.web.servlet.config.annotation.CorsRegistry;
import org.springframework.web.servlet.config.annotation.EnableWebMvc;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
import java.text.SimpleDateFormat;
import java.util.List;
/*
* Please note that main web configuration is in src/main/webapp/WEB-INF/api-servlet.xml
*/
@Configuration
@EnableWebMvc
@ComponentScan({ "com.baeldung.web", "com.baeldung.requestmapping" })
public class MvcConfig implements WebMvcConfigurer {
public MvcConfig() {
super();
}
//
@Override
public void configureMessageConverters(final List<HttpMessageConverter<?>> messageConverters) {
final Jackson2ObjectMapperBuilder builder = new Jackson2ObjectMapperBuilder();
builder.indentOutput(true)
.dateFormat(new SimpleDateFormat("dd-MM-yyyy hh:mm"));
}
@Override
public void configureContentNegotiation(ContentNegotiationConfigurer configurer) {
configurer.defaultContentType(MediaType.APPLICATION_JSON);
}
@Override
public void addCorsMappings(CorsRegistry registry) {
registry.addMapping("/**");
}
}

View File

@ -0,0 +1,22 @@
package com.baeldung.web.dto;
public class Bazz {
public String id;
public String name;
public Bazz(String id){
this.id = id;
}
public Bazz(String id, String name) {
this.id = id;
this.name = name;
}
@Override
public String toString() {
return "Bazz [id=" + id + ", name=" + name + "]";
}
}

View File

@ -0,0 +1,45 @@
package com.baeldung.web.dto;
import com.thoughtworks.xstream.annotations.XStreamAlias;
@XStreamAlias("Foo")
public class Foo {
private long id;
private String name;
public Foo() {
super();
}
public Foo(final String name) {
super();
this.name = name;
}
public Foo(final long id, final String name) {
super();
this.id = id;
this.name = name;
}
// API
public long getId() {
return id;
}
public void setId(final long id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(final String name) {
this.name = name;
}
}

View File

@ -4,12 +4,10 @@ This module contains articles about REST APIs in Spring
## Relevant articles:
- [Guide to UriComponentsBuilder in Spring](https://www.baeldung.com/spring-uricomponentsbuilder)
- [Returning Custom Status Codes from Spring Controllers](https://www.baeldung.com/spring-mvc-controller-custom-http-status-code)
- [Spring RequestMapping](https://www.baeldung.com/spring-requestmapping)
- [Spring and Apache FileUpload](https://www.baeldung.com/spring-apache-file-upload)
- [Test a REST API with curl](https://www.baeldung.com/curl-rest)
- [Best Practices for REST API Error Handling](https://www.baeldung.com/rest-api-error-handling-best-practices)
- [Binary Data Formats in a Spring REST API](https://www.baeldung.com/spring-rest-api-with-binary-data-formats)
### NOTE:

View File

@ -1,13 +0,0 @@
*.class
#folders#
/target
/neoDb*
/data
/spring-boot-runtime/src/main/webapp/WEB-INF/classes
*/META-INF/*
# Packaged files #
*.jar
*.war
*.ear

View File

@ -1,17 +0,0 @@
## Spring REST
This module contains articles about REST APIs with Spring
### The Course
The "REST With Spring" Classes: http://bit.ly/restwithspring
### Relevant Articles:
- [Spring @RequestMapping](https://www.baeldung.com/spring-requestmapping)
- [Returning Custom Status Codes from Spring Controllers](https://www.baeldung.com/spring-mvc-controller-custom-http-status-code)
- [Binary Data Formats in a Spring REST API](https://www.baeldung.com/spring-rest-api-with-binary-data-formats)
- [Guide to UriComponentsBuilder in Spring](https://www.baeldung.com/spring-uricomponentsbuilder)
- [A Custom Media Type for a Spring REST API](https://www.baeldung.com/spring-rest-custom-media-type)
- [HTTP PUT vs HTTP PATCH in a REST API](https://www.baeldung.com/http-put-patch-difference-spring)
- [Guide to DeferredResult in Spring](https://www.baeldung.com/spring-deferred-result)
- [How to Set a Header on a Response with Spring 5](https://www.baeldung.com/spring-response-header)
- [Download an Image or a File with Spring MVC](https://www.baeldung.com/spring-controller-return-image-file)

View File

@ -1,254 +0,0 @@
<?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>
<artifactId>spring-rest</artifactId>
<version>0.1-SNAPSHOT</version>
<name>spring-rest</name>
<packaging>war</packaging>
<parent>
<groupId>com.baeldung</groupId>
<artifactId>parent-boot-2</artifactId>
<version>0.0.1-SNAPSHOT</version>
<relativePath>../parent-boot-2</relativePath>
</parent>
<dependencies>
<!-- Spring Boot Dependencies -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
</dependency>
<!-- Spring -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
<exclusions>
<exclusion>
<artifactId>commons-logging</artifactId>
<groupId>commons-logging</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
</dependency>
<dependency>
<groupId>commons-fileupload</groupId>
<artifactId>commons-fileupload</artifactId>
<version>${commons-fileupload.version}</version>
</dependency>
<!-- web -->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>jstl</artifactId>
<scope>runtime</scope>
</dependency>
<!-- marshalling -->
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.dataformat</groupId>
<artifactId>jackson-dataformat-xml</artifactId>
</dependency>
<!-- util -->
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>${guava.version}</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
</dependency>
<!-- test scoped -->
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-library</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId>
</dependency>
<!-- -->
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>${protobuf-java.version}</version>
</dependency>
<dependency>
<groupId>com.googlecode.protobuf-java-format</groupId>
<artifactId>protobuf-java-format</artifactId>
<version>${protobuf-java-format.version}</version>
</dependency>
<dependency>
<groupId>com.esotericsoftware</groupId>
<artifactId>kryo</artifactId>
<version>${kryo.version}</version>
</dependency>
<dependency>
<groupId>com.jayway.jsonpath</groupId>
<artifactId>json-path</artifactId>
</dependency>
<!-- Apache common IO for utility -->
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>${commons-io.version}</version>
</dependency>
<dependency>
<groupId>io.rest-assured</groupId>
<artifactId>rest-assured</artifactId>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>${httpclient.version}</version>
</dependency>
</dependencies>
<build>
<finalName>spring-rest</finalName>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
</resources>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>live</id>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven2-plugin</artifactId>
<executions>
<execution>
<id>start-server</id>
<phase>pre-integration-test</phase>
<goals>
<goal>start</goal>
</goals>
</execution>
<execution>
<id>stop-server</id>
<phase>post-integration-test</phase>
<goals>
<goal>stop</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<executions>
<execution>
<phase>integration-test</phase>
<goals>
<goal>test</goal>
</goals>
<configuration>
<excludes>
<exclude>none</exclude>
</excludes>
<includes>
<include>**/*LiveTest.java</include>
</includes>
<systemPropertyVariables>
<webTarget>cargo</webTarget>
</systemPropertyVariables>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<properties>
<commons-fileupload.version>1.3.2</commons-fileupload.version>
<kryo.version>4.0.0</kryo.version>
<protobuf-java-format.version>1.4</protobuf-java-format.version>
<protobuf-java.version>3.1.0</protobuf-java.version>
<!-- util -->
<guava.version>20.0</guava.version>
<!-- Maven plugins -->
<cargo-maven2-plugin.version>1.6.0</cargo-maven2-plugin.version>
<findbugs-maven-plugin.version>3.0.4</findbugs-maven-plugin.version>
<dependency.locations.enabled>false</dependency.locations.enabled>
<json.path.version>2.2.0</json.path.version>
<pact.version>3.5.11</pact.version>
<rest-assured.version>3.1.0</rest-assured.version>
<httpclient.version>4.5.2</httpclient.version>
<start-class>com.baeldung.sampleapp.config.MainApplication</start-class>
</properties>
</project>

View File

@ -1,14 +0,0 @@
package com.baeldung.controllers;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
@Controller
public class ViewController {
@GetMapping("/")
public String welcome() {
return "index";
}
}

View File

@ -1,2 +0,0 @@
server.port= 8082
server.servlet.context-path=/spring-rest

View File

@ -1 +0,0 @@
This is a sample file containing text data

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

View File

@ -1,23 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n
</pattern>
</encoder>
</appender>
<logger name="org.springframework.web.filter.CommonsRequestLoggingFilter">
<level value="DEBUG" />
</logger>
<logger name="org.springframework" level="WARN" />
<logger name="org.springframework.transaction" level="WARN" />
<!-- in order to debug some marshalling issues, this needs to be TRACE -->
<logger name="org.springframework.web.servlet.mvc" level="WARN" />
<root level="INFO">
<appender-ref ref="STDOUT" />
</root>
</configuration>

View File

@ -1,61 +0,0 @@
{
"provider": {
"name": "test_provider"
},
"consumer": {
"name": "test_consumer"
},
"interactions": [
{
"description": "GET REQUEST",
"request": {
"method": "GET",
"path": "/pact"
},
"response": {
"status": 200,
"headers": {
"Content-Type": "application/json"
},
"body": {
"condition": true,
"name": "tom"
}
},
"providerStates": [
{
"name": "test GET"
}
]
},
{
"description": "POST REQUEST",
"request": {
"method": "POST",
"path": "/pact",
"headers": {
"Content-Type": "application/json"
},
"body": {
"name": "Michael"
}
},
"response": {
"status": 201
},
"providerStates": [
{
"name": "test POST"
}
]
}
],
"metadata": {
"pact-specification": {
"version": "3.0.0"
},
"pact-jvm": {
"version": "3.5.0"
}
}
}

View File

@ -1,13 +0,0 @@
*.class
#folders#
/target
/neoDb*
/data
/src/main/webapp/WEB-INF/classes
*/META-INF/*
# Packaged files #
*.jar
*.war
*.ear

View File

@ -1,24 +0,0 @@
https://publicobject.com/helloworld.txt
GET
0
HTTP/1.1 200 OK
10
Content-Type: text/plain
Content-Length: 1759
Connection: keep-alive
Accept-Ranges: bytes
Server: nginx/1.10.0 (Ubuntu)
Date: Sat, 08 Dec 2018 13:02:07 GMT
Last-Modified: Tue, 27 May 2014 02:35:47 GMT
ETag: "5383fa03-6df"
OkHttp-Sent-Millis: 1489054646765
OkHttp-Received-Millis: 1489054646966
TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
4
MIIFVTCCBD2gAwIBAgIRAKgHBM+t9Yx3v9G9tGZECWkwDQYJKoZIhvcNAQELBQAwgZAxCzAJBgNVBAYTAkdCMRswGQYDVQQIExJHcmVhdGVyIE1hbmNoZXN0ZXIxEDAOBgNVBAcTB1NhbGZvcmQxGjAYBgNVBAoTEUNPTU9ETyBDQSBMaW1pdGVkMTYwNAYDVQQDEy1DT01PRE8gUlNBIERvbWFpbiBWYWxpZGF0aW9uIFNlY3VyZSBTZXJ2ZXIgQ0EwHhcNMTQxMDExMDAwMDAwWhcNMTkxMDEwMjM1OTU5WjBUMSEwHwYDVQQLExhEb21haW4gQ29udHJvbCBWYWxpZGF0ZWQxFDASBgNVBAsTC1Bvc2l0aXZlU1NMMRkwFwYDVQQDExBwdWJsaWNvYmplY3QuY29tMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAjtgQtvL2kUr6ooHMOq7cxQLGycBW+ri9TGyQkO1lTb66RmcAujENxMh51wKodrveUdbqwpL4g1P49o/Y1fK5IHWAf3vpE8p3RyELY0NRlclRM24dgif/+dgRUUk+0kF3NH6MbB/kve07FMF2FyNDLxtbwJvmrn1MI5c52cpxI24vGcpOZ0VIW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://publicobject.com/helloworld.txt
GET
0
HTTP/1.1 301 Moved Permanently
8
Server: nginx/1.10.0 (Ubuntu)
Date: Sat, 08 Dec 2018 13:02:04 GMT
Content-Type: text/html
Content-Length: 194
Connection: keep-alive
Location: https://publicobject.com/helloworld.txt
OkHttp-Sent-Millis: 1544274128028
OkHttp-Received-Millis: 1544274128386

View File

@ -1,7 +0,0 @@
<html>
<head><title>301 Moved Permanently</title></head>
<body bgcolor="white">
<center><h1>301 Moved Permanently</h1></center>
<hr><center>nginx/1.10.0 (Ubuntu)</center>
</body>
</html>

View File

@ -1,75 +0,0 @@
libcore.io.DiskLruCache
1
201105
2
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
DIRTY 2d9345a30d2cc31bb3091d70a8ef6c18
CLEAN 2d9345a30d2cc31bb3091d70a8ef6c18 7618 1759
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
DIRTY 2d9345a30d2cc31bb3091d70a8ef6c18
CLEAN 2d9345a30d2cc31bb3091d70a8ef6c18 7618 1759
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
DIRTY 2d9345a30d2cc31bb3091d70a8ef6c18
CLEAN 2d9345a30d2cc31bb3091d70a8ef6c18 7618 1759
READ 4b217e04ba52215f3a6b64d28f6729c6
DIRTY 4b217e04ba52215f3a6b64d28f6729c6
CLEAN 4b217e04ba52215f3a6b64d28f6729c6 333 194
READ 2d9345a30d2cc31bb3091d70a8ef6c18
DIRTY 2d9345a30d2cc31bb3091d70a8ef6c18
CLEAN 2d9345a30d2cc31bb3091d70a8ef6c18 7618 1759

View File

@ -1 +0,0 @@
hello world

View File

@ -17,6 +17,9 @@ The "REST With Spring" Classes: http://bit.ly/restwithspring
- [Uploading MultipartFile with Spring RestTemplate](https://www.baeldung.com/spring-rest-template-multipart-upload)
- [Get and Post Lists of Objects with RestTemplate](https://www.baeldung.com/spring-rest-template-list)
- [Copy of RestTemplate Post Request with JSON](https://www.baeldung.com/spring-resttemplate-post-json-test)
- [HTTP PUT vs HTTP PATCH in a REST API](https://www.baeldung.com/http-put-patch-difference-spring)
- [A Custom Media Type for a Spring REST API](https://www.baeldung.com/spring-rest-custom-media-type)
- [Download an Image or a File with Spring MVC](https://www.baeldung.com/spring-controller-return-image-file)
### NOTE: