You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cache encoded BASIC credentials in ExchangeFilterFunctions
Prior to this commit, the Basic Authentication credentials were encoded for
each request in ExchangeFilterFunctions.basicAuthentication(String, String).
This commit addresses this minor performance issue by encoding the
credentials prior to the creation of the lambda expression returned by
ExchangeFilterFunctions.basicAuthentication(String, String).
Closesgh-23256
Copy file name to clipboardExpand all lines: spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeFilterFunctions.java
+15-13Lines changed: 15 additions & 13 deletions
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
/*
2
-
* Copyright 2002-2018 the original author or authors.
2
+
* Copyright 2002-2019 the original author or authors.
3
3
*
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
@@ -39,6 +39,7 @@
39
39
*
40
40
* @author Rob Winch
41
41
* @author Arjen Poutsma
42
+
* @author Sam Brannen
42
43
* @since 5.0
43
44
*/
44
45
publicabstractclassExchangeFilterFunctions {
@@ -90,21 +91,22 @@ public static ExchangeFilterFunction statusError(Predicate<HttpStatus> statusPre
90
91
91
92
/**
92
93
* Return a filter that applies HTTP Basic Authentication to the request
93
-
* headers via {@link HttpHeaders#setBasicAuth(String, String)}.
94
-
* @param user the user
94
+
* headers via {@link HttpHeaders#setBasicAuth(String)} and
0 commit comments