How is this different from the current (default) client IP hashing? Mainly that 
you can select different source data for the hash?
 


     On Monday, August 10, 2015 6:28 AM, Phil Sorber <sor...@apache.org> wrote:
   

 On Sun, Aug 9, 2015 at 11:18 PM Brian Geffon <briangef...@gmail.com> wrote:

> It wouldn't really make sense to introduce a new data structure (the
> consistent hash ring code), I'll can reuse the consistent hashing algorithm
> but not any associated data structures. Regarding parent selection, how did
> you think they could be more consistent?
>
>
Not sure without looking at your code. Just wondering if there was some
config convention that you came up with that makes more sense, or something
like that. It's entirely possible that all they share is the consistent
hash ring. I just think it would be a bad user experience if two similarly
named and behaving things were wildly different from a user perspective.


> On Mon, Aug 10, 2015 at 12:10 PM, Phil Sorber <sor...@apache.org> wrote:
>
> > On Sun, Aug 9, 2015 at 9:10 PM Brian Geffon <briangef...@gmail.com>
> wrote:
> >
> > > All,
> > > We currently support strict and timed round robin for round robin DNS
> > > records and I'd like to propose adding consistent hashing based DNS
> > > selection. We're trying to replace our current ATS -> Haproxy setup
> with
> > > only ATS and that's been the motivation behind all of our recent HostDB
> > > improvements because we (and many others) use Haproxy simply for load
> > > balancing / host selection.
> > >
> > > I've been hacking around with a few ideas and implementation methods
> but
> > > basically here is what I have so far:
> > >
> > > 1) Add a new records.config called called
> > > proxy.config.hostdb.consisent_hash of type INT which will enable /
> > disable
> > > the feature.
> > >
> > > 2) Add a new records.config option called
> > > proxy.config.hostdb.consistent_hash_selection of type STRING, this will
> > be
> > > how the string is assembled to produce the hash. After bouncing a few
> > ideas
> > > around I was thinking a subset of the custom log format strings make
> the
> > > most sense (
> > >
> > >
> >
> https://docs.trafficserver.apache.org/en/latest/admin/event-logging-formats.en.html
> > > ),
> > > so basically you would do something like:
> > >
> > >    CONFIG proxy.config.hostdb.consistent_hash_selection STRING %<cqup>
> > > %<{X-Foo-Header}cqh>
> > >
> > > This would hash based on the pre-remapped request path and an incoming
> > > header called "X-Foo-Header." Reusing this existing syntax seemed to
> make
> > > the most sense. Additionally, because  cookies are typically a good way
> > to
> > > uniquely identify a session I'll likely add another format which will
> get
> > > the value of an individual cookie, is this something people would find
> > > useful?
> > >
> > > I'd really love feedback before I land the patch. Thoughts?
> > >
> > > Thanks,
> > > Brian
> > >
> >
> >
> > Do you plan to reuse the existing consistent hash ring code?
> >
> > Is there anything we can do to make consistent hash parent selection more
> > consistent with the consistent hash hostdb implementation? (you see what
> I
> > did there?)
> >
>


  

Reply via email to