Closed nosalan closed 2 months ago
@nosalan If the labelFilter
is absent in the selectors, the key-values/featureFlags with no label
are selected. You didn't see tenant2/conf-key1
since its label is xda
, the same for feature flag.
You just need to specify the label in selector:
apiVersion: azconfig.io/v1
kind: AzureAppConfigurationProvider
metadata:
annotations:
meta.helm.sh/release-name: test-app
meta.helm.sh/release-namespace: test-app
labels:
app.kubernetes.io/managed-by: Helm
name: appconfigurationprovider-sample
namespace: test-app
spec:
auth:
workloadIdentity:
managedIdentityClientId: <REDACTED>
configuration:
selectors:
- keyFilter: '*'
- keyFilter: '*'
labelFilter: xda
endpoint: https://<REDACTED>.azconfig.io
featureFlag:
refresh:
enabled: true
interval: 30s
selectors:
- keyFilter: '*'
labelFilter: 'my -lab'
replicaDiscoveryEnabled: true
target:
configMapData:
key: mysettings.json
type: json
configMapName: configmap-created-by-appconfig-provider
Thanks for suggestion @RichardChen820 I need to download all settings regardless of label, so this is what I tried. But it still doesn't work.
apiVersion: azconfig.io/v1
kind: AzureAppConfigurationProvider
metadata:
name: appconfigurationprovider-sample
spec:
endpoint: https://<REDACTED>.azconfig.io
configuration:
selectors:
- keyFilter: "*"
labelFilter: "*"
featureFlag:
selectors:
- keyFilter: '*'
labelFilter: "*"
refresh:
enabled: true
target:
configMapName: configmap-created-by-appconfig-provider
configMapData:
type: json
key: mysettings.json
auth:
workloadIdentity:
managedIdentityClientId: <REDACTED>
@nosalan Wildcard in labelFilter
is not supported, this is by design since label is not designed to be used in this way, I would recommend you using the label to group the relevant configurations with intention rather than blindly select all labels. You can take the best practice as a reference.
This design is for getting deterministic results, configurations are key-values that are non-ordered data. If there are key-values have the same key but with different labels, selecting all labels would cause non-deterministic result, can't ensure the overlap sequence.
I understand it now. I thought that the label is atag but instead it's a namespace. And you cannot download values for all labels also you cannot modify the label value.
Problem description
In my Azure App Configuration I have 2 configuration entries and 1 feature flag. However, I can only see 1 configuration entry in the Config Map created by the Azure App Configuration Kubernetes Provider. Deleting the Config Map doesn't help.
Steps to reproduce
Additional information
Version:![image](https://github.com/Azure/AppConfiguration-KubernetesProvider/assets/2273250/7e731111-1c0e-4691-b4c3-c04f366d3e9a)
kubernetes-provider:1.3.1
Describe CRD output (Status):