Skip to content

Conversation

@amajumdar
Copy link

I noticed several severe issues with the use of feign client and feign.RibbonModule. All this while I was under the impression that it leverages the Ribbon implementation of http client(RestClient) but it does not.

I saw the following issues:

  1. Connection leaks. The server runs out of file descriptors after a day of hundreds of client calls.
  2. Every time a request is made, a new connection is opened.
  3. Also some of the Ribbon properties like shiro-client.ribbon.OkToRetryOnAllOperations=false are ignored.

I noticed several severe issues with the use of feign client and feign.RibbonModule. All this while I was under the impression that it leverages the Ribbon implementation of http client(RestClient) but it does not. 

I saw the following issues:
1. Connection leaks. The server runs out of file descriptors after a day of hundreds of client calls.
2. Every time a request is made, a new connection is opened.
3. Also some of the Ribbon properties like shiro-client.ribbon.OkToRetryOnAllOperations=false are ignored.
@cloudbees-pull-request-builder

feign-pull-requests #132 FAILURE
Looks like there's a problem with this pull request

@allenxwang
Copy link
Contributor

@amajumdar Can you take a look at the cloudbee build failure?

@cloudbees-pull-request-builder

feign-pull-requests #133 FAILURE
Looks like there's a problem with this pull request

Minor changes due to changes in super class AbstractLoadBalancerAwareClient
@cloudbees-pull-request-builder

feign-pull-requests #134 FAILURE
Looks like there's a problem with this pull request

@cloudbees-pull-request-builder

feign-pull-requests #135 SUCCESS
This pull request looks good

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I addressed this compatibility issue in

#90

@adriancole Should we just cherry pick that into master?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There has been some drift. I think a new commit will need to be made

@allenxwang
Copy link
Contributor

Overall, I think this should work.

@adriancole Can you take a look and see if using Ribbon's RestClient will break any Feign's functionality?

@Xorlev
Copy link

Xorlev commented Jun 27, 2014

Any chance this might get integrated?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this correct behavior? Eureka source seems to indicate that leaving on the port as a part of the vipAddress is standard:

From AbstractInstanceConfig.java:

    @Override
    public String getVirtualHostName() {
        return (getHostName(false) + ":" + getNonSecurePort());
    }

Seems to me that honoring exactly what's passed in by the user (minus http/https) is preferable.

@codefromthecrypt
Copy link
Contributor

Let me know if folks still want an opinion on this one. Happy to make a review pass.

@codefromthecrypt
Copy link
Contributor

this probably needs to be revisited using latest ribbon and latest feign. Feel free to reopen!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants