+### v0.6.9
+* Code violations fixed in pkg/nbi/httprestful.go and pkg/nbi/control.go
+
### v0.6.8
* Appending Receiver endpoint in routes if RX message type is same
# By default this file is in the docker build directory,
# but the location can configured in the JJB template.
---
-tag: 0.6.8
+tag: 0.6.9
m.Lock()
data, err := sdlEngine.ReadAll(xapp.Config.GetString("rtfile"))
m.Unlock()
- if err != nil || data == nil {
- xapp.Logger.Error("Cannot get data from sdl interface due to: " + err.Error())
- return
- }
+ if data == nil {
+ if err != nil {
+ xapp.Logger.Error("Cannot get data from sdl interface due to: " + err.Error())
+ return
+ } else {
+ xapp.Logger.Debug("Cannot get data from sdl interface")
+ return
+ }
+ }
ep := sbiEngine.CheckEndpoint(string(params.Payload))
if ep == nil {
data, err := sdlEngine.ReadAll(xapp.Config.GetString("rtfile"))
fmt.Printf("data = %v,%v,%v",data,sdlEngine,sbiEngine)
m.Unlock()
- if err != nil || data == nil {
- return errors.New("Cannot get data from sdl interface due to: " + err.Error())
- }
+ if data == nil {
+ if err != nil {
+ return errors.New("Cannot get data from sdl interface due to: " + err.Error())
+ } else {
+ xapp.Logger.Debug("Cannot get data from sdl interface, data is null")
+ return errors.New("Cannot get data from sdl interface")
+ }
+ }
+
if sbiEngine == nil {
fmt.Printf("SBI is nil")
}
func provideXappHandleHandlerImpl(data *models.XappCallbackData) error {
if data != nil {
xapp.Logger.Debug("Received callback data")
+ return nil
}
err := validateXappCallbackData(data)
if err != nil {
sdlEngine, _ := sdl.GetSdl("file")
rpeEngine, _ := rpe.GetRpe("rmrpush")
data, err := sdlEngine.ReadAll(xapp.Config.GetString("rtfile"))
- if err != nil || data == nil {
- xapp.Logger.Error("Cannot get data from sdl interface due to: " + err.Error())
- return response, err
+ if data == nil {
+ if err != nil {
+ xapp.Logger.Error("Cannot get data from sdl interface due to: " + err.Error())
+ return response, err
+ } else {
+ xapp.Logger.Debug("Cannot get data from sdl interface")
+ return response, errors.New("Cannot get data from sdl interface")
+ }
}
response.RouteTable = *rpeEngine.GeneratePolicies(rtmgr.Eps, data)