SigNoz/signoz · error
ErrCodeUnsupported
ErrCodeUnsupported
Error message
get connection credentials is not supported
What it means
The base cloudintegration module deliberately implements the Module interface's optional account/credential operations as unsupported stubs. GetConnectionCredentials always returns this TypeUnsupported error; only provider-specific modules that embed and override it provide real credentials.
Source
Thrown at pkg/modules/cloudintegration/implcloudintegration/module.go:19
package implcloudintegration
import (
"context"
"github.com/SigNoz/signoz/pkg/errors"
"github.com/SigNoz/signoz/pkg/modules/cloudintegration"
"github.com/SigNoz/signoz/pkg/types/cloudintegrationtypes"
"github.com/SigNoz/signoz/pkg/valuer"
)
type module struct{}
func NewModule() cloudintegration.Module {
return &module{}
}
func (module *module) GetConnectionCredentials(ctx context.Context, orgID valuer.UUID, provider cloudintegrationtypes.CloudProviderType) (*cloudintegrationtypes.Credentials, error) {
return nil, errors.New(errors.TypeUnsupported, cloudintegrationtypes.ErrCodeUnsupported, "get connection credentials is not supported")
}
func (module *module) CreateAccount(ctx context.Context, account *cloudintegrationtypes.Account) error {
return errors.New(errors.TypeUnsupported, cloudintegrationtypes.ErrCodeUnsupported, "create account is not supported")
}
func (module *module) GetAccount(ctx context.Context, orgID valuer.UUID, accountID valuer.UUID, provider cloudintegrationtypes.CloudProviderType) (*cloudintegrationtypes.Account, error) {
return nil, errors.New(errors.TypeUnsupported, cloudintegrationtypes.ErrCodeUnsupported, "get account is not supported")
}
// GetConnectedAccount implements [cloudintegration.Module].
func (module *module) GetConnectedAccount(ctx context.Context, orgID valuer.UUID, accountID valuer.UUID, provider cloudintegrationtypes.CloudProviderType) (*cloudintegrationtypes.Account, error) {
return nil, errors.New(errors.TypeUnsupported, cloudintegrationtypes.ErrCodeUnsupported, "get connected account is not supported")
}
func (module *module) ListAccounts(ctx context.Context, orgID valuer.UUID, provider cloudintegrationtypes.CloudProviderType) ([]*cloudintegrationtypes.Account, error) {
return nil, errors.New(errors.TypeUnsupported, cloudintegrationtypes.ErrCodeUnsupported, "list accounts is not supported")
}View on GitHub (pinned to 5069bf80b0)
Solutions
- Resolve and use the provider-specific cloudintegration module that implements GetConnectionCredentials.
- If you are implementing a new provider module, override GetConnectionCredentials (embed the base module and provide the method).
- Feature-detect support before calling (see defense) instead of assuming every module supports it.
Example fix
// before
m := implcloudintegration.NewModule()
creds, err := m.GetConnectionCredentials(ctx, orgID, provider) // ErrCodeUnsupported
// after
type credentialsProvider interface {
GetConnectionCredentials(context.Context, valuer.UUID, cloudintegrationtypes.CloudProviderType) (*cloudintegrationtypes.Credentials, error)
}
if cp, ok := module.(credentialsProvider); ok {
creds, err = cp.GetConnectionCredentials(ctx, orgID, provider)
} Defensive patterns
Strategy: type-guard
Validate before calling
type canGetCredentials interface {
GetConnectionCredentials(context.Context, valuer.UUID, cloudintegrationtypes.CloudProviderType) (*cloudintegrationtypes.Credentials, error)
}
if _, ok := module.(canGetCredentials); !ok {
return nil, fmt.Errorf("module does not support credentials lookup")
}
creds, err := module.(canGetCredentials).GetConnectionCredentials(ctx, orgID, provider) Type guard
func supportsCredentials(m cloudintegration.Module) bool {
_, ok := m.(interface {
GetConnectionCredentials(context.Context, valuer.UUID, cloudintegrationtypes.CloudProviderType) (*cloudintegrationtypes.Credentials, error)
})
return ok && !isBaseModule(m)
} Try / catch
creds, err := module.GetConnectionCredentials(ctx, orgID, provider)
if err != nil {
if errors.Is(err, cloudintegrationtypes.ErrCodeUnsupported) {
return nil, fmt.Errorf("credentials not supported for provider %s", provider)
}
return nil, err
} Prevention
- Register provider-specific modules, never the base NewModule(), in DI for account flows.
- Treat ErrCodeUnsupported as a capability signal and degrade gracefully.
When it happens
Trigger: Calling Module.GetConnectionCredentials on the generic/base cloudintegration module (or a provider module that did not override it) instead of a concrete provider implementation (AWS/Azure/GCP etc.).
Common situations: Wiring the interface with the default NewModule() instead of the provider-specific constructor; adding a new cloud provider whose module forgot to implement credentials; DI misconfiguration resolving the base module.
Understand the failure class
Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.
Related errors
AI-assisted analysis of SigNoz/signoz@5069bf80b0 (2026-08-28).
Data as JSON: /api/errors/78e0fd9997571784.
Report an issue: GitHub.