Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
spring-cloud-netflix
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
openSource
spring-cloud-netflix
Commits
e7331098
Commit
e7331098
authored
Jan 15, 2015
by
Spencer Gibb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change protected and package scope fields to private
fixes gh-149
parent
84554725
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
49 additions
and
35 deletions
+49
-35
ServletWrappingEndpoint.java
...ework/cloud/netflix/endpoint/ServletWrappingEndpoint.java
+11
-4
EurekaClientAutoConfiguration.java
...k/cloud/netflix/eureka/EurekaClientAutoConfiguration.java
+1
-1
EurekaDiscoveryClient.java
...framework/cloud/netflix/eureka/EurekaDiscoveryClient.java
+1
-1
FeignConfiguration.java
...ringframework/cloud/netflix/feign/FeignConfiguration.java
+9
-9
SpringDecoder.java
...rg/springframework/cloud/netflix/feign/SpringDecoder.java
+1
-1
SpringEncoder.java
...rg/springframework/cloud/netflix/feign/SpringEncoder.java
+2
-2
RibbonLoadBalancerClient.java
...mework/cloud/netflix/ribbon/RibbonLoadBalancerClient.java
+5
-2
ZuulProxyConfiguration.java
...gframework/cloud/netflix/zuul/ZuulProxyConfiguration.java
+1
-1
Servlet30WrapperFilter.java
...loud/netflix/zuul/filters/pre/Servlet30WrapperFilter.java
+5
-1
SimpleHostRoutingFilter.java
...d/netflix/zuul/filters/route/SimpleHostRoutingFilter.java
+1
-1
FeignClientTests.java
...springframework/cloud/netflix/feign/FeignClientTests.java
+1
-1
HystrixOnlyTests.java
...ringframework/cloud/netflix/hystrix/HystrixOnlyTests.java
+1
-1
RibbonInterceptorTests.java
...ramework/cloud/netflix/ribbon/RibbonInterceptorTests.java
+3
-3
RibbonLoadBalancerClientTests.java
...k/cloud/netflix/ribbon/RibbonLoadBalancerClientTests.java
+3
-3
PreDecorationFilterTests.java
...ud/netflix/zuul/filters/pre/PreDecorationFilterTests.java
+1
-1
EurekaInstanceCanceledEvent.java
...flix/eureka/server/event/EurekaInstanceCanceledEvent.java
+1
-1
EurekaInstanceRegisteredEvent.java
...ix/eureka/server/event/EurekaInstanceRegisteredEvent.java
+1
-1
EurekaInstanceRenewedEvent.java
...tflix/eureka/server/event/EurekaInstanceRenewedEvent.java
+1
-1
No files found.
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/endpoint/ServletWrappingEndpoint.java
View file @
e7331098
...
...
@@ -36,13 +36,13 @@ public abstract class ServletWrappingEndpoint implements InitializingBean,
// TODO: move to spring-boot?
pr
otected
String
path
;
pr
ivate
String
path
;
pr
otected
boolean
sensitive
;
pr
ivate
boolean
sensitive
;
pr
otected
boolean
enabled
=
true
;
pr
ivate
boolean
enabled
=
true
;
pr
otected
final
ServletWrappingController
controller
=
new
ServletWrappingController
();
pr
ivate
final
ServletWrappingController
controller
=
new
ServletWrappingController
();
@Override
public
void
afterPropertiesSet
()
throws
Exception
{
...
...
@@ -75,6 +75,13 @@ public abstract class ServletWrappingEndpoint implements InitializingBean,
return
this
.
controller
.
handleRequest
(
request
,
response
);
}
public
boolean
isEnabled
()
{
return
enabled
;
}
public
ServletWrappingController
getController
()
{
return
controller
;
}
@Override
public
String
getPath
()
{
return
this
.
path
;
...
...
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/eureka/EurekaClientAutoConfiguration.java
View file @
e7331098
...
...
@@ -42,7 +42,7 @@ import com.netflix.discovery.converters.XmlXStream;
public
class
EurekaClientAutoConfiguration
{
@Autowired
ApplicationContext
context
;
private
ApplicationContext
context
;
@PostConstruct
public
void
init
()
{
...
...
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/eureka/EurekaDiscoveryClient.java
View file @
e7331098
...
...
@@ -90,7 +90,7 @@ public class EurekaDiscoveryClient implements DiscoveryClient {
}
static
class
EurekaServiceInstance
implements
ServiceInstance
{
InstanceInfo
instance
;
private
InstanceInfo
instance
;
EurekaServiceInstance
(
InstanceInfo
instance
)
{
this
.
instance
=
instance
;
...
...
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/feign/FeignConfiguration.java
View file @
e7331098
...
...
@@ -41,31 +41,31 @@ public class FeignConfiguration {
ConfigurableEnvironmentConfiguration
envConfig
;
// FIXME: howto enforce this?
@Autowired
Decoder
decoder
;
private
Decoder
decoder
;
@Autowired
Encoder
encoder
;
private
Encoder
encoder
;
@Autowired
Logger
logger
;
private
Logger
logger
;
@Autowired
Contract
contract
;
private
Contract
contract
;
@Autowired
(
required
=
false
)
Logger
.
Level
logLevel
;
private
Logger
.
Level
logLevel
;
@Autowired
(
required
=
false
)
Retryer
retryer
;
private
Retryer
retryer
;
@Autowired
(
required
=
false
)
ErrorDecoder
errorDecoder
;
private
ErrorDecoder
errorDecoder
;
@Autowired
(
required
=
false
)
Request
.
Options
options
;
private
Request
.
Options
options
;
@Autowired
(
required
=
false
)
Client
ribbonClient
;
private
Client
ribbonClient
;
protected
Feign
.
Builder
feign
()
{
Feign
.
Builder
builder
=
Feign
.
builder
()
...
...
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/feign/SpringDecoder.java
View file @
e7331098
...
...
@@ -43,7 +43,7 @@ import static org.springframework.cloud.netflix.feign.FeignUtils.getHttpHeaders;
public
class
SpringDecoder
implements
Decoder
{
@Autowired
Provider
<
HttpMessageConverters
>
messageConverters
;
private
Provider
<
HttpMessageConverters
>
messageConverters
;
public
SpringDecoder
()
{
}
...
...
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/feign/SpringEncoder.java
View file @
e7331098
...
...
@@ -48,7 +48,7 @@ public class SpringEncoder implements Encoder {
private
static
final
Logger
logger
=
LoggerFactory
.
getLogger
(
SpringEncoder
.
class
);
@Autowired
Provider
<
HttpMessageConverters
>
messageConverters
;
private
Provider
<
HttpMessageConverters
>
messageConverters
;
@Override
public
void
encode
(
Object
requestBody
,
RequestTemplate
request
)
...
...
@@ -105,7 +105,7 @@ public class SpringEncoder implements Encoder {
private
class
FeignOutputMessage
implements
HttpOutputMessage
{
final
ByteArrayOutputStream
outputStream
=
new
ByteArrayOutputStream
();
private
final
ByteArrayOutputStream
outputStream
=
new
ByteArrayOutputStream
();
private
final
RequestTemplate
request
;
...
...
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/ribbon/RibbonLoadBalancerClient.java
View file @
e7331098
...
...
@@ -104,8 +104,8 @@ public class RibbonLoadBalancerClient implements LoadBalancerClient {
}
protected
static
class
RibbonServer
implements
ServiceInstance
{
pr
otected
String
serviceId
;
pr
otected
Server
server
;
pr
ivate
String
serviceId
;
pr
ivate
Server
server
;
protected
RibbonServer
(
String
serviceId
,
Server
server
)
{
this
.
serviceId
=
serviceId
;
...
...
@@ -127,6 +127,9 @@ public class RibbonLoadBalancerClient implements LoadBalancerClient {
return
this
.
server
.
getPort
();
}
public
Server
getServer
()
{
return
server
;
}
}
}
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/zuul/ZuulProxyConfiguration.java
View file @
e7331098
...
...
@@ -117,7 +117,7 @@ public class ZuulProxyConfiguration extends ZuulConfiguration {
private
ProxyRouteLocator
routeLocator
;
@Autowired
ZuulHandlerMapping
zuulHandlerMapping
;
private
ZuulHandlerMapping
zuulHandlerMapping
;
@Override
public
void
onApplicationEvent
(
ApplicationEvent
event
)
{
...
...
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/zuul/filters/pre/Servlet30WrapperFilter.java
View file @
e7331098
...
...
@@ -43,7 +43,7 @@ import com.netflix.zuul.http.HttpServletRequestWrapper;
*/
public
class
Servlet30WrapperFilter
extends
ZuulFilter
{
pr
otected
Field
requestField
=
null
;
pr
ivate
Field
requestField
=
null
;
public
Servlet30WrapperFilter
()
{
this
.
requestField
=
ReflectionUtils
.
findField
(
HttpServletRequestWrapper
.
class
,
...
...
@@ -52,6 +52,10 @@ public class Servlet30WrapperFilter extends ZuulFilter {
this
.
requestField
.
setAccessible
(
true
);
}
protected
Field
getRequestField
()
{
return
requestField
;
}
@Override
public
String
filterType
()
{
return
"pre"
;
...
...
spring-cloud-netflix-core/src/main/java/org/springframework/cloud/netflix/zuul/filters/route/SimpleHostRoutingFilter.java
View file @
e7331098
...
...
@@ -363,7 +363,7 @@ public class SimpleHostRoutingFilter extends ZuulFilter {
}
public
static
class
MySSLSocketFactory
extends
SSLSocketFactory
{
SSLContext
sslContext
=
SSLContext
.
getInstance
(
"TLS"
);
private
SSLContext
sslContext
=
SSLContext
.
getInstance
(
"TLS"
);
public
MySSLSocketFactory
(
KeyStore
truststore
)
throws
NoSuchAlgorithmException
,
KeyManagementException
,
KeyStoreException
,
UnrecoverableKeyException
{
...
...
spring-cloud-netflix-core/src/test/java/org/springframework/cloud/netflix/feign/FeignClientTests.java
View file @
e7331098
...
...
@@ -58,7 +58,7 @@ public class FeignClientTests extends FeignConfiguration {
private
int
port
=
0
;
@Autowired
TestClient
testClient
;
private
TestClient
testClient
;
// @FeignClient(value = "http://localhost:9876", loadbalance = false)
@FeignClient
(
"feignclienttest"
)
...
...
spring-cloud-netflix-core/src/test/java/org/springframework/cloud/netflix/hystrix/HystrixOnlyTests.java
View file @
e7331098
...
...
@@ -120,7 +120,7 @@ class HystrixOnlyApplication {
}
@Autowired
Service
service
;
private
Service
service
;
@RequestMapping
(
"/"
)
public
String
home
()
{
...
...
spring-cloud-netflix-core/src/test/java/org/springframework/cloud/netflix/ribbon/RibbonInterceptorTests.java
View file @
e7331098
...
...
@@ -49,13 +49,13 @@ import static org.mockito.Mockito.verify;
public
class
RibbonInterceptorTests
{
@Mock
HttpRequest
request
;
private
HttpRequest
request
;
@Mock
ClientHttpRequestExecution
execution
;
private
ClientHttpRequestExecution
execution
;
@Mock
ClientHttpResponse
response
;
private
ClientHttpResponse
response
;
@Before
public
void
init
()
{
...
...
spring-cloud-netflix-core/src/test/java/org/springframework/cloud/netflix/ribbon/RibbonLoadBalancerClientTests.java
View file @
e7331098
...
...
@@ -70,7 +70,7 @@ public class RibbonLoadBalancerClientTests {
RibbonLoadBalancerClient
client
=
getRibbonLoadBalancerClient
(
server
);
ServiceInstance
serviceInstance
=
client
.
choose
(
server
.
getServiceId
());
URI
uri
=
client
.
reconstructURI
(
serviceInstance
,
new
URL
(
"http://"
+
server
.
serviceId
).
toURI
());
+
server
.
getServiceId
()
).
toURI
());
assertEquals
(
server
.
getHost
(),
uri
.
getHost
());
assertEquals
(
server
.
getPort
(),
uri
.
getPort
());
}
...
...
@@ -145,10 +145,10 @@ public class RibbonLoadBalancerClientTests {
RibbonServer
ribbonServer
)
{
given
(
this
.
loadBalancer
.
getName
()).
willReturn
(
ribbonServer
.
getServiceId
());
given
(
this
.
loadBalancer
.
chooseServer
(
anyString
()))
.
willReturn
(
ribbonServer
.
server
);
.
willReturn
(
ribbonServer
.
getServer
()
);
given
(
this
.
loadBalancer
.
getLoadBalancerStats
())
.
willReturn
(
this
.
loadBalancerStats
);
given
(
this
.
loadBalancerStats
.
getSingleServerStat
(
ribbonServer
.
server
))
given
(
this
.
loadBalancerStats
.
getSingleServerStat
(
ribbonServer
.
getServer
()
))
.
willReturn
(
this
.
serverStats
);
given
(
this
.
clientFactory
.
getLoadBalancer
(
this
.
loadBalancer
.
getName
()))
.
willReturn
(
this
.
loadBalancer
);
...
...
spring-cloud-netflix-core/src/test/java/org/springframework/cloud/netflix/zuul/filters/pre/PreDecorationFilterTests.java
View file @
e7331098
...
...
@@ -41,7 +41,7 @@ public class PreDecorationFilterTests {
private
PreDecorationFilter
filter
;
@Mock
DiscoveryClient
discovery
;
private
DiscoveryClient
discovery
;
private
ZuulProperties
properties
=
new
ZuulProperties
();
...
...
spring-cloud-netflix-eureka-server/src/main/java/org/springframework/cloud/netflix/eureka/server/event/EurekaInstanceCanceledEvent.java
View file @
e7331098
...
...
@@ -33,7 +33,7 @@ public class EurekaInstanceCanceledEvent extends ApplicationEvent {
private
String
serverId
;
boolean
replication
;
private
boolean
replication
;
public
EurekaInstanceCanceledEvent
(
Object
source
,
String
appName
,
String
serverId
,
boolean
replication
)
{
...
...
spring-cloud-netflix-eureka-server/src/main/java/org/springframework/cloud/netflix/eureka/server/event/EurekaInstanceRegisteredEvent.java
View file @
e7331098
...
...
@@ -35,7 +35,7 @@ public class EurekaInstanceRegisteredEvent extends ApplicationEvent {
private
int
leaseDuration
;
boolean
replication
;
private
boolean
replication
;
public
EurekaInstanceRegisteredEvent
(
Object
source
,
InstanceInfo
instanceInfo
,
int
leaseDuration
,
boolean
replication
)
{
...
...
spring-cloud-netflix-eureka-server/src/main/java/org/springframework/cloud/netflix/eureka/server/event/EurekaInstanceRenewedEvent.java
View file @
e7331098
...
...
@@ -37,7 +37,7 @@ public class EurekaInstanceRenewedEvent extends ApplicationEvent {
private
InstanceInfo
instanceInfo
;
boolean
replication
;
private
boolean
replication
;
public
EurekaInstanceRenewedEvent
(
Object
source
,
String
appName
,
String
serverId
,
InstanceInfo
instanceInfo
,
boolean
replication
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment