aboutsummaryrefslogtreecommitdiff
path: root/juick-api
diff options
context:
space:
mode:
Diffstat (limited to 'juick-api')
-rw-r--r--juick-api/build.gradle5
-rw-r--r--juick-api/src/main/java/com/juick/api/configuration/ApiSecurityConfig.java3
-rw-r--r--juick-api/src/main/java/com/juick/api/controllers/Messages.java2
-rw-r--r--juick-api/src/main/java/com/juick/api/controllers/Notifications.java2
-rw-r--r--juick-api/src/main/java/com/juick/api/controllers/Others.java2
-rw-r--r--juick-api/src/main/java/com/juick/api/controllers/PM.java4
-rw-r--r--juick-api/src/main/java/com/juick/api/controllers/Post.java5
-rw-r--r--juick-api/src/main/java/com/juick/api/controllers/Subscriptions.java2
-rw-r--r--juick-api/src/main/java/com/juick/api/controllers/Tags.java2
-rw-r--r--juick-api/src/main/java/com/juick/api/controllers/Users.java4
10 files changed, 14 insertions, 17 deletions
diff --git a/juick-api/build.gradle b/juick-api/build.gradle
index bcf4bd25..b85bb4fc 100644
--- a/juick-api/build.gradle
+++ b/juick-api/build.gradle
@@ -9,7 +9,8 @@ apply plugin: 'war'
apply plugin: 'org.akhikhl.gretty'
dependencies {
- compile project(':juick-server')
+ compile project(':juick-server-jdbc')
+ compile project(':juick-server-web')
compile "org.springframework:spring-webmvc:${rootProject.springFrameworkVersion}"
compile "org.springframework:spring-websocket:${rootProject.springFrameworkVersion}"
@@ -19,7 +20,7 @@ dependencies {
compile 'org.imgscalr:imgscalr-lib:4.2'
providedRuntime 'mysql:mysql-connector-java:5.1.40'
- testCompile project(path: ':juick-server', configuration: 'testArtifacts')
+ testCompile project(path: ':juick-server-jdbc', configuration: 'testArtifacts')
testRuntime 'org.apache.tomcat:tomcat-websocket:8.5.15'
testRuntime 'com.jayway.jsonpath:json-path:2.2.0'
diff --git a/juick-api/src/main/java/com/juick/api/configuration/ApiSecurityConfig.java b/juick-api/src/main/java/com/juick/api/configuration/ApiSecurityConfig.java
index f1dcf30a..969ebd03 100644
--- a/juick-api/src/main/java/com/juick/api/configuration/ApiSecurityConfig.java
+++ b/juick-api/src/main/java/com/juick/api/configuration/ApiSecurityConfig.java
@@ -1,6 +1,6 @@
package com.juick.api.configuration;
-import com.juick.server.security.NotAuthorizedAuthenticationEntryPoint;
+import com.juick.service.security.NotAuthorizedAuthenticationEntryPoint;
import com.juick.service.UserService;
import com.juick.service.security.JuickUserDetailsService;
import com.juick.service.security.deprecated.RequestParamHashRememberMeServices;
@@ -8,7 +8,6 @@ import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.PropertySource;
-import org.springframework.core.env.Environment;
import org.springframework.http.HttpMethod;
import org.springframework.security.authentication.dao.DaoAuthenticationProvider;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
diff --git a/juick-api/src/main/java/com/juick/api/controllers/Messages.java b/juick-api/src/main/java/com/juick/api/controllers/Messages.java
index 76bbb5be..0d77bb74 100644
--- a/juick-api/src/main/java/com/juick/api/controllers/Messages.java
+++ b/juick-api/src/main/java/com/juick/api/controllers/Messages.java
@@ -9,7 +9,7 @@ import com.juick.server.util.HttpForbiddenException;
import com.juick.service.MessagesService;
import com.juick.service.TagService;
import com.juick.service.UserService;
-import com.juick.util.UserUtils;
+import com.juick.server.util.UserUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.http.HttpStatus;
diff --git a/juick-api/src/main/java/com/juick/api/controllers/Notifications.java b/juick-api/src/main/java/com/juick/api/controllers/Notifications.java
index 2f0dc335..c121efb6 100644
--- a/juick-api/src/main/java/com/juick/api/controllers/Notifications.java
+++ b/juick-api/src/main/java/com/juick/api/controllers/Notifications.java
@@ -9,7 +9,7 @@ import com.juick.server.util.HttpForbiddenException;
import com.juick.service.MessagesService;
import com.juick.service.PushQueriesService;
import com.juick.service.SubscriptionService;
-import com.juick.util.UserUtils;
+import com.juick.server.util.UserUtils;
import org.springframework.http.MediaType;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;
diff --git a/juick-api/src/main/java/com/juick/api/controllers/Others.java b/juick-api/src/main/java/com/juick/api/controllers/Others.java
index 722653a5..4f646af8 100644
--- a/juick-api/src/main/java/com/juick/api/controllers/Others.java
+++ b/juick-api/src/main/java/com/juick/api/controllers/Others.java
@@ -6,7 +6,7 @@ import com.juick.server.util.HttpForbiddenException;
import com.juick.server.util.HttpNotFoundException;
import com.juick.service.PMQueriesService;
import com.juick.service.UserService;
-import com.juick.util.UserUtils;
+import com.juick.server.util.UserUtils;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
diff --git a/juick-api/src/main/java/com/juick/api/controllers/PM.java b/juick-api/src/main/java/com/juick/api/controllers/PM.java
index 9faf05ea..f4bf2763 100644
--- a/juick-api/src/main/java/com/juick/api/controllers/PM.java
+++ b/juick-api/src/main/java/com/juick/api/controllers/PM.java
@@ -6,8 +6,8 @@ import com.juick.server.util.HttpBadRequestException;
import com.juick.server.util.HttpForbiddenException;
import com.juick.service.PMQueriesService;
import com.juick.service.UserService;
-import com.juick.util.UserUtils;
-import com.juick.util.WebUtils;
+import com.juick.server.util.UserUtils;
+import com.juick.server.util.WebUtils;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
diff --git a/juick-api/src/main/java/com/juick/api/controllers/Post.java b/juick-api/src/main/java/com/juick/api/controllers/Post.java
index cbd5ac0c..ffabe9ad 100644
--- a/juick-api/src/main/java/com/juick/api/controllers/Post.java
+++ b/juick-api/src/main/java/com/juick/api/controllers/Post.java
@@ -10,7 +10,7 @@ import com.juick.server.util.ImageUtils;
import com.juick.service.MessagesService;
import com.juick.service.SubscriptionService;
import com.juick.service.UserService;
-import com.juick.util.UserUtils;
+import com.juick.server.util.UserUtils;
import org.apache.commons.codec.digest.DigestUtils;
import org.apache.commons.io.IOUtils;
import org.apache.commons.lang3.StringUtils;
@@ -28,13 +28,10 @@ import rocks.xmpp.extensions.nick.model.Nickname;
import rocks.xmpp.extensions.oob.model.x.OobX;
import javax.inject.Inject;
-import javax.mail.MessagingException;
import javax.mail.Session;
import javax.mail.internet.InternetAddress;
import javax.mail.internet.MimeMessage;
import javax.servlet.http.HttpServletRequest;
-import java.io.BufferedInputStream;
-import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.net.URI;
diff --git a/juick-api/src/main/java/com/juick/api/controllers/Subscriptions.java b/juick-api/src/main/java/com/juick/api/controllers/Subscriptions.java
index fcae3373..c4a214d9 100644
--- a/juick-api/src/main/java/com/juick/api/controllers/Subscriptions.java
+++ b/juick-api/src/main/java/com/juick/api/controllers/Subscriptions.java
@@ -7,7 +7,7 @@ import com.juick.server.util.HttpForbiddenException;
import com.juick.service.MessagesService;
import com.juick.service.SubscriptionService;
import com.juick.service.UserService;
-import com.juick.util.UserUtils;
+import com.juick.server.util.UserUtils;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
diff --git a/juick-api/src/main/java/com/juick/api/controllers/Tags.java b/juick-api/src/main/java/com/juick/api/controllers/Tags.java
index 7b1ce313..ab2ee7ce 100644
--- a/juick-api/src/main/java/com/juick/api/controllers/Tags.java
+++ b/juick-api/src/main/java/com/juick/api/controllers/Tags.java
@@ -4,7 +4,7 @@ import com.juick.User;
import com.juick.server.helpers.TagStats;
import com.juick.service.TagService;
import com.juick.service.UserService;
-import com.juick.util.UserUtils;
+import com.juick.server.util.UserUtils;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
diff --git a/juick-api/src/main/java/com/juick/api/controllers/Users.java b/juick-api/src/main/java/com/juick/api/controllers/Users.java
index 3805b2ef..b84f375f 100644
--- a/juick-api/src/main/java/com/juick/api/controllers/Users.java
+++ b/juick-api/src/main/java/com/juick/api/controllers/Users.java
@@ -4,8 +4,8 @@ import com.juick.User;
import com.juick.server.util.HttpForbiddenException;
import com.juick.server.util.HttpNotFoundException;
import com.juick.service.UserService;
-import com.juick.util.UserUtils;
-import com.juick.util.WebUtils;
+import com.juick.server.util.UserUtils;
+import com.juick.server.util.WebUtils;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;