svc

package
v0.10.6 Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2024 License: AGPL-3.0 Imports: 37 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ServiceContext

type ServiceContext struct {
	Config config.Config

	PubDev pubDev.PubDev
	PubApp pubApp.PubApp

	OssClient       *oss.Client
	TimedM          timedmanage.TimedManage
	SchemaRepo      *caches.Cache[schema.Model, string]
	SchemaManaRepo  msgThing.SchemaDataRepo
	HubLogRepo      deviceLog.HubRepo
	StatusRepo      deviceLog.StatusRepo
	SendRepo        deviceLog.SendRepo
	SDKLogRepo      deviceLog.SDKRepo
	Cache           kv.Store
	DeviceStatus    *cache.DeviceStatus
	FastEvent       *eventBus.FastEvent
	AreaM           areamanage.AreaManage
	UserM           usermanage.UserManage
	DataM           datamanage.DataManage
	ProjectM        projectmanage.ProjectManage
	ProductCache    *caches.Cache[dm.ProductInfo, string]
	DeviceCache     *caches.Cache[dm.DeviceInfo, devices.Core]
	UserDeviceShare *caches.Cache[dm.UserDeviceShareInfo, userShared.UserShareKey]
	TenantCache     sysExport.TenantCacheT
	ProjectCache    sysExport.ProjectCacheT
	AreaCache       sysExport.AreaCacheT
	WebHook         *sysExport.Webhook
	Slot            sysExport.SlotCacheT
	UserSubscribe   *ws.UserSubscribe
	GatewayCanBind  *cache.GatewayCanBind
	NodeID          int64
}

func NewServiceContext

func NewServiceContext(c config.Config) *ServiceContext

func (*ServiceContext) WithDeviceTenant

func (s *ServiceContext) WithDeviceTenant(ctx context.Context, dev devices.Core) context.Context

Jump to

Keyboard shortcuts

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