Improved logging in functional web framework
This commit improves predicate and route logging in the functional web framework.
This commit is contained in:
@@ -29,6 +29,7 @@ import java.util.Locale;
|
||||
import java.util.Map;
|
||||
import java.util.Optional;
|
||||
import java.util.OptionalLong;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
|
||||
import reactor.core.publisher.Flux;
|
||||
import reactor.core.publisher.Mono;
|
||||
@@ -127,6 +128,11 @@ public class MockServerRequest implements ServerRequest {
|
||||
return Optional.ofNullable((S) this.attributes.get(name));
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String, Object> attributes() {
|
||||
return this.attributes;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> queryParams(String name) {
|
||||
return Collections.unmodifiableList(this.queryParams.get(name));
|
||||
@@ -182,7 +188,7 @@ public class MockServerRequest implements ServerRequest {
|
||||
|
||||
private Object body;
|
||||
|
||||
private Map<String, Object> attributes = new LinkedHashMap<>();
|
||||
private Map<String, Object> attributes = new ConcurrentHashMap<>();
|
||||
|
||||
private MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<>();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user