Update example-xapp
[ric-plt/xapp-frame.git] / pkg / xapp / xapp.go
old mode 100644 (file)
new mode 100755 (executable)
index 45a3564..b63c8aa
@@ -36,6 +36,8 @@ var (
        Metric        *Metrics
        Logger        *Log
        Config        Configurator
+       Subscription  *Subscriber
+       Alarm         *AlarmClient
        readyCb       ReadyCB
        readyCbParams interface{}
 )
@@ -63,6 +65,8 @@ func init() {
        Resource = NewRouter()
        Config = Configurator{}
        Metric = NewMetrics(viper.GetString("metrics.url"), viper.GetString("metrics.namespace"), Resource.router)
+       Subscription = NewSubscriber(viper.GetString("subscription.host"), viper.GetInt("subscription.timeout"))
+       Alarm = NewAlarmClient(viper.GetString("alarm.MOId"), viper.GetString("alarm.APPId"))
 
        if viper.IsSet("db.namespaces") {
                namespaces := viper.GetStringSlice("db.namespaces")