DNS for Service Discovery in HAProxy
haproxy.com
haproxy.com
I'm not suggesting you use it but (as for how it works in general) look into how Microsoft's Active Directory works. They've had the "service discovery" problem figured out for going on two decades, including preferences for "closer" servers, weighting, and so on.
I'm no MS fan by any means but AD is one MS product that really is awesome.
I didn't mean to suggest that they had some revolutionary new unique way of handling service discovery or even that they were the first. I think maybe you misinterpreted or misunderstood my intentions.
LDAP and Kerberos of all implementation are probably the most common use case for SRV records, most people probably don’t even know it. Real shame, in many ways I wish A/AAAA records weren’t even a thing for the vast majority of services (HTTP, I’m looking at you!)
Browsers do not own the A record and should never have been using it in the first place, so to continue squatting them and invent specious reasons for doing so is simple arrogance and assertion of unwarranted privilege.
Instead we have the multiple warts and misbehaviours of misusing the DNS for URL endpoint resolution.
https://www.haproxy.com/products/haproxy-enterprise-edition/
However, I would strongly consider hiring a mature developer relations manager. You're a fantastic developer, Willy, but you risk losing business by lashing out like this.
We work hand-in-hand : if I fail at my task, the product dies and the company suffers as well. If the company fails, I will have to find another way to eat my daily steak and that will necessarily affect the project. That's why the company helps me in this difficult task by hiring the developers I need to help me on this job and why in turn I freely express my opinion when people attack the company's motivations in a way that I find really unfair.
And if you want to get a better sense of what I'm saying, just issues this in the master branch to see who fixes most of the bugs, resulting in haproxy being really usable in production by all of us :
$ git shortlog --grep BUG v1.7.0..
https://www.haproxy.com/products/haproxy-community-vs-enterp...
Said that. Yes I'm grateful to be able to run and modify both HAproxy and Nginx for free, but parent is totally right in the comment. Both projects are going that route, compared with their beginnings.
Rather have founders like wtarreau speak their mind than adopt some fake passive aggressive tone or have a 'dev relations manager' spinning, at least here.
'correcting an assumption' seems orthogonal to 'lashing out'.
also, it's not clear he even addressed the op's point, insofar as i understand. haproxy enterprise does seem to contain features unavailable in the 'community' version:
http://www.haproxy.com/products/haproxy-community-vs-enterpr...
In fact, it's important to understand what enterprise users need : they never want to have to deal with patches or feature backports, most of them don't want to have to build anything, and instead they want to install regular pre-compiled packages from a permanently updated repository. That's exactly what we provide them. But providing pre-compiled packages is no excuse for not giving their sources at the same time, which we do.
Let me be very clear about something : a load balancer (and haproxy is no exception to this) is a very complex component and will always have bugs. And it happens that where it's deployed it's a critical component that must never fail, which is a bit incompatible with the first rule. For having dealt with proprietary LBs in the past, I'm well placed to know that you cannot and must never trust a non-fully opensource load balancer. And we've kept this spirit of full openness to achieve the highest possible reliability, and the GPL maintains this guarantee here. Some of the top contributors of the project are/have been working for enterprise customers and have brought very detailed analysis about certain issues, sometimes even proposing patches to fix them (or also small changes to make their life easier). As the project manager, I don't care where a patch comes from: any user, an occasional code reviewer, a customer, one of my coworkers etc. A fix is a fix, and if it addresses a real bug it must be merged, and the same rule as in the kernel applies here with no exception : mainline first. This guarantees that no patch is lost and the fact that the patch is the most possibly correct. And in order to get these fixes, you have to be the most open.
The situation as it is now benefits the two categories of users : - enterprise users don't have to wait for the next release to get certain features they need right now : some of the features from haproxy-1.8-dev are already present in HAPEE 1.6 or 1.7. So basically these users are encouraged to pick the most stable version which satisfies all their needs. - mainline code benefits from some feedback from the field (improvements and fixes) before the final release, which has allowed us quite a few time to adjust certain confusing things (option names, default behaviour, etc) before declaring them "stable" and having to maintain them forever.
The only advice I could give to people considering adopting a load balancer from a vendor : during the evaluation, ASK FOR THE SOURCES! If you can't have them, never use this product, one day or another you will regret it. And I'm not saying this just to try to place us in front when many other solutions are closed, but simply because I've been in this situation of using a closed product quite a few times in the past and hated it. That's even what led me to create haproxy in the first place!
On the opposite, in nginx, some features are developed only in their proprietary solution. Sometime, nginx inc passes for heroes because they open source some of them...
Note this feature has not yet been backported into HAProxy Enterprise...
http://www.haproxy.com/products/haproxy-community-vs-enterpr...
HAProxy Technologies pushes first its developments in the -dev community branch. Check the commits for the feature given above (SRV records, non exhaustive list of patches): http://git.haproxy.org/?p=haproxy.git&a=search&h=HEAD&st=com...
HAProxy technologies simply makes the effort of maintaining a branch of HAProxy in which some -dev features are backported. That way, users of HAProxy Enterprise have the most stable and feature reach version of HAProxy. And as Willy stated, every user of HAProxy Enterprise also have access to the source packages.
So from a business point of view, the main difference between HAProxy and nginx is that HAProxy is the respects both its community and customers.
Any change to get some directions how to test this functionality?
So far I have currently 1.8-dev2 up and running but now I find no real references about how to try it .. and if available in this repo. (maybe i have to dig into the code ?)
Thanks and all the best.
Thanks and sorry for the noise
If anything, a lot of people pair the two, but have so far often had to resort to cumbersome solutions for rewriting the Haproxy config to keep the set of backends in Haproxy updated.
If anything, this will make Haproxy and Consul work much better together, given that Consul serves up SRV records for the services you register with it.
We're quite proud of the result because it makes HAProxy able to scale up / down at run time without being reloaded and compatible with any service registry able to export a list of nodes delivering a same service through DNS.
HAProxy can use multiple name for the resolution, pointing to different set of DNS servers, enforcing custom "hold" timers (to bypass server's TTL or negative TTLs in case of NX, etc...) and mix all of this with "old style hardcoded" servers in the backend...
HAProxy is flexible :)
So yes, this feature was missing in HAProxy and we catched up because our community and some customers asked for it. So they can now use the power of HAProxy with their current consul deployments.
Currently using dnsmasq but would like to use erl-dns once I finish wrapping it with an HTTP admin API.
The DNS-SD code will ship with HAProxy 1.8, and we will gladly help out by adding it to the above ingress controller after the release. A WIP of that code is up on github in case you’re interested. In fact, HAProxy is full of surprises and little known features (like the dynamic scaling via haproxy runtime api we already contributed to the controller) and we're happy to share them with everyone!