code: def failover_all_class_methods(decorator):
      """
      This decorator function wraps an entire class to decorate each member method, incl. inherited.
  
      Adapted from https://stackoverflow.com/a/6307868
      """
  
      # Convenience function to ensure `decorate` gets wrapper function attributes: name, docs, etc.
      @functools.wraps(decorator)
      def decorate(cls):
          all_methods = (
              inspect.getmembers(cls, inspect.isbuiltin)
              + inspect.getmembers(cls, inspect.ismethod)
              + inspect.getmembers(cls, inspect.isroutine)
          )
          for name, method in all_methods:
              if not name.startswith("_"):
                  # It's safer to exclude all protected/private method from decoration
                  setattr(cls, name, decorator(method))
          return cls
  
      return decorate
  
imports: import functools
  import inspect
  import logging
  import os
  from distutils.version import LooseVersion
  from xml.etree import ElementTree
  import pyarrow
  import six
  from pyarrow.hdfs import HadoopFileSystem
  from pyarrow.lib import ArrowIOError
  from six.moves.urllib.parse import urlparse
label_desc: Use image node_id 1 for calling a global function with example usage: failover_all_class_methods(decorator) and returns: decorate, cls