Skip to content
This repository was archived by the owner on May 14, 2020. It is now read-only.
This repository was archived by the owner on May 14, 2020. It is now read-only.

Change the API for defining client_lib_id #36

Description

@dlyash

The approach introduced in #34 assumes that library users will use the following code to set this identifier globally:

LibNameVersionHolder.setClientLibName("name");
LibNameVersionHolder.setClientLibVersion("version");

On my opinion this approach has some severe drawbacks:

  • Not straightforward. Users need some sacred knowledge to make use of this API: that there's some class in the library with static methods which affect library behaviour
  • Not flexible. No way to specify Client Lib ID on the fine-grained level (i.e. instance of client). Also, static methods mean no way to override them.
  • Not testable. Users of the library have to jump through hops to unit-test their code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions