diff options
author | Vitaly Takmazov | 2017-06-29 17:09:49 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2017-06-30 10:22:20 +0300 |
commit | c99b9350be030bfbf87829956a182753a81d07a2 (patch) | |
tree | 1485ea407aca135eee7815d93a3636ba793a0276 /juick-xmpp/src | |
parent | b75b5a3d1a3bf001923d49923dcebee95ba2327e (diff) |
MVC was not enabled in apps based on BaseWebConfiguration
Diffstat (limited to 'juick-xmpp/src')
-rw-r--r-- | juick-xmpp/src/main/java/com/juick/components/configuration/XmppAppConfiguration.java | 7 | ||||
-rw-r--r-- | juick-xmpp/src/main/java/com/juick/components/configuration/XmppInitializer.java | 6 |
2 files changed, 7 insertions, 6 deletions
diff --git a/juick-xmpp/src/main/java/com/juick/components/configuration/XmppAppConfiguration.java b/juick-xmpp/src/main/java/com/juick/components/configuration/XmppAppConfiguration.java index 956b5bce..a0cf94a2 100644 --- a/juick-xmpp/src/main/java/com/juick/components/configuration/XmppAppConfiguration.java +++ b/juick-xmpp/src/main/java/com/juick/components/configuration/XmppAppConfiguration.java @@ -8,11 +8,12 @@ import com.juick.components.XMPPConnection; import com.juick.components.XMPPServer; import com.juick.components.s2s.CleaningUp; import com.juick.components.s2s.JuickBot; -import com.juick.configuration.DataConfiguration; +import com.juick.server.configuration.BaseWebConfiguration; import org.apache.commons.lang3.BooleanUtils; import org.springframework.context.annotation.*; import org.springframework.core.env.Environment; import org.springframework.scheduling.annotation.EnableScheduling; +import org.springframework.web.servlet.config.annotation.WebMvcConfigurationSupport; import javax.inject.Inject; import java.util.concurrent.ExecutorService; @@ -21,9 +22,9 @@ import java.util.concurrent.Executors; @Configuration @ComponentScan(basePackages = {"com.juick.components.controllers"}) @PropertySource("classpath:juick.conf") -@Import(DataConfiguration.class) +@Import(BaseWebConfiguration.class) @EnableScheduling -public class XmppAppConfiguration { +public class XmppAppConfiguration extends WebMvcConfigurationSupport { @Inject private Environment env; diff --git a/juick-xmpp/src/main/java/com/juick/components/configuration/XmppInitializer.java b/juick-xmpp/src/main/java/com/juick/components/configuration/XmppInitializer.java index b7c096db..c3c98f41 100644 --- a/juick-xmpp/src/main/java/com/juick/components/configuration/XmppInitializer.java +++ b/juick-xmpp/src/main/java/com/juick/components/configuration/XmppInitializer.java @@ -1,6 +1,6 @@ package com.juick.components.configuration; -import com.juick.server.configuration.BaseWebConfiguration; +import com.juick.configuration.DataConfiguration; import org.apache.commons.codec.CharEncoding; import org.springframework.web.filter.CharacterEncodingFilter; import org.springframework.web.servlet.support.AbstractAnnotationConfigDispatcherServletInitializer; @@ -14,12 +14,12 @@ public class XmppInitializer extends AbstractAnnotationConfigDispatcherServletIn @Override protected Class<?>[] getRootConfigClasses() { - return new Class<?>[]{XmppAppConfiguration.class}; + return new Class<?>[]{DataConfiguration.class}; } @Override protected Class<?>[] getServletConfigClasses() { - return new Class<?>[]{ BaseWebConfiguration.class}; + return new Class<?>[]{ XmppAppConfiguration.class}; } @Override |