<commit_before><div>
  <h3>Database Fragmentation</h3>
  <div class="sub_section">
    <div>Set the database fragmentation level to determine the point when compaction is triggered.</div>
    <p class="row">
      <input
        type="checkbox"
        id="48099acb-df16-4e1e-9949-2aaccfeb9e41"
        ng-model="autoCompactionSettings.databaseFragmentationThreshold.percentageFlag"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        class="check-for-databaseFragmentationThresholdPercentage">
      <input
        type="number"
        id="decaebe7-bb14-4c1f-9bb1-70ceb7fb2e43"
        ng-model="autoCompactionSettings.databaseFragmentationThreshold.percentage"
        name="databaseFragmentationThreshold_percentage_"
        ng-class="{invalid: validationErrors.databaseFragmentationThreshold_percentage_}"
        ng-disabled="!autoCompactionSettings.databaseFragmentationThreshold.percentageFlag || (rbac && !rbac.cluster.settings.write)"> %
      <span class="error-container err-databaseFragmentationThreshold-percentage-" ng-show="validationErrors.databaseFragmentationThreshold_percentage_">{{validationErrors.databaseFragmentationThreshold_percentage_}}</span>
    </p>
    <p class="row">
      <input
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        class="check-for-databaseFragmentationThresholdSize"
        ng-model="autoCompactionSettings.databaseFragmentationThreshold.sizeFlag">
      <input
        type="number"
        id="settings-db-compaction-size"
        name="databaseFragmentationThreshold_size_"
        ng-model="autoCompactionSettings.databaseFragmentationThreshold.size"
        ng-class="{invalid: validationErrors.databaseFragmentationThreshold_size_}"
        ng-disabled="!autoCompactionSettings.databaseFragmentationThreshold.sizeFlag || (rbac && !rbac.cluster.settings.write)" class="size"> MB
      <span class="error-container err-databaseFragmentationThreshold-size-" ng-show="validationErrors.databaseFragmentationThreshold_size_">{{validationErrors.databaseFragmentationThreshold_size_}}</span>
    </p>
  </div>

  <h3>View Fragmentation</h3>
  <div class="sub_section">
    <div>Set the view fragmentation level to determine the point when compaction is triggered.</div>
    <p class="row">
      <input
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        id="0a2cb7a3-84b7-4822-bf32-87d3e192926a"
        ng-model="autoCompactionSettings.viewFragmentationThreshold.percentageFlag"
        class="check-for-viewFragmentationThresholdPercentage" />
      <input
        id="8e49a092-3108-46ed-b5c3-9b95c4ceda6f"
        ng-model="autoCompactionSettings.viewFragmentationThreshold.percentage"
        name="viewFragmentationThreshold_percentage_"
        ng-class="{invalid: validationErrors.viewFragmentationThreshold_percentage_}"
        ng-disabled="!autoCompactionSettings.viewFragmentationThreshold.percentageFlag || (rbac && !rbac.cluster.settings.write)"
        type="number"> %
      <span class="error-container err-viewFragmentationThreshold-percentage-" ng-show="validationErrors.viewFragmentationThreshold_percentage_">{{validationErrors.viewFragmentationThreshold_percentage_}}</span>
    </p>
    <p class="row">
      <input
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        class="check-for-viewFragmentationThresholdSize"
        ng-model="autoCompactionSettings.viewFragmentationThreshold.sizeFlag">
      <input
        type="number"
        id="settings-view-compaction-size"
        ng-model="autoCompactionSettings.viewFragmentationThreshold.size"
        name="viewFragmentationThreshold_size_"
        ng-class="{invalid: validationErrors.viewFragmentationThreshold_size_}"
        ng-disabled="!autoCompactionSettings.viewFragmentationThreshold.sizeFlag || (rbac && !rbac.cluster.settings.write)"
        class="size"> MB
      <span class="error-container err-viewFragmentationThreshold-size-" ng-show="validationErrors.viewFragmentationThreshold_size_">{{validationErrors.viewFragmentationThreshold_size_}}</span>
    </p>
  </div>
  <h3>Time Interval</h3>
  <div class="sub_section">
    <div class="row">
      <input
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        id="f5962927-16af-4eb6-802c-86fe6c3a238d"
        class="check-for-allowedTimePeriod"
        ng-model="autoCompactionSettings.allowedTimePeriodFlag"/>
      <label for="f5962927-16af-4eb6-802c-86fe6c3a238d">Set the time interval for when compaction is allowed to run</label>
    </div>
    <div
      mn-period="allowedTimePeriod"
      auto-compaction-settings="autoCompactionSettings"
      rbac="rbac"
      errors="validationErrors">
    </div>
    <div class="row">
      <input
        id="f6fb6488-c05a-4baa-88f7-27032da6600b"
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        name="parallelDBAndViewCompaction"
        ng-class="{invalid: validationErrors.parallelDBAndViewCompaction}"
        ng-model="autoCompactionSettings.parallelDBAndViewCompaction"
        value="true" />
      <label for="f6fb6488-c05a-4baa-88f7-27032da6600b">Compact Bucket and Views Index in parallel</label>
      <div class="error-container err-parallelDBAndViewCompaction" ng-show="validationErrors.parallelDBAndViewCompaction">{{validationErrors.parallelDBAndViewCompaction}}</div>
    </div>
  </div>

  <h3 class="only-when-40" ng-if="!isBucketsSettings && poolDefault.compat.atLeast40">Index Fragmentation</h3>
  <div class="sub_section only-when-40" id="js_index_fragmentation_settings" ng-if="!isBucketsSettings && poolDefault.compat.atLeast40">
    <div class="row">
      <input
        type="radio"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        id="index-regular-compaction-radio"
        class="check-for-allowedTimePeriod"
        name="indexCircularCompaction"
        ng-value="false"
        ng-model="autoCompactionSettings.indexCircularCompactionFlag">
      <label for="index-regular-compaction-radio">Set the index fragmentation level to determine the point when compaction is triggered.</label>
    </div>
    <div class="row">
      <input
        type="number"
        ng-disabled="(rbac && !rbac.cluster.settings.write) || autoCompactionSettings.indexCircularCompactionFlag === true"
        ng-model="autoCompactionSettings.indexFragmentationThreshold.percentage"> %
      <span
        class="error-container err-indexFragmentationThreshold-percentage-"
        ng-show="validationErrors.indexFragmentationThreshold_percentage_">{{validationErrors.indexFragmentationThreshold_percentage_}}</span>
    </div>
    <div class="row">
      <input
        type="radio"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        id="index-circular-compaction-radio"
        class="check-for-allowedTimePeriod"
        name="indexCircularCompaction"
        ng-value="true"
        ng-model="autoCompactionSettings.indexCircularCompactionFlag">
      <label for="index-circular-compaction-radio">Use circular compaction with time interval for when defragmintation is allowed to run.</label>
    </div>
    <div class="row">
      <span ng-repeat="day in daysOfWeek">
        <input
          ng-disabled="!autoCompactionSettings.indexCircularCompactionFlag"
          type="checkbox"
          style="vertical-align:middle;"
          id="days_of_week_{{day}}"
          ng-model="autoCompactionSettings.indexCircularCompactionDaysOfWeek[day]"
          ng-value="day">
        <label style="vertical-align:middle;margin-right:5px;" for="days_of_week_{{day}}">
          {{day}}
        </label>
      </span>
    </div>
    <div class="row">
      <div
        mn-period="indexCircularCompaction"
        auto-compaction-settings="autoCompactionSettings"
        rbac="rbac"
        errors="validationErrors">
      </div>
    </div>
  </div>

  <h3>Metadata Purge Interval</h3>
  <div class="sub_section">
    <div class="row">
      <label for="fc68aaf1-9519-4eeb-ba28-3daa042aae22">Set the frequency of metadata purge interval:</label>
      <input
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        ng-model="autoCompactionSettings.purgeInterval"
        ng-class="{invalid: validationErrors.purgeInterval}"
        id="fc68aaf1-9519-4eeb-ba28-3daa042aae22"
        name="purgeInterval"
        style="width: 2.5em;"><commit_msg>added rbac permission for circularCompactionDaysOfWeek<commit_after><div>
  <h3>Database Fragmentation</h3>
  <div class="sub_section">
    <div>Set the database fragmentation level to determine the point when compaction is triggered.</div>
    <p class="row">
      <input
        type="checkbox"
        id="48099acb-df16-4e1e-9949-2aaccfeb9e41"
        ng-model="autoCompactionSettings.databaseFragmentationThreshold.percentageFlag"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        class="check-for-databaseFragmentationThresholdPercentage">
      <input
        type="number"
        id="decaebe7-bb14-4c1f-9bb1-70ceb7fb2e43"
        ng-model="autoCompactionSettings.databaseFragmentationThreshold.percentage"
        name="databaseFragmentationThreshold_percentage_"
        ng-class="{invalid: validationErrors.databaseFragmentationThreshold_percentage_}"
        ng-disabled="!autoCompactionSettings.databaseFragmentationThreshold.percentageFlag || (rbac && !rbac.cluster.settings.write)"> %
      <span class="error-container err-databaseFragmentationThreshold-percentage-" ng-show="validationErrors.databaseFragmentationThreshold_percentage_">{{validationErrors.databaseFragmentationThreshold_percentage_}}</span>
    </p>
    <p class="row">
      <input
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        class="check-for-databaseFragmentationThresholdSize"
        ng-model="autoCompactionSettings.databaseFragmentationThreshold.sizeFlag">
      <input
        type="number"
        id="settings-db-compaction-size"
        name="databaseFragmentationThreshold_size_"
        ng-model="autoCompactionSettings.databaseFragmentationThreshold.size"
        ng-class="{invalid: validationErrors.databaseFragmentationThreshold_size_}"
        ng-disabled="!autoCompactionSettings.databaseFragmentationThreshold.sizeFlag || (rbac && !rbac.cluster.settings.write)" class="size"> MB
      <span class="error-container err-databaseFragmentationThreshold-size-" ng-show="validationErrors.databaseFragmentationThreshold_size_">{{validationErrors.databaseFragmentationThreshold_size_}}</span>
    </p>
  </div>

  <h3>View Fragmentation</h3>
  <div class="sub_section">
    <div>Set the view fragmentation level to determine the point when compaction is triggered.</div>
    <p class="row">
      <input
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        id="0a2cb7a3-84b7-4822-bf32-87d3e192926a"
        ng-model="autoCompactionSettings.viewFragmentationThreshold.percentageFlag"
        class="check-for-viewFragmentationThresholdPercentage" />
      <input
        id="8e49a092-3108-46ed-b5c3-9b95c4ceda6f"
        ng-model="autoCompactionSettings.viewFragmentationThreshold.percentage"
        name="viewFragmentationThreshold_percentage_"
        ng-class="{invalid: validationErrors.viewFragmentationThreshold_percentage_}"
        ng-disabled="!autoCompactionSettings.viewFragmentationThreshold.percentageFlag || (rbac && !rbac.cluster.settings.write)"
        type="number"> %
      <span class="error-container err-viewFragmentationThreshold-percentage-" ng-show="validationErrors.viewFragmentationThreshold_percentage_">{{validationErrors.viewFragmentationThreshold_percentage_}}</span>
    </p>
    <p class="row">
      <input
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        class="check-for-viewFragmentationThresholdSize"
        ng-model="autoCompactionSettings.viewFragmentationThreshold.sizeFlag">
      <input
        type="number"
        id="settings-view-compaction-size"
        ng-model="autoCompactionSettings.viewFragmentationThreshold.size"
        name="viewFragmentationThreshold_size_"
        ng-class="{invalid: validationErrors.viewFragmentationThreshold_size_}"
        ng-disabled="!autoCompactionSettings.viewFragmentationThreshold.sizeFlag || (rbac && !rbac.cluster.settings.write)"
        class="size"> MB
      <span class="error-container err-viewFragmentationThreshold-size-" ng-show="validationErrors.viewFragmentationThreshold_size_">{{validationErrors.viewFragmentationThreshold_size_}}</span>
    </p>
  </div>
  <h3>Time Interval</h3>
  <div class="sub_section">
    <div class="row">
      <input
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        id="f5962927-16af-4eb6-802c-86fe6c3a238d"
        class="check-for-allowedTimePeriod"
        ng-model="autoCompactionSettings.allowedTimePeriodFlag"/>
      <label for="f5962927-16af-4eb6-802c-86fe6c3a238d">Set the time interval for when compaction is allowed to run</label>
    </div>
    <div
      mn-period="allowedTimePeriod"
      auto-compaction-settings="autoCompactionSettings"
      rbac="rbac"
      errors="validationErrors">
    </div>
    <div class="row">
      <input
        id="f6fb6488-c05a-4baa-88f7-27032da6600b"
        type="checkbox"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        name="parallelDBAndViewCompaction"
        ng-class="{invalid: validationErrors.parallelDBAndViewCompaction}"
        ng-model="autoCompactionSettings.parallelDBAndViewCompaction"
        value="true" />
      <label for="f6fb6488-c05a-4baa-88f7-27032da6600b">Compact Bucket and Views Index in parallel</label>
      <div class="error-container err-parallelDBAndViewCompaction" ng-show="validationErrors.parallelDBAndViewCompaction">{{validationErrors.parallelDBAndViewCompaction}}</div>
    </div>
  </div>

  <h3 class="only-when-40" ng-if="!isBucketsSettings && poolDefault.compat.atLeast40">Index Fragmentation</h3>
  <div class="sub_section only-when-40" id="js_index_fragmentation_settings" ng-if="!isBucketsSettings && poolDefault.compat.atLeast40">
    <div class="row">
      <input
        type="radio"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        id="index-regular-compaction-radio"
        class="check-for-allowedTimePeriod"
        name="indexCircularCompaction"
        ng-value="false"
        ng-model="autoCompactionSettings.indexCircularCompactionFlag">
      <label for="index-regular-compaction-radio">Set the index fragmentation level to determine the point when compaction is triggered.</label>
    </div>
    <div class="row">
      <input
        type="number"
        ng-disabled="(rbac && !rbac.cluster.settings.write) || autoCompactionSettings.indexCircularCompactionFlag === true"
        ng-model="autoCompactionSettings.indexFragmentationThreshold.percentage"> %
      <span
        class="error-container err-indexFragmentationThreshold-percentage-"
        ng-show="validationErrors.indexFragmentationThreshold_percentage_">{{validationErrors.indexFragmentationThreshold_percentage_}}</span>
    </div>
    <div class="row">
      <input
        type="radio"
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        id="index-circular-compaction-radio"
        class="check-for-allowedTimePeriod"
        name="indexCircularCompaction"
        ng-value="true"
        ng-model="autoCompactionSettings.indexCircularCompactionFlag">
      <label for="index-circular-compaction-radio">Use circular compaction with time interval for when defragmintation is allowed to run.</label>
    </div>
    <div class="row">
      <span ng-repeat="day in daysOfWeek">
        <input
          ng-disabled="!autoCompactionSettings.indexCircularCompactionFlag || !rbac.cluster.settings.write"
          type="checkbox"
          style="vertical-align:middle;"
          id="days_of_week_{{day}}"
          ng-model="autoCompactionSettings.indexCircularCompactionDaysOfWeek[day]"
          ng-value="day">
        <label style="vertical-align:middle;margin-right:5px;" for="days_of_week_{{day}}">
          {{day}}
        </label>
      </span>
    </div>
    <div class="row">
      <div
        mn-period="indexCircularCompaction"
        auto-compaction-settings="autoCompactionSettings"
        rbac="rbac"
        errors="validationErrors">
      </div>
    </div>
  </div>

  <h3>Metadata Purge Interval</h3>
  <div class="sub_section">
    <div class="row">
      <label for="fc68aaf1-9519-4eeb-ba28-3daa042aae22">Set the frequency of metadata purge interval:</label>
      <input
        ng-disabled="(rbac && !rbac.cluster.settings.write)"
        ng-model="autoCompactionSettings.purgeInterval"
        ng-class="{invalid: validationErrors.purgeInterval}"
        id="fc68aaf1-9519-4eeb-ba28-3daa042aae22"
        name="purgeInterval"
        style="width: 2.5em;">
{'fraction_non_alphanumeric': 0.12369921806102652, 'fraction_numerical': 0.02422247045681698, 'mean_word_length': 3.8406374501992033, 'pattern_counts': {'":': 0, '<': 187, '<?xml version=': 0, '>': 187, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1094434', 'n_tokens_mistral': 5223, 'n_tokens_neox': 4969, 'n_words': 654}