aboutsummaryrefslogtreecommitdiff
path: root/juick-notifications/src/main/java/com
diff options
context:
space:
mode:
Diffstat (limited to 'juick-notifications/src/main/java/com')
-rw-r--r--juick-notifications/src/main/java/com/juick/components/Notifications.java (renamed from juick-notifications/src/main/java/com/juick/notifications/CloudNotifications.java)8
-rw-r--r--juick-notifications/src/main/java/com/juick/components/configuration/NotificationsConfiguration.java (renamed from juick-notifications/src/main/java/com/juick/notifications/configuration/NotificationsConfiguration.java)8
-rw-r--r--juick-notifications/src/main/java/com/juick/components/configuration/NotificationsInitializer.java (renamed from juick-notifications/src/main/java/com/juick/notifications/configuration/NotificationsInitializer.java)2
-rw-r--r--juick-notifications/src/main/java/com/juick/components/controllers/StatusController.java (renamed from juick-notifications/src/main/java/com/juick/notifications/controllers/StatusController.java)8
-rw-r--r--juick-notifications/src/main/java/com/juick/notifications/api/Status.java19
5 files changed, 13 insertions, 32 deletions
diff --git a/juick-notifications/src/main/java/com/juick/notifications/CloudNotifications.java b/juick-notifications/src/main/java/com/juick/components/Notifications.java
index e108ec03..8cf5d5da 100644
--- a/juick-notifications/src/main/java/com/juick/notifications/CloudNotifications.java
+++ b/juick-notifications/src/main/java/com/juick/components/Notifications.java
@@ -15,7 +15,7 @@
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-package com.juick.notifications;
+package com.juick.components;
import com.google.android.gcm.server.*;
import com.juick.json.MessageSerializer;
@@ -63,9 +63,9 @@ import java.util.logging.Logger;
* @author Ugnich Anton
*/
@Component
-public class CloudNotifications implements DisposableBean, Stream.StreamListener, MessageListener {
+public class Notifications implements DisposableBean, Stream.StreamListener, MessageListener {
- private static Logger logger = Logger.getLogger(CloudNotifications.class.getName());
+ private static Logger logger = Logger.getLogger(Notifications.class.getName());
String wns_application_sip;
String wns_client_secret;
@@ -77,7 +77,7 @@ public class CloudNotifications implements DisposableBean, Stream.StreamListener
ExecutorService service;
@Inject
- public CloudNotifications(Environment env, ExecutorService service) {
+ public Notifications(Environment env, ExecutorService service) {
this.service = service;
logger.info("component initialized");
wns_application_sip = env.getProperty("wns_application_sip", "");
diff --git a/juick-notifications/src/main/java/com/juick/notifications/configuration/NotificationsConfiguration.java b/juick-notifications/src/main/java/com/juick/components/configuration/NotificationsConfiguration.java
index fd122724..64d01a36 100644
--- a/juick-notifications/src/main/java/com/juick/notifications/configuration/NotificationsConfiguration.java
+++ b/juick-notifications/src/main/java/com/juick/components/configuration/NotificationsConfiguration.java
@@ -1,8 +1,8 @@
-package com.juick.notifications.configuration;
+package com.juick.components.configuration;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.datatype.jdk8.Jdk8Module;
-import com.juick.notifications.CloudNotifications;
+import com.juick.components.Notifications;
import com.mitchellbosecke.pebble.PebbleEngine;
import com.mitchellbosecke.pebble.loader.Loader;
import com.mitchellbosecke.pebble.loader.ServletLoader;
@@ -74,8 +74,8 @@ public class NotificationsConfiguration extends WebMvcConfigurationSupport {
return viewResolver;
}
@Bean
- public CloudNotifications push() {
- return new CloudNotifications(env, service);
+ public Notifications push() {
+ return new Notifications(env, service);
}
@Bean
public ExecutorService service() {
diff --git a/juick-notifications/src/main/java/com/juick/notifications/configuration/NotificationsInitializer.java b/juick-notifications/src/main/java/com/juick/components/configuration/NotificationsInitializer.java
index cd547138..1449a4f8 100644
--- a/juick-notifications/src/main/java/com/juick/notifications/configuration/NotificationsInitializer.java
+++ b/juick-notifications/src/main/java/com/juick/components/configuration/NotificationsInitializer.java
@@ -1,4 +1,4 @@
-package com.juick.notifications.configuration;
+package com.juick.components.configuration;
import org.springframework.web.filter.CharacterEncodingFilter;
import org.springframework.web.servlet.support.AbstractAnnotationConfigDispatcherServletInitializer;
diff --git a/juick-notifications/src/main/java/com/juick/notifications/controllers/StatusController.java b/juick-notifications/src/main/java/com/juick/components/controllers/StatusController.java
index 41f44a35..50d73de6 100644
--- a/juick-notifications/src/main/java/com/juick/notifications/controllers/StatusController.java
+++ b/juick-notifications/src/main/java/com/juick/components/controllers/StatusController.java
@@ -1,7 +1,7 @@
-package com.juick.notifications.controllers;
+package com.juick.components.controllers;
-import com.juick.notifications.CloudNotifications;
-import com.juick.notifications.api.Status;
+import com.juick.components.Notifications;
+import com.juick.server.helpers.Status;
import org.springframework.http.MediaType;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@@ -17,7 +17,7 @@ import javax.inject.Inject;
@ResponseBody
public class StatusController {
@Inject
- CloudNotifications push;
+ Notifications push;
@RequestMapping(method = RequestMethod.GET, value = "/", produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
public Status status() {
diff --git a/juick-notifications/src/main/java/com/juick/notifications/api/Status.java b/juick-notifications/src/main/java/com/juick/notifications/api/Status.java
deleted file mode 100644
index dcdc0ccd..00000000
--- a/juick-notifications/src/main/java/com/juick/notifications/api/Status.java
+++ /dev/null
@@ -1,19 +0,0 @@
-package com.juick.notifications.api;
-
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/**
- * Created by vitalyster on 25.07.2016.
- */
-public class Status {
- private String value;
-
- public Status(String value) {
- this.value = value;
- }
-
- @JsonProperty("status")
- public String getValue() {
- return value;
- }
-}