fxmodules

package
v0.19.1015 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 25, 2026 License: AGPL-3.0 Imports: 153 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

ActionsWorkerModule provides the actions namespace worker.

View Source
var AdminDashboardAPIModule = fx.Module("admin-dashboard-api",
	fx.Provide(api.NewEndpointAudit),
	fx.Provide(api.AsAPI(api.NewAdminDashboardAPI)),
	fx.Invoke(db.DBGroupParam(func([]*gorm.DB) {})),
	fx.Invoke(api.APIGroupParam(func([]*api.API) {})),
)

AdminDashboardAPIModule provides the admin dashboard API server.

View Source
var AdminDashboardServicesModule = fx.Module("admin-dashboard-services",
	sharedServices,
	fx.Provide(psql.AsPSQLReplica(psql.NewReplica)),
)

AdminDashboardServicesModule provides services for the admin dashboard API.

AllAPIsModule provides all API servers (for running all in one process).

View Source
var AllServicesModule = fx.Module("all-services",
	sharedServices,
	fx.Provide(api.AsService(authservice.New)),
)

AllServicesModule provides all services including authservice (for dev mode).

AppsWorkerModule provides the apps namespace worker.

View Source
var AuthAPIModule = fx.Module("auth-api",
	fx.Provide(api.NewEndpointAudit),
	fx.Provide(api.AsAPI(api.NewAuthAPI)),
	fx.Invoke(db.DBGroupParam(func([]*gorm.DB) {})),
	fx.Invoke(api.APIGroupParam(func([]*api.API) {})),
)

AuthAPIModule provides the auth API server.

View Source
var AuthServicesModule = fx.Module("auth-services",
	sharedServices,
	fx.Provide(api.AsService(authservice.New)),
)

AuthServicesModule provides services for the auth API (includes authservice).

ComponentsWorkerModule provides the components namespace worker.

GeneralWorkerModule provides the general namespace worker.

HelpersModule provides all domain-specific helper functions used across different parts of the application.

View Source
var InfrastructureModule = fx.Module("infrastructure",

	fx.Provide(internal.NewConfig),
	fx.WithLogger(pkglog.NewFXLog),
	fx.Provide(log.New),
	fx.Provide(dblog.New),

	fx.Provide(func(cfg *internal.Config) *querycollector.Collector {
		if cfg.DebugEnableQueryCollector {
			return querycollector.NewCollector(5000)
		}
		return nil
	}),

	fx.Provide(psql.AsPSQL(psql.New)),
	fx.Provide(ch.AsCH(ch.New)),

	fx.Invoke(func(lc fx.Lifecycle, p queryWriterParams) {
		if p.Collector == nil {
			return
		}

		disabledTables := make(map[string]struct{})
		if p.Cfg.QueryCollectorDisabledTables != "" {
			for _, t := range strings.Split(p.Cfg.QueryCollectorDisabledTables, ",") {
				t = strings.TrimSpace(t)
				if t != "" {
					disabledTables[t] = struct{}{}
				}
			}
		}

		w := querycollector.NewWriter(querycollector.WriterConfig{
			DB:             p.CHDB,
			Logger:         p.L,
			DisabledTables: disabledTables,
		})
		p.Collector.SetWriter(w)

		lc.Append(fx.Hook{
			OnStart: func(context.Context) error {
				w.Start()
				return nil
			},
			OnStop: func(context.Context) error {
				w.Stop()
				return nil
			},
		})
	}),

	fx.Provide(blobstore.NewService),

	fx.Provide(func(cfg *internal.Config, l *zap.Logger) *filecache.FileCache {
		cache, err := filecache.New(filecache.Options{
			Dir:      cfg.TemporalBlobCacheDir,
			MaxCount: cfg.TemporalBlobCacheMaxCount,
			MaxBytes: int64(cfg.TemporalBlobCacheMaxSizeMB) * 1024 * 1024,
		})
		if err != nil {
			l.Warn("failed to create blob cache, caching disabled", zap.Error(err))
			return nil
		}
		return cache
	}),

	fx.Provide(gzip.AsGzip(gzip.New)),
	fx.Provide(largepayload.AsLargePayload(largepayload.New)),
	fx.Provide(blob.AsBlob(blob.New)),
	fx.Provide(signaldb.NewPayloadConverter),
	fx.Provide(dataconverter.New),
	fx.Provide(temporal.New),

	fx.Provide(loops.New),
	fx.Provide(salesforce.New),
	fx.Provide(github.New),
	fx.Provide(metrics.New),
	fx.Provide(propagator.New),
	fx.Provide(validator.New),
	fx.Provide(notifications.New),
	fx.Provide(terraform.New),
	fx.Provide(authz.New),
	fx.Provide(features.New),
	fx.Provide(account.New),
	fx.Provide(analytics.New),
	fx.Provide(analytics.NewTemporal),
	fx.Provide(cloudformation.NewTemplates),
	fx.Provide(arm.NewTemplates),
	fx.Provide(enqueuer.New),
	fx.Provide(queueclient.New),
	fx.Provide(emitterclient.New),
	fx.Provide(flowclient.New),
	fx.Provide(notebookclient.New),
)

InfrastructureModule provides all core infrastructure dependencies including config, logging, databases, temporal, and other shared services.

InstallsWorkerModule provides the installs namespace worker.

View Source
var InternalAPIModule = fx.Module("internal-api",
	fx.Provide(api.NewEndpointAudit),
	fx.Provide(api.AsAPI(api.NewInternalAPI)),
	fx.Invoke(db.DBGroupParam(func([]*gorm.DB) {})),
	fx.Invoke(api.APIGroupParam(func([]*api.API) {})),
)

InternalAPIModule provides the internal API server.

View Source
var InternalServicesModule = fx.Module("internal-services", sharedServices)

InternalServicesModule provides services for the internal API (excludes authservice).

MiddlewaresModule provides all HTTP middlewares used by the API services.

View Source
var OnboardingsWorkerModule = fx.Module("worker-onboardings",
	fx.Provide(worker.AsWorker(onboardingworker.New)),
)

OnboardingsWorkerModule provides the onboardings namespace worker.

OrgsWorkerModule provides the orgs namespace worker.

View Source
var PublicAPIModule = fx.Module("public-api",
	fx.Provide(api.NewEndpointAudit),
	fx.Provide(api.AsAPI(api.NewPublicAPI)),
	fx.Invoke(db.DBGroupParam(func([]*gorm.DB) {})),
	fx.Invoke(api.APIGroupParam(func([]*api.API) {})),
)

PublicAPIModule provides the public-facing API server.

View Source
var PublicServicesModule = fx.Module("public-services", sharedServices)

PublicServicesModule provides services for the public API (excludes authservice).

View Source
var RunnerAPIModule = fx.Module("runner-api",
	fx.Provide(api.NewEndpointAudit),
	fx.Provide(api.AsAPI(api.NewRunnerAPI)),
	fx.Invoke(db.DBGroupParam(func([]*gorm.DB) {})),
	fx.Invoke(api.APIGroupParam(func([]*api.API) {})),
)

RunnerAPIModule provides the runner API server.

View Source
var RunnerServicesModule = fx.Module("runner-services", sharedServices)

RunnerServicesModule provides services for the runner API (excludes authservice).

RunnersWorkerModule provides the runners namespace worker.

View Source
var ServicesModule = AllServicesModule

ServicesModule is deprecated, use API-specific modules instead. Kept for backwards compatibility.

SharedWorkflowsModule provides shared workflow activities and workflows used across multiple worker namespaces.

View Source
var SlackAPIModule = fx.Module("slack-api",
	fx.Provide(api.NewEndpointAudit),
	fx.Provide(api.AsAPI(api.NewSlackAPI)),
	fx.Invoke(db.DBGroupParam(func([]*gorm.DB) {})),
	fx.Invoke(api.APIGroupParam(func([]*api.API) {})),
)

SlackAPIModule provides the dedicated Slack-facing API server (OAuth callback, slash commands, Events API webhooks).

View Source
var SlackLibsModule = fx.Module("slack-libs",
	fx.Provide(func() *slackclient.Client {
		return slackclient.New()
	}),
	fx.Provide(func(cfg *internal.Config) (*statejwt.Encoder, error) {
		return statejwt.New(cfg.SlackStateJWTSecret)
	}),
	fx.Provide(autolink.New),
)

SlackLibsModule provides the shared Slack helper libraries (Web API client and OAuth state JWT encoder) used by the slack service package as well as the Slack-listener handlers in Phase 4.

The state-JWT encoder requires the SlackStateJWTSecret config value; in dev environments where the secret is unset, statejwt.New() returns an error and the surface that depends on it (install URL endpoint) will fail to start. That's intentional — install flows must not silently issue unsigned state values.

View Source
var SlackServicesModule = fx.Module("slack-services", sharedServices)

SlackServicesModule provides services for the dedicated Slack API.

View Source
var VCSWorkerModule = fx.Module("worker-vcs",
	fx.Provide(func(h *vcshelpers.Helpers) vcsactivities.GithubClient { return h }),
	fx.Provide(vcsactivities.New),
	fx.Provide(worker.AsWorker(vcsworker.New)),
)

VCSWorkerModule provides the vcs namespace worker.

WorkerInterceptorsModule provides interceptors for temporal workers.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL