Skip to content

Refactor out attribute name, fix TTL update, upgrade logging

Tango-Controls Bot requested to merge Refactor-Attribute-Name into master

Created by: chedburgh

Refactor out Attribute Name. This combines all the attribute name functionality into a single class for ease of use. Changes:

  • Move all attribute name string functionality into AttributeName
  • Split defines into own header to be used across files and allow a central config file for doxygen.
  • Upgraded logger from macros to a simple stream based logger for better debug support.
  • Fixed updateTTL - it was not updating the ttl cache when updating the ttl
  • Changed LibHdb++Cassandra interface to name the attribute name fqdn_attr_name, since this is what it is passed.
  • Continued documenting code.
  • Added some unit tests for the new AttributeName class. These are based on the Catch framework, and its header has been added to /test.
  • Improved Makefile to be more readable, add new test targets and doc targets.

IMPORTANT: I have studied the API and tested it, and from this drawn the conclusion that only fqdn_attr_name (fully qualified domain attribute name) type attribute names are passed. This is what the AttributeName object is based on. If it is not passed this string, it will throw an exception. I would recommend we fix the API this way, rather than leave it ambiguous (it would not handle this anyway, since it would cause undefined behaviour right now in some places).

Merge request reports