mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
Removed GetInternalChan method from Service interface
This commit is contained in:
committed by
Dan Christian Bogos
parent
f10f570a27
commit
9f8790a3d4
@@ -540,36 +540,36 @@ func main() {
|
||||
|
||||
// init internalRPCSet to share internal connections among the engine
|
||||
engine.IntRPC = engine.NewRPCClientSet()
|
||||
engine.IntRPC.AddInternalRPCClient(utils.AnalyzerSv1, anz.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.APIerSv1, apiSv1.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.APIerSv2, apiSv1.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.AttributeSv1, attrS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.AnalyzerSv1, internalAnalyzerSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.APIerSv1, internalAPIerSv1Chan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.APIerSv2, internalAPIerSv2Chan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.AttributeSv1, internalAttributeSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.CacheSv1, internalCacheSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.CDRsV1, cdrS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.CDRsV2, cdrS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.ChargerSv1, chrS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.CDRsV1, internalCDRServerChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.CDRsV2, internalCDRServerChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.ChargerSv1, internalChargerSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.GuardianSv1, internalGuardianSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.LoaderSv1, ldrs.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.ResourceSv1, reS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.Responder, rals.GetResponder().GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.SchedulerSv1, schS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.SessionSv1, smg.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.StatSv1, stS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.RouteSv1, routeS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.ThresholdSv1, tS.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.LoaderSv1, internalLoaderSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.ResourceSv1, internalResourceSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.Responder, internalResponderChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.SchedulerSv1, internalSchedulerSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.SessionSv1, internalSessionSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.StatSv1, internalStatSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.RouteSv1, internalRouteSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.ThresholdSv1, internalThresholdSChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.ServiceManagerV1, internalServeManagerChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.ConfigSv1, internalConfigChan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.CoreSv1, internalCoreSv1Chan)
|
||||
engine.IntRPC.AddInternalRPCClient(utils.RALsV1, rals.GetIntenternalChan())
|
||||
engine.IntRPC.AddInternalRPCClient(utils.RALsV1, internalRALsChan)
|
||||
|
||||
initConfigSv1(internalConfigChan, server)
|
||||
|
||||
// Serve rpc connections
|
||||
go startRpc(server, rals.GetResponder().GetIntenternalChan(), cdrS.GetIntenternalChan(),
|
||||
reS.GetIntenternalChan(), stS.GetIntenternalChan(),
|
||||
attrS.GetIntenternalChan(), chrS.GetIntenternalChan(), tS.GetIntenternalChan(),
|
||||
routeS.GetIntenternalChan(), smg.GetIntenternalChan(), anz.GetIntenternalChan(),
|
||||
dspS.GetIntenternalChan(), ldrs.GetIntenternalChan(), rals.GetIntenternalChan(),
|
||||
go startRpc(server, internalResponderChan, internalCDRServerChan,
|
||||
internalResourceSChan, internalStatSChan,
|
||||
internalAttributeSChan, internalChargerSChan, internalThresholdSChan,
|
||||
internalRouteSChan, internalSessionSChan, internalAnalyzerSChan,
|
||||
internalDispatcherSChan, internalLoaderSChan, internalRALsChan,
|
||||
internalCacheSChan, internalEEsChan, internalRateSChan, exitChan)
|
||||
<-exitChan
|
||||
|
||||
|
||||
@@ -80,11 +80,6 @@ func (anz *AnalyzerService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (anz *AnalyzerService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return anz.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (anz *AnalyzerService) Reload() (err error) {
|
||||
return // for the momment nothing to reload
|
||||
|
||||
@@ -131,11 +131,6 @@ func (apiService *APIerSv1Service) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (apiService *APIerSv1Service) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return apiService.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (apiService *APIerSv1Service) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -82,11 +82,6 @@ func (api *APIerSv2Service) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (api *APIerSv2Service) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return api.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (api *APIerSv2Service) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -28,7 +28,6 @@ import (
|
||||
"github.com/cgrates/cgrates/config"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewAsteriskAgent returns the Asterisk Agent
|
||||
@@ -77,11 +76,6 @@ func (ast *AsteriskAgent) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (ast *AsteriskAgent) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (ast *AsteriskAgent) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -91,11 +91,6 @@ func (attrS *AttributeService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (attrS *AttributeService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return attrS.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (attrS *AttributeService) Reload() (err error) {
|
||||
return // for the momment nothing to reload
|
||||
|
||||
@@ -111,11 +111,6 @@ func (cdrService *CDRServer) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (cdrService *CDRServer) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return cdrService.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (cdrService *CDRServer) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -92,11 +92,6 @@ func (chrS *ChargerService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (chrS *ChargerService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return chrS.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (chrS *ChargerService) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -25,7 +25,6 @@ import (
|
||||
"github.com/cgrates/cgrates/config"
|
||||
"github.com/cgrates/cgrates/engine"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewDataDBService returns the DataDB Service
|
||||
@@ -80,11 +79,6 @@ func (db *DataDBService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (db *DataDBService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (db *DataDBService) Reload() (err error) {
|
||||
db.Lock()
|
||||
|
||||
@@ -27,7 +27,6 @@ import (
|
||||
"github.com/cgrates/cgrates/engine"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewDiameterAgent returns the Diameter Agent
|
||||
@@ -81,11 +80,6 @@ func (da *DiameterAgent) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (da *DiameterAgent) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (da *DiameterAgent) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -148,11 +148,6 @@ func (dspS *DispatcherService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (dspS *DispatcherService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return dspS.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (dspS *DispatcherService) Reload() (err error) {
|
||||
return // for the momment nothing to reload
|
||||
|
||||
@@ -27,7 +27,6 @@ import (
|
||||
"github.com/cgrates/cgrates/engine"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewDNSAgent returns the DNS Agent
|
||||
@@ -80,12 +79,6 @@ func (dns *DNSAgent) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
// no chanel for DNSAgent
|
||||
func (dns *DNSAgent) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (dns *DNSAgent) Reload() (err error) {
|
||||
if dns.oldListen == dns.cfg.DNSAgentCfg().Listen {
|
||||
|
||||
@@ -22,7 +22,7 @@ import (
|
||||
"fmt"
|
||||
"sync"
|
||||
|
||||
"github.com/cgrates/cgrates/apier/v1"
|
||||
v1 "github.com/cgrates/cgrates/apier/v1"
|
||||
"github.com/cgrates/cgrates/config"
|
||||
"github.com/cgrates/cgrates/ees"
|
||||
"github.com/cgrates/cgrates/engine"
|
||||
@@ -62,11 +62,6 @@ type EventExporterService struct {
|
||||
rpc *v1.EventExporterSv1
|
||||
}
|
||||
|
||||
// GetIntenternalChan is deprecated and it will be removed shortly
|
||||
func (es *EventExporterService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
panic("deprecated method")
|
||||
}
|
||||
|
||||
// ServiceName returns the service name
|
||||
func (es *EventExporterService) ServiceName() string {
|
||||
return utils.EventExporterS
|
||||
|
||||
@@ -27,7 +27,6 @@ import (
|
||||
"github.com/cgrates/cgrates/ers"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewEventReaderService returns the EventReader Service
|
||||
@@ -83,11 +82,6 @@ func (erS *EventReaderService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (erS *EventReaderService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (erS *EventReaderService) Reload() (err error) {
|
||||
erS.RLock()
|
||||
|
||||
@@ -28,7 +28,6 @@ import (
|
||||
"github.com/cgrates/cgrates/config"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewFreeswitchAgent returns the Freeswitch Agent
|
||||
@@ -71,12 +70,6 @@ func (fS *FreeswitchAgent) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
// no chanel for FreeswitchAgent
|
||||
func (fS *FreeswitchAgent) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (fS *FreeswitchAgent) Reload() (err error) {
|
||||
if err = fS.Shutdown(); err != nil {
|
||||
|
||||
@@ -27,7 +27,6 @@ import (
|
||||
"github.com/cgrates/cgrates/engine"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewHTTPAgent returns the HTTP Agent
|
||||
@@ -73,11 +72,6 @@ func (ha *HTTPAgent) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (ha *HTTPAgent) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (ha *HTTPAgent) Reload() (err error) {
|
||||
return // no reload
|
||||
|
||||
@@ -29,7 +29,6 @@ import (
|
||||
"github.com/cgrates/cgrates/config"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewKamailioAgent returns the Kamailio Agent
|
||||
@@ -76,11 +75,6 @@ func (kam *KamailioAgent) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (kam *KamailioAgent) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (kam *KamailioAgent) Reload() (err error) {
|
||||
|
||||
|
||||
@@ -90,11 +90,6 @@ func (ldrs *LoaderService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (ldrs *LoaderService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return ldrs.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (ldrs *LoaderService) Reload() (err error) {
|
||||
filterS := <-ldrs.filterSChan
|
||||
|
||||
@@ -27,7 +27,6 @@ import (
|
||||
"github.com/cgrates/cgrates/engine"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewRadiusAgent returns the Radius Agent
|
||||
@@ -78,11 +77,6 @@ func (rad *RadiusAgent) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (rad *RadiusAgent) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (rad *RadiusAgent) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -95,11 +95,6 @@ func (rals *RalService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (rals *RalService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return rals.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (rals *RalService) Reload() (err error) {
|
||||
engine.SetRpSubjectPrefixMatching(rals.cfg.RalsCfg().RpSubjectPrefixMatching)
|
||||
|
||||
@@ -27,6 +27,7 @@ import (
|
||||
"github.com/cgrates/cgrates/rates"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
|
||||
//"github.com/cgrates/cgrates/apier/v1"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
@@ -60,11 +61,6 @@ type RateService struct {
|
||||
//rpc *v1.EventExporterSv1
|
||||
}
|
||||
|
||||
// GetIntenternalChan is deprecated and it will be removed shortly
|
||||
func (rs *RateService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
panic("deprecated method")
|
||||
}
|
||||
|
||||
// ServiceName returns the service name
|
||||
func (rs *RateService) ServiceName() string {
|
||||
return utils.RateS
|
||||
|
||||
@@ -94,11 +94,6 @@ func (reS *ResourceService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (reS *ResourceService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return reS.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (reS *ResourceService) Reload() (err error) {
|
||||
reS.Lock()
|
||||
|
||||
@@ -75,11 +75,6 @@ func (resp *ResponderService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (resp *ResponderService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return resp.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (resp *ResponderService) Reload() (err error) {
|
||||
resp.Lock()
|
||||
|
||||
@@ -95,11 +95,6 @@ func (routeS *RouteService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (routeS *RouteService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return routeS.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (routeS *RouteService) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -90,11 +90,6 @@ func (schS *SchedulerService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (schS *SchedulerService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return schS.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (schS *SchedulerService) Reload() (err error) {
|
||||
schS.Lock()
|
||||
|
||||
@@ -117,11 +117,6 @@ func (smg *SessionService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (smg *SessionService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return smg.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (smg *SessionService) Reload() (err error) {
|
||||
return
|
||||
|
||||
@@ -27,7 +27,6 @@ import (
|
||||
"github.com/cgrates/cgrates/engine"
|
||||
"github.com/cgrates/cgrates/servmanager"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewSIPAgent returns the sip Agent
|
||||
@@ -76,12 +75,6 @@ func (sip *SIPAgent) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
// no chanel for SIPAgent
|
||||
func (sip *SIPAgent) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (sip *SIPAgent) Reload() (err error) {
|
||||
if sip.oldListen == sip.cfg.SIPAgentCfg().Listen {
|
||||
|
||||
@@ -96,11 +96,6 @@ func (sts *StatService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (sts *StatService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return sts.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (sts *StatService) Reload() (err error) {
|
||||
sts.Lock()
|
||||
|
||||
@@ -26,7 +26,6 @@ import (
|
||||
"github.com/cgrates/cgrates/config"
|
||||
"github.com/cgrates/cgrates/engine"
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/rpcclient"
|
||||
)
|
||||
|
||||
// NewStorDBService returns the StorDB Service
|
||||
@@ -78,11 +77,6 @@ func (db *StorDBService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (db *StorDBService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (db *StorDBService) Reload() (err error) {
|
||||
db.Lock()
|
||||
|
||||
@@ -91,11 +91,6 @@ func (thrs *ThresholdService) Start() (err error) {
|
||||
return
|
||||
}
|
||||
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
func (thrs *ThresholdService) GetIntenternalChan() (conn chan rpcclient.ClientConnector) {
|
||||
return thrs.connChan
|
||||
}
|
||||
|
||||
// Reload handles the change of config
|
||||
func (thrs *ThresholdService) Reload() (err error) {
|
||||
thrs.Lock()
|
||||
|
||||
@@ -380,8 +380,6 @@ type Service interface {
|
||||
Reload() error
|
||||
// Shutdown stops the service
|
||||
Shutdown() error
|
||||
// GetIntenternalChan returns the internal connection chanel
|
||||
GetIntenternalChan() chan rpcclient.ClientConnector
|
||||
// IsRunning returns if the service is running
|
||||
IsRunning() bool
|
||||
// ShouldRun returns if the service should be running
|
||||
|
||||
Reference in New Issue
Block a user