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
a913369d
Commit
a913369d
authored
Mar 07, 2016
by
Spencer Gibb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Upgrade feign version to 8.15.0
fixes gh-880
parent
eed5a6f1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
4 deletions
+32
-4
FeignClientTests.java
...framework/cloud/netflix/feign/valid/FeignClientTests.java
+31
-3
pom.xml
spring-cloud-netflix-dependencies/pom.xml
+1
-1
No files found.
spring-cloud-netflix-core/src/test/java/org/springframework/cloud/netflix/feign/valid/FeignClientTests.java
View file @
a913369d
...
...
@@ -74,6 +74,7 @@ import feign.Logger;
import
feign.RequestInterceptor
;
import
feign.RequestTemplate
;
import
rx.Observable
;
import
rx.Single
;
/**
* @author Spencer Gibb
...
...
@@ -116,6 +117,9 @@ public class FeignClientTests {
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/hello"
)
Hello
getHello
();
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/hello"
)
Single
<
Hello
>
getHelloSingle
();
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/hellos"
)
List
<
Hello
>
getHellos
();
...
...
@@ -179,6 +183,9 @@ public class FeignClientTests {
@FeignClient
(
name
=
"localapp3"
,
fallback
=
HystrixClientFallback
.
class
)
protected
interface
HystrixClient
{
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/fail"
)
Single
<
Hello
>
failSingle
();
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/fail"
)
Hello
fail
();
@RequestMapping
(
method
=
RequestMethod
.
GET
,
value
=
"/fail"
)
...
...
@@ -198,13 +205,18 @@ public class FeignClientTests {
}
@Override
public
Single
<
Hello
>
failSingle
()
{
return
Single
.
just
(
new
Hello
(
"fallbacksingle"
));
}
@Override
public
HystrixCommand
<
Hello
>
failCommand
()
{
return
new
FallbackCommand
<>(
new
Hello
(
"fallbackcommand"
));
}
@Override
public
Observable
<
Hello
>
failObservable
()
{
return
new
FallbackCommand
<>(
new
Hello
(
"fallbackobservable"
)).
observe
(
);
return
Observable
.
just
(
new
Hello
(
"fallbackobservable"
)
);
}
@Override
...
...
@@ -363,6 +375,15 @@ public class FeignClientTests {
}
@Test
public
void
testSingle
()
{
Single
<
Hello
>
single
=
this
.
testClient
.
getHelloSingle
();
assertNotNull
(
"single was null"
,
single
);
Hello
hello
=
single
.
toBlocking
().
value
();
assertNotNull
(
"hello was null"
,
hello
);
assertEquals
(
"first hello didn't match"
,
new
Hello
(
HELLO_WORLD_1
),
hello
);
}
@Test
public
void
testNoContentResponse
()
{
ResponseEntity
response
=
testClient
.
noContent
();
assertNotNull
(
"response was null"
,
response
);
...
...
@@ -401,7 +422,15 @@ public class FeignClientTests {
}
@Test
@Ignore
(
"Until HystrixCommand works in fallback"
)
public
void
testHystrixFallbackSingle
()
{
Single
<
Hello
>
single
=
hystrixClient
.
failSingle
();
assertNotNull
(
"single was null"
,
single
);
Hello
hello
=
single
.
toBlocking
().
value
();
assertNotNull
(
"hello was null"
,
hello
);
assertEquals
(
"message was wrong"
,
"fallbacksingle"
,
hello
.
getMessage
());
}
@Test
public
void
testHystrixFallbackCommand
()
{
HystrixCommand
<
Hello
>
command
=
hystrixClient
.
failCommand
();
assertNotNull
(
"command was null"
,
command
);
...
...
@@ -411,7 +440,6 @@ public class FeignClientTests {
}
@Test
@Ignore
(
"Until Observable works in fallback"
)
public
void
testHystrixFallbackObservable
()
{
Observable
<
Hello
>
observable
=
hystrixClient
.
failObservable
();
assertNotNull
(
"observable was null"
,
observable
);
...
...
spring-cloud-netflix-dependencies/pom.xml
View file @
a913369d
...
...
@@ -19,7 +19,7 @@
<spring-cloud-stream.version>
1.0.0.BUILD-SNAPSHOT
</spring-cloud-stream.version>
<archaius.version>
0.7.3
</archaius.version>
<eureka.version>
1.4.2
</eureka.version>
<feign.version>
8.1
4.4
</feign.version>
<feign.version>
8.1
5.0
</feign.version>
<hystrix.version>
1.4.24
</hystrix.version>
<ribbon.version>
2.1.0
</ribbon.version>
<servo.version>
0.10.1
</servo.version>
...
...
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