docstr: Create a new metric and add into cache.
      Add a metric which is generic with custom metrics
  
  Parameters
  ----------
  metric_name: str
      Name of metric
  unit: str
      unit of metric
  dimension_names: list
      list of dimension name strings for the metric
  metric_type: MetricTypes
      Type of metric
  
  Returns
  -------
  Created metrics object
docstr_tok: ["Create","a","new","metric","and","add","into","cache",".","Add","a","metric","which","is","generic","with","custom","metrics","Parameters","--","--","--","--","--","metric_name",":","str","Name","of","metric","unit",":","str","unit","of","metric","dimension_names",":","list","list","of","dimension","name","strings","for","the","metric","metric_type",":","MetricTypes","Type","of","metric","Returns","--","--","--","-","Created","metrics","object"]
code: def add_metric_to_cache(
      self,
      metric_name: str,
      unit: str,
      dimension_names: list = [],
      metric_type: MetricTypes = MetricTypes.COUNTER,
  ) -> MetricAbstract:
      """
      Create a new metric and add into cache.
          Add a metric which is generic with custom metrics
  
      Parameters
      ----------
      metric_name: str
          Name of metric
      unit: str
          unit of metric
      dimension_names: list
          list of dimension name strings for the metric
      metric_type: MetricTypes
          Type of metric
  
      Returns
      -------
      Created metrics object
      """
      pass
  
imports: import abc
  import os
  import ts.metrics.metric_cache_errors
  from ts.metrics.dimension import Dimension
  from ts.metrics.metric_abstract import MetricAbstract
  from ts.metrics.metric_type_enum import MetricTypes
label_desc: Use image node_id 15 for calling the MetricCacheAbstract obj's underlying member method code with example usage: obj.add_metric_to_cache(metric_name, unit, dimension_names, metric_type) without return types