util

package
v0.0.0-...-a92538d Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NotifyUserCountsAsync

func NotifyUserCountsAsync(ctx context.Context, pgClient pushgateway.Client, localpart string, serverName spec.ServerName, db storage.UserDatabase) error

NotifyUserCountsAsync sends notifications to a local user's notification destinations. UserDatabase lookups run synchronously, but a single goroutine is started when talking to the Push gateways. There is no way to know when the background goroutine has finished.

func StartPhoneHomeCollector

func StartPhoneHomeCollector(startTime time.Time, cfg *config.Dendrite, statsDB storage.Statistics)

Types

type PusherDevice

type PusherDevice struct {
	Device pushgateway.Device
	Pusher *api.Pusher
	URL    string
	Format string
}

func GetPushDevices

func GetPushDevices(ctx context.Context, localpart string, serverName spec.ServerName, tweaks map[string]interface{}, db storage.UserDatabase) ([]*PusherDevice, error)

GetPushDevices pushes to the configured devices of a local user.

Jump to

Keyboard shortcuts

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