<@U04S8PLJWMT> Issue: When creating a new source, ...
# ask-ai
m
@kapa.ai Issue: When creating a new source, Airbyte (v2.0.1) is able to create secrets in AWS Secrets Manager but cannot read them back. Error:
WARN    i.a.c.s.p.AwsSecretsManagerClient$DefaultImpls(getSecret):203 - Secret airbyte_workspace_00000000-0000-0000-0000-000000000000_secret_e97b6402-2192-4c72-af0d-6b34f5f61398_v1 not found
values.yaml:
Copy code
secretsManager:
    enabled: true
    type: AWS_SECRET_MANAGER
    secretName: airbyte-config-secrets
    awsSecretManager:
      region: eu-west-2
      authenticationType: instanceProfile
k
Based on the knowledge sources, this appears to be a known issue with AWS Secrets Manager integration in Airbyte. The problem is related to how Airbyte handles secret versioning. ## The Issue When Airbyte creates secrets in AWS Secrets Manager, it adds a version suffix (like
_v1
) to the secret ID internally. However, the actual secret stored in AWS Secrets Manager doesn't include this suffix. When Airbyte tries to read the secret back, it looks for the version with the
_v1
suffix, which doesn't exist in AWS Secrets Manager. This is documented in [this GitHub issue](https://github.com/airbytehq/airbyte/issues/46097), which explains: > "the version suffix that Airbyte adds to the ids -- e.g.
<secret-id-base>_v1/v2/etc
is not respected when writing to AWS Secrets Manager, so none of the secrets are versioned properly." There's also a similar report in [this issue](https://github.com/airbytehq/airbyte/issues/46328) about the Facebook Marketing connector experiencing the same problem. ## Potential Solutions 1. Verify your configuration: Ensure your
secretsManager
configuration is complete. According to [this resolved issue](https://github.com/airbytehq/airbyte/issues/60915), missing configuration can cause similar problems. Your configuration looks correct, but double-check that the IAM role has proper permissions to both read and write to AWS Secrets Manager. 2. Check IAM permissions: Since you're using
instanceProfile
authentication, ensure the EC2 instance or EKS node has an IAM role with the following permissions: -
secretsmanager:CreateSecret
-
secretsmanager:GetSecretValue
-
secretsmanager:PutSecretValue
-
secretsmanager:DeleteSecret
3. Report the issue: Since this appears to be a bug in how Airbyte handles secret versioning with AWS Secrets Manager, you may want to report this on the [Airbyte GitHub repository](https://github.com/airbytehq/airbyte/issues) if it hasn't been addressed in version 2.0.1. Unfortunately, the knowledge sources don't provide a definitive workaround for this specific versioning issue in your version of Airbyte.
m
@kapa.ai When I look in AWS console, the secrets being created have the
_v1
suffix. From the logs, Airbyte searches for a secret with the
_v1
suffix as well as one without, but cannot find either.
k
A message from kapa.ai
Thank you for that clarification. This changes the diagnosis - if AWS Secrets Manager shows the secrets with the
_v1
suffix, but Airbyte still cannot find them, this suggests a different issue than the versioning problem I initially mentioned. ## Possible Causes Based on the knowledge sources, here are the most likely issues: ### 1. IAM Permission Issues Since you're using
instanceProfile
authentication, the most common cause is insufficient IAM permissions. According to the [AWS Secrets Manager configuration documentation](https://docs.airbyte.com/platform/deploying-airbyte/integrations/secrets#values), ensure your IAM role has: -
secretsmanager:GetSecretValue
- to read secrets -
secretsmanager:CreateSecret
- to create secrets -
secretsmanager:PutSecretValue
- to update secrets -
secretsmanager:DescribeSecret
- to check if secrets exist The error message suggests Airbyte can create the secret but cannot retrieve it, which points to a permission issue with
GetSecretValue
. ### 2. Region Mismatch Verify that: - The secrets are being created in the
eu-west-2
region (as specified in your config) - The IAM role permissions are scoped to the correct region - There are no region-specific restrictions in your IAM policy ### 3. Workspace ID Issue The secret coordinate shows
00000000-0000-0000-0000-000000000000
as the workspace ID. According to the [secrets documentation](https://docs.airbyte.com/platform/understanding-airbyte/secrets), this special workspace ID is used for ephemeral secrets created during operations like "Discover" or "Check" that aren't associated with a specific workspace. These secrets are supposed to expire after 2 hours. This might indicate that the source creation process is failing at the connection check stage, before the actual workspace-specific secrets are created. ## Troubleshooting Steps 1. Check IAM permissions: Review the IAM role attached to your EKS nodes/EC2 instances and ensure it has all required Secrets Manager permissions 2. Verify region: Confirm the secrets are in
eu-west-2
and your IAM policy allows access to that region 3. Check CloudTrail logs: Look for any
AccessDenied
errors when Airbyte tries to call
GetSecretValue
4. Test manually: Try to retrieve the secret using AWS CLI from the same environment where Airbyte is running to verify permissions work If none of these resolve the issue, the knowledge sources don't provide additional specific troubleshooting steps for this scenario.
m
@kapa.ai I verified all of the troubleshooting steps from above. It seems that the failure is occurring during a check command. The error message on the front end is
Failed to save Chargebee due to the following error: Failed to fetch
, however the request has no response data.
k
A message from kapa.ai
Based on the knowledge sources and your description, this appears to be a failure during the Chargebee connector's
check
command, which validates the connection before saving the source configuration. ## Understanding the Check Command According to the [Airbyte Protocol documentation](https://docs.airbyte.com/platform/understanding-airbyte/airbyte-protocol#common-interface), the
check
command validates that a connector can connect and access all required resources. The expected behavior is: - Success: Returns a success response if the connection works - Config error: Returns a failed response with an error message if there's a configuration issue (like incorrect credentials) - Connector error: Outputs a trace message if there's a connector-level failure The error message "Failed to fetch" with no response data suggests the check operation is failing before it can return a proper status. ## Chargebee-Specific Issues Based on the knowledge sources, there are a few known issues with the Chargebee connector: ### 1. Site Configuration Error According to [this forum post](https://discuss.airbyte.io/t/203), a common Chargebee connection failure occurs when the site configuration is incorrect. The error in that case showed: >
ConnectionError(MaxRetryError("HTTPSConnectionPool(host='https', port=443): Max retries exceeded...
Verify: In your Chargebee source configuration, ensure you're entering only the site prefix (e.g.,
aivhub1-test
) and not the full URL (e.g.,
https://aivhub1-test.chargebee.com
). ### 2. Product Catalog Version The [Chargebee connector documentation](https://docs.airbyte.com/integrations/sources/chargebee) mentions that the connector needs to know which Product Catalog version your Chargebee site uses (1.0 or 2.0). According to the [error handling documentation](https://docs.airbyte.com/platform/connector-development/connector-builder-ui/error-handling#response-filters), the Chargebee connector has response filters that check for messages like: >
"This API operation is not enabled for this site"
This error occurs when using an unsupported API version for certain endpoints. ## Troubleshooting Steps 1. Verify Site Configuration: Ensure you're using only the site prefix, not the full URL 2. Check Product Catalog Version: Confirm you've selected the correct Product Catalog version (1.0 or 2.0) for your Chargebee site 3. Verify API Key: Ensure your [Chargebee API key](https://apidocs.chargebee.com/docs/api/auth) has the necessary permissions 4. Check Airbyte Logs: Look at the
source-chargebee-check
pod logs for more detailed error information about what's failing during the check operation Unfortunately, the knowledge sources don't provide specific information about how the AWS Secrets Manager issue might be causing the "Failed to fetch" error during the check command. If the secrets are being created but not read properly, this could prevent the check command from accessing the API key needed to validate the Chargebee connection.