spring mvc No bean named 'springSecurityFilterChain' is defined
<p>I am using spring 4.2.1.RELEASE and jdk1.8.0_65. 
I can't deploy my spring mvc project to tomcat8. 
(the "server" is a raspberry pi 3 with Apache Tomcat/8.0.14 (Debian) )</p>

<p>On my dev machine with windows and spring boot everything works fine. I can start my warfile from commandline.
I don't need any user login. Everyone should have access to all pages without any authentication. I've searched a lot but I wasn't able to get the project running.</p>

<p>After deployment to tomcat8 I get the following ExceptioN:</p>

<pre><code>org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'springSecurityFilterChain' is defined
</code></pre>

<p>My WebSecurityConfigureAdapter:</p>

<pre><code>@Configuration
@EnableWebSecurity
@EnableGlobalMethodSecurity

public class WebSecurityConfiguration extends WebSecurityConfigurerAdapter {

    protected static final org.apache.logging.log4j.Logger log = org.apache.logging.log4j.LogManager.getLogger(new Log4j2DynamicBinder().getCurrentClass());

    static {
        log.debug("WebSecurityConfiguration initialized.");
    }

    @Override
    protected void configure(HttpSecurity security) throws Exception {
        security.csrf().disable()
                .authorizeRequests()
                .antMatchers("/*").permitAll();
    }

    @Override
    public void configure(WebSecurity security) throws Exception {
        security.ignoring()
                .antMatchers(WebMVCConfig.RESOURCE_HANDLERS.keySet().toArray(new String[0]));
     }

    @Autowired
    public void configureGlobal(AuthenticationManagerBuilder auth) throws Exception { 
        auth.inMemoryAuthentication().withUser("timmy").password("timmy").authorities("USER");
    }

    @Bean
    public FilterChainProxy springSecurityFilterChain() throws Exception {
        log.debug("springSecurityFilterChain called!");
        return new FilterChainProxy(new DefaultSecurityFilterChain(new AntPathRequestMatcher("/**")));
    }
}
</code></pre>

<p>When I start the project from commandline on the ubuntu machine, everything works.. I am sure that this class gets initialized:</p>

<pre><code>2016-10-25 14:46:13.001 DEBUG 53128 --- [main] (  c.o.s.s.WebSecurityConfiguration:35 ) : WebSecurityConfiguration initialized.
....
2016-10-25 14:46:15.008 DEBUG  --- [ost-startStop-1] (  c.o.s.s.WebSecurityConfiguration:65 ) : springSecurityFilterChain called!
2016-10-25 14:46:15.015  INFO 53128 --- [ost-startStop-1] o.s.s.web.DefaultSecurityFilterChain     : Creating filter chain: Ant [pattern='/**'], []
2016-10-25 14:46:15.194  INFO 53128 --- [ost-startStop-1] o.s.b.c.embedded.FilterRegistrationBean  : Mapping filter: 'metricFilter' to: [/*]
2016-10-25 14:46:15.194  INFO 53128 --- [ost-startStop-1] o.s.b.c.embedded.FilterRegistrationBean  : Mapping filter: 'characterEncodingFilter' to: [/*]
2016-10-25 14:46:15.196  INFO 53128 --- [ost-startStop-1] o.s.b.c.embedded.FilterRegistrationBean  : Mapping filter: 'springSecurityFilterChain' to: [/*]
2016-10-25 14:46:15.197  INFO 53128 --- [ost-startStop-1] o.s.b.c.embedded.FilterRegistrationBean  : Mapping filter: 'webRequestLoggingFilter' to: [/*]
2016-10-25 14:46:15.201  INFO 53128 --- [ost-startStop-1] o.s.b.c.embedded.FilterRegistrationBean  : Mapping filter: 'applicationContextIdFilter' to: [/*]
</code></pre>

<p>I will appreciate any help :) Thanks!</p>

<p>@Edit: Stacktrace: </p>

<pre><code>   org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'springSecurityFilterChain' is defined
    org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanDefinition(DefaultListableBeanFactory.java:698)
    org.springframework.beans.factory.support.AbstractBeanFactory.getMergedLocalBeanDefinition(AbstractBeanFactory.java:1174)
    org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:283)
    org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:201)
    org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1051)
    org.springframework.web.filter.DelegatingFilterProxy.initDelegate(DelegatingFilterProxy.java:326)
    org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:255)
</code></pre>

<p>@Edit2: Stacktrace from logfiles:</p>

<pre><code>    25-Oct-2016 13:14:16.380 SEVERE [http-nio-8080-exec-64] org.apache.catalina.core.StandardWrapperValve.invoke Servlet.service() for servlet [SpringMVCDispatcher] in context with path [/server-1.0] threw exception
 org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'springSecurityFilterChain' is defined
        at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanDefinition(DefaultListableBeanFactory.java:698)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getMergedLocalBeanDefinition(AbstractBeanFactory.java:1174)
        at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:283)
        at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:201)
        at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1051)
        at org.springframework.web.filter.DelegatingFilterProxy.initDelegate(DelegatingFilterProxy.java:326)
        at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:255)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:506)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:142)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
        at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:610)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:537)
        at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1081)
        at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:658)
        at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:222)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1566)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1523)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:745)
</code></pre>

<p>@Edit3: Moved Bean into new class and added @Configuration annotation:
Same error on production system... 
When I start the app from the commandline, I am receiving replacement messages..</p>

<pre><code>@Configuration
public class DedicatedConfigs {
    @Bean
    public FilterChainProxy springSecurityFilterChain() throws Exception {
        return new FilterChainProxy(new DefaultSecurityFilterChain(new AntPathRequestMatcher("/**")));
    }
}
</code></pre>