code: def retention_policy_alter(database,
                             name,
                             duration,
                             replication,
                             default=False,
                             user=None,
                             password=None,
                             host=None,
                             port=None):
      '''
      Modify an existing retention policy.
  
      database
          The database to operate on.
  
      name
          Name of the policy to modify.
  
      duration
          How long InfluxDB keeps the data.
  
      replication
          How many copies of the data are stored in the cluster.
  
      default
          Whether this policy should be the default or not. Default is False.
  
      CLI Example:
  
      .. code-block:: bash
  
          salt '*' influxdb08.retention_policy_modify metrics default 1d 1
      '''
      client = _client(user=user, password=password, host=host, port=port)
      client.alter_retention_policy(name, database, duration, replication, default)
      return Truf retention_policy_alter(database,
                             name,
                             duration,
                             replication,
                             default=False,
                             user=None,
                             password=None,
                             host=None,
                             port=None):
      '''
      Modify an existing retention policy.
  
      database
          The database to operate on.
  
      name
          Name of the policy to modify.
  
      duration
          How long InfluxDB keeps the data.
  
      replication
          How many copies of the data are stored in the cluster.
  
      default
          Whether this policy should be the default or not. Default is False.
  
      CLI Example:
  
      .. code-block:: bash
  
          salt '*' influxdb08.retention_policy_modify metrics default 1d 1
      '''
      client = _client(user=user, password=password, host=host, port=port)
      client.alter_retention_policy(name, database, duration, replication, default)
      return True
docs: Modify an existing retention policy.
  
      database
          The database to operate on.
  
      name
          Name of the policy to modify.
  
      duration
          How long InfluxDB keeps the data.
  
      replication
          How many copies of the data are stored in the cluster.
  
      default
          Whether this policy should be the default or not. Default is False.
  
      CLI Example:
  
      .. code-block:: bash
  
          salt '*' influxdb08.retention_policy_modify metrics default 1d 1