diff options
author | Vitaly Takmazov | 2018-01-30 17:51:13 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2018-01-30 17:52:10 +0300 |
commit | c41d997b1046fcc7bf04e8abb317907425bdb714 (patch) | |
tree | 7b294a83b1f8b773f95aeba4f86f701f04f6a5fc /juick-notifications | |
parent | c6f081c30b378b9b0c3210bddb653c87059e75c8 (diff) |
web: authenticate services over api
Diffstat (limited to 'juick-notifications')
-rw-r--r-- | juick-notifications/src/main/java/com/juick/components/configuration/NotificationsAppConfiguration.java | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/juick-notifications/src/main/java/com/juick/components/configuration/NotificationsAppConfiguration.java b/juick-notifications/src/main/java/com/juick/components/configuration/NotificationsAppConfiguration.java index 5cd2b3cd..67293373 100644 --- a/juick-notifications/src/main/java/com/juick/components/configuration/NotificationsAppConfiguration.java +++ b/juick-notifications/src/main/java/com/juick/components/configuration/NotificationsAppConfiguration.java @@ -29,10 +29,6 @@ import java.util.List; @Import({ APNSConfiguration.class, MPNSConfiguration.class, GCMConfiguration.class, JuickServerComponentConfiguration.class}) public class NotificationsAppConfiguration extends BaseWebConfiguration { - @Value("${api_user:juick}") - private String apiUser; - @Value("${api_password:secret}") - private String apiSecret; @Bean public JuickServerComponent juickServerComponent() { @@ -44,16 +40,6 @@ public class NotificationsAppConfiguration extends BaseWebConfiguration { } @Bean - public RestTemplate rest() { - RestTemplate rest = new RestTemplate(); - List<ClientHttpRequestInterceptor> interceptors = Collections.singletonList( - new BasicAuthorizationInterceptor(apiUser, apiSecret)); - - rest.setRequestFactory(new InterceptingClientHttpRequestFactory(rest.getRequestFactory(), interceptors)); - return rest; - } - - @Bean public Notifications push() { return new Notifications(); } |