db

package
v0.5.0 Latest Latest
Warning

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

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

README

db

Table of Contents

  1. Description
  2. Structure and Organisation
  3. Class Diagram
  4. Package Specification

Specification

Description

This package defines the local database functionality for the Device Management Service (DMS). Currently two repository structures have been implemented:

  • gorm: which is a SQlite database implementation.

  • clover: which is a NoSQL or document oriented database implementation.

Structure and Organisation

Here is quick overview of the contents of this pacakge:

  • README: Current file which is aimed towards developers who wish to use and modify the package functionality.

  • db.go: This file defines the method which opens an SQlite database at a path set by the config parameter work_dir, applies migration and returns the db instance.

  • repositories: This folder contains the sub-packages of the db package.

  • specs: This folder contains the class diagram of the package.

Class Diagram

The class diagram for the db package is shown below.

Source file

db Class diagram

Rendered from source file
!$rootUrlGitlab = "https://gitlab.com/nunet/device-management-service/-/raw/main"
!$packageRelativePath = "/db"
!$packageUrlGitlab = $rootUrlGitlab + $packageRelativePath
 
!include $packageUrlGitlab/specs/class_diagram.puml
Package Specification

Refer to the README file defined in the repositories folder for specification of the package.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConnectDatabase

func ConnectDatabase(dbPath string) (*gorm.DB, error)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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