### Elasticsearch Version

7.17, 8.x

### Installed Plugins

_No response_

### Java Version

_bundled_

### OS Version

Darwin

### Problem Description

The migrate to data tiers API can sometimes configure an illegal value for the `_tier_preference` setting for partially mounted indices.
This can happen if two conditions are met: 
1. if the partially mounted index doesn't have a `_tier_preference` configured
2. if the migrate to data tiers API doesn't perform any migration for this index (e.g. say this partially mounted index doesn't use the `data` custom attribute name for any allocation filtering, but either uses some other node attribute name or none at all)

In this case this piece of code kicks in to configure a default tier preference https://github.com/elastic/elasticsearch/blob/main/x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/cluster/metadata/MetadataMigrateToDataTiersRoutingService.java#L534

This is wrong, and we should configure the `MountSearchableSnapshotRequest.Storage.defaultDataTiersPreference` as the tier preference.

Relates to https://github.com/elastic/elasticsearch/issues/84758

### Steps to Reproduce

1. Mount an index - `partial-test`
2. Remove the `_tier_preference` using
```
PUT partial-test/_settings
{
  "index.routing.allocation.include._tier_preference": null
}
```
3. Call the migrate to data tiers routing API 
```
POST /_ilm/migrate_to_data_tiers
```

### Logs (if relevant)

_No response_
x-pack/plugin/ilm/src/main/java/org/elasticsearch/xpack/cluster/metadata/MetadataMigrateToDataTiersRoutingService.java
finalSettings.remove(nodeAttrIndexExcludeRoutingSetting);
                    finalSettings.remove(nodeAttrIndexRequireRoutingSetting);
                    finalSettings.remove(nodeAttrIndexIncludeRoutingSetting);
                }
                mb.put(
                    IndexMetadata.builder(indexMetadata).settings(finalSettings).settingsVersion(indexMetadata.getSettingsVersion() + 1)
                );
                migratedIndices.add(indexMetadata.getIndex().getName());
            }
        }
        return migratedIndices;
    }
    /**
     * Attempts to migrate the value of the given attribute routing setting to the _tier_preference equivalent. The provided setting
     * needs to be configured and have one of the supported values (hot, warm, cold, or frozen) in order for the migration to be performed.
     * If the migration is successful the provided setting will be removed.
     *
     * If the migration is **not** executed the current index settings is returned, otherwise the updated settings are returned
     */
    private static Settings maybeMigrateRoutingSettingToTierPreference(
        String attributeBasedRoutingSettingName,
        Settings currentIndexSettings,
        String indexName
    ) {
        if (currentIndexSettings.keySet().contains(attributeBasedRoutingSettingName) == false) {
            return currentIndexSettings;
        }
        Settings.Builder newSettingsBuilder = Settings.builder().put(currentIndexSettings);
        
        if (currentIndexSettings.keySet().contains(TIER_PREFERENCE)) {