mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-23 08:08:45 +05:00
Add AccountS in dispatcher
This commit is contained in:
committed by
Dan Christian Bogos
parent
610cf862bd
commit
42add2a12c
@@ -1313,7 +1313,21 @@ type DispatcherActionSv1 struct {
|
||||
dR *dispatchers.DispatcherService
|
||||
}
|
||||
|
||||
// Ping implements RateSv1Ping
|
||||
// Ping implements ActionSv1Ping
|
||||
func (dR *DispatcherActionSv1) Ping(args *utils.CGREventWithOpts, reply *string) error {
|
||||
return dR.dR.ActionSv1Ping(args, reply)
|
||||
}
|
||||
|
||||
func NewDispatcherAccountSv1(dps *dispatchers.DispatcherService) *DispatcherAccountSv1 {
|
||||
return &DispatcherAccountSv1{dR: dps}
|
||||
}
|
||||
|
||||
// Exports RPC from RLs
|
||||
type DispatcherAccountSv1 struct {
|
||||
dR *dispatchers.DispatcherService
|
||||
}
|
||||
|
||||
// Ping implements AccountSv1Ping
|
||||
func (dR *DispatcherAccountSv1) Ping(args *utils.CGREventWithOpts, reply *string) error {
|
||||
return dR.dR.AccountSv1Ping(args, reply)
|
||||
}
|
||||
|
||||
@@ -155,6 +155,9 @@ func (dspS *DispatcherService) Start() (err error) {
|
||||
dspS.server.RpcRegisterName(utils.ActionSv1,
|
||||
v1.NewDispatcherActionSv1(dspS.dspS))
|
||||
|
||||
dspS.server.RpcRegisterName(utils.AccountSv1,
|
||||
v1.NewDispatcherAccountSv1(dspS.dspS))
|
||||
|
||||
dspS.connChan <- dspS.anz.GetInternalCodec(dspS.dspS, utils.DispatcherS)
|
||||
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user