repository

package
v0.0.0-...-82c07be Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dbs

type Dbs struct {
	Neo4jDriver *neo4j.DriverWithContext
}

type OrganizationRepository

type OrganizationRepository interface {
	SuggestOrganizationsMerge(ctx context.Context, tenant, primaryOrgId, secondaryOrgId, suggestedBy, suggestedByDtls string, confidence float64) error
	OrgsAlreadyComparedForDuplicates(ctx context.Context, tenant, org1Id, org2Id string) (bool, error)
	GetOrganizationsForDedupComparison(ctx context.Context, tenant string, limit int) ([]*dbtype.Node, error)
	ExistsNewOrganizationsCreatedAfter(ctx context.Context, tenant string, after time.Time) (bool, error)
}

func NewOrganizationRepository

func NewOrganizationRepository(driver *neo4j.DriverWithContext, database string) OrganizationRepository

type Repositories

type Repositories struct {
	Dbs Dbs

	PostgresRepositories *postgresRepository.Repositories

	TenantRepository       TenantRepository
	OrganizationRepository OrganizationRepository
}

func InitRepositories

func InitRepositories(driver *neo4j.DriverWithContext, gormDb *gorm.DB, neo4jDatabase string) *Repositories

type TenantRepository

type TenantRepository interface {
	GetTenantsWithOrganizations(ctx context.Context, atLeastOrganizationsForTenant int) ([]string, error)
	GetTenantMetadata(ctx context.Context, tenantName string) (*dbtype.Node, error)
	UpdateTenantMetadataOrgDedupAt(ctx context.Context, tenantName string, time time.Time) error
}

func NewTenantRepository

func NewTenantRepository(driver *neo4j.DriverWithContext, database string) TenantRepository

Jump to

Keyboard shortcuts

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