[SDC] rebase code

Change-Id: I456ec65a233d277e6bae35e140f2e3da5765bae6
Signed-off-by: Tal Gitelman <tg851x@intl.att.com>
Signed-off-by: Michael Lando <ml636r@att.com>
diff --git a/catalog-ui/src/app/ng2/app.module.ts b/catalog-ui/src/app/ng2/app.module.ts
index ea73d38..970c57d 100644
--- a/catalog-ui/src/app/ng2/app.module.ts
+++ b/catalog-ui/src/app/ng2/app.module.ts
@@ -11,13 +11,15 @@
     StateParamsServiceFactory, CacheServiceProvider, EventListenerServiceProvider
 } from "./utils/ng1-upgraded-provider";
 import {ConfigService} from "./services/config.service";
-import {HttpService} from "./services/http.service";
 import {HttpModule} from '@angular/http';
 import {AuthenticationService} from './services/authentication.service';
 import {Cookie2Service} from "./services/cookie.service";
 import {ComponentServiceNg2} from "./services/component-services/component.service";
 import {ServiceServiceNg2} from "./services/component-services/service.service";
 import {ComponentInstanceServiceNg2} from "./services/component-instance-services/component-instance.service";
+import { InterceptorService } from 'ng2-interceptors';
+import { XHRBackend, RequestOptions } from '@angular/http';
+import {HttpInterceptor} from "./services/http.interceptor.service";
 
 export const upgradeAdapter = new UpgradeAdapter(forwardRef(() => AppModule));
 
@@ -25,6 +27,13 @@
     return () => config.loadValidationConfiguration();
 }
 
+export function interceptorFactory(xhrBackend: XHRBackend, requestOptions: RequestOptions){
+    let service = new InterceptorService(xhrBackend, requestOptions);
+      service.addInterceptor(new HttpInterceptor());
+    return service;
+}
+
+
 // export function httpServiceFactory(backend: XHRBackend, options: RequestOptions) {
 //     return new HttpService(backend, options);
 // }
@@ -43,7 +52,6 @@
     exports: [],
     entryComponents: [],
     providers: [
-        HttpService,
         DataTypesServiceProvider,
         SharingServiceProvider,
         CookieServiceProvider,
@@ -61,6 +69,11 @@
             useFactory: configServiceFactory,
             deps: [ConfigService],
             multi: true
+        },
+        {
+            provide: InterceptorService,
+            useFactory: interceptorFactory,
+            deps: [XHRBackend, RequestOptions]
         }
      ],
     bootstrap: [AppComponent]