Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: UpdateNbIdentity -> UpdateNbIdentities

RanListManager

  • An optimization suggestion (APPROVED) - instead managing a list of []*NbIdentity, manage a map of [string]*NbIdentity, where key is inventoryName and value is the nbIdentity.


Code Block
titleRanListManager
type RanListManager struct {
	rnibDataService services.RNibDataService
	mux sync.Mutex
	nbIdentityListnbIdentityMap map[string]*NbIdentity
}

type IRanListManager interface {
	InitNbIdentityListInitNbIdentityMap() error
	AddNbIdentity(nodeType entities.Node_Type, nbIdentity *entities.NbIdentity) error
	UpdateNbIdentityUpdateNbIdentityConnectionStatus(nodeType entities.Node_Type, ranName string, nbIdentityconnectionStatus *entities.NbIdentityConnectionStatus) error
	DeleteNbIdentityRemoveNbIdentity(nodeType entities.Node_Type, nbIdentity *entities.NbIdentityranName string) error
	GetNbIdentityList() []*entities.NbIdentity
}

InitNbIdentityList


Info

...

  • Triggered on application init,

...

  • fetches nb identity list from DB and populate nbIdentityMap data member.
  • rnib error → os.Exit(1)


Image Added

AddNbIdentity

...


Info

SaveNodeb Calls will be followed by a ranListManager.AddNbIdentity(nodeType, nbIdentity) call

...

UpdateNbIdentity

...

.

AFFECTED FLOWS

  • Add Enb REST API
  • E2 Setup Request coming from NW

Image Added


Add Enb REST API

Image Added

E2 Setup Request coming from NW

Image Added

UpdateNbIdentityConnectionStatus


Info
  • Affects the call to RanStateChangeManager.ChangeStatus in the following flows: Lost Connection | E2T Init | E2T Shutdown | E2 Setup | Red Button 
  • Does not affect Update Enb since it's always DISCONNECTED


Image Added


RanStateChangeManager

Image Added


RemoveNbIdentity


Info
  • RemoveEnb call will be followed by ranListManager.

...

  • RemoveNbIdentity(nodeType, nbIdentity) call

...

  • Currently, there

...

  • 's no RemoveGnb method (there's only RemoveServedNrCells)

AFFECTED FLOWS

  • Delete Enb REST API

Image Added

Delete ENB REST API

Image Added removeServedNrCells)

GetNbIdentityList

  • Returns the in-memory nbIdentity list (iterate map values and append to a []*NbIdentity slice)
  • Affected flows: Get Nodeb Ids REST API & Red Button

Get Nodeb States REST API

  • Change url from /v1/nodeb/ids to /v1/nodeb/states
  • Add ConnectionStatus property to NbIdentity proto (already pushed)
  • Get nbIdentity list from memory instead of DB


Image Added


Red Button REST API

  • Similarly, get nbIdentity list from memory instead of DB

Image Added- getListNodebIds calls:
- delete_all_request_handler
- get_nodeb_id_list_request_handler
- every getListNodebIds call will be replaced by an in-memory call - ranListManager.GetNbIdentityList()

RnibWriter Changes

Modify

We shall modify the following methods:

  • SaveNodeb(nbIdentity *entities.NbIdentity, nodebInfo *entities.NodebInfo) error
    • Change signature to: SaveNodeb(nbIdentity *entities.NbIdentity, nodebInfo *entities.NodebInfo) error
    • Modify implementation:
      • Remove UNKNOWN nodeType handling (reason: setup is now deterministic)
      • Remove save nbIdentity code - it would be called sequentially externally

  • RemoveEnb(nodebInfo *entities.NodebInfo) error
    • Modify implementation:
      • Delete remove nbIdentity code - it would be called sequentially externally

Add

Code Block
AddNbIdentity(nodeType entities.Node_Type, nbIdentity *entities.NbIdentity) error

...


UpdateNbIdentities(nodeType entities.Node_Type,

...

 oldNbIdentities []*entities.NbIdentity, newNbIdentities []*entities.NbIdentity) error

...


RemoveNbIdentity(nodeType entities.Node_Type, nbIdentity *entities.NbIdentity) error

RnibReader Changes

Modify

We shall modify the following methods:

  • GetListNodebIds() ([]*entities.NbIdentity, error)
    • Remove UNKNOWN nodeType handling (reason: setup is now deterministic)


Optimization suggestions