Hacker News new | ask | show | jobs
by pentium10 3906 days ago
Cool, now we can use Device Identification feature to route mobile users to a different backend, also love the HTTP/2 connection sharing.
1 comments

As always I'm skeptical of reliable device identification. Claiming to have it almost sounds like claiming to own a hen that lays golden eggs. Their blurb about it doesn't do much to convince me so far:

    Through our company, we have some customer who want us to integrate
    into HAProxy the ability to detect device type and characteristics and
    report it to the backend server. We got a couple of contributions from
    2 companies experts in this domain: 51 degrees and deviceatlas. You
    can now load those libraries in HAProxy in order to fully qualify a
    client capabilities and set up some headers your application server
    can rely on to adapt content delivered to the client or let the
    varnish cache server use it to cache multiple flavor of the same
    object based on client capabilities.

    More on this blog later on how to integrate each product.
But it would be a nice surprise if it performed well.
Speaking for DeviceAtlas in particular I can assure you that detection reliability is better than most assume. The stated 99% detection accuracy rate isn’t marketing speak—it is continously verified on real traffic from all around the world.

We measure two main aspects of performance:

- Per-request detection overhead: Willy’s preferred way to measure impact on HAProxy performance is the per request overhead added. DeviceAtlas adds a few µs per request. Typically this does not cause much of an issue. Example: if a load balancer is serving 20,000 requests per second with 80% CPU, that's 40µs of CPU time per request on a machine that can go up to 50µs. If we add 4µs to that we reach 88% of CPU under the same load, and the end user performance is not degraded in any meaningful way.

- Memory footprint: DeviceAtlas lets you configure the per-device property set to tailor the memory and performance impact. The resulting memory impact ranges from about 12MB to 100MB.