Hi,
Notice that by default cas is using spring web flow, or
SimpleUrlHandlerMapping. You have to register spring annotation based
configuration. Add bean:
    <bean 
class="org.springframework.web.servlet.mvc.annotation.DefaultAnnotationHandlerMapping"
          p:order="1"
          p:alwaysUseFullPath="true"
            >
        <property name="interceptors">
            <list>
                <ref local="localeChangeInterceptor"/>
                <ref bean="throttleInterceptor"/>
            </list>
        </property>
    </bean>
Notice 'order="1"' so this handler mapping would be used second. Use
SimpleUrlHandler as first.

Add beans to enable annotations:
    <bean 
class="org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter"/>
    <bean 
class="org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter"
        p:alwaysUseFullPath="true"/>

Hope this points you to right direction.
Best regards,
Augustyn

On 8 October 2014 at 07:38, Ravikumar S <ravikumar.sutagu...@gmail.com> wrote:
> Hi,
>
> Even I came across similar requirement. I have done the following to add a
> new controller.
> 1. Define controller bean in applicationContext.xml file providing the
> dependencies if any
>
> 2. Mention the intercept-url for the required page and mention "permit all"
> in securityContext.xml file.
>
> PS: This is done for CAS 3.5.2 version
>
> Regards,
> Ravi
>
> On Wed, Oct 8, 2014 at 9:31 AM, yn.zhangyingd...@gmail.com
> <yn.zhangyingd...@gmail.com> wrote:
>>
>> Dear all,
>>
>>
>> I used cas-server-3.5.2 and I want to add some jsp pages base on
>> cas-server-webapp by using spring mvc framwork.
>>
>>
>> now,
>>
>> 1.  I don't know how to config xml file for beans.
>>
>> my controller like:
>>
>> @Controller
>> @RequestMapping("test")
>> public class BlogController {
>>
>>
>>     @RequestMapping("hello")
>>     public String hello(Model model) {
>>
>>     ......
>>     return "test-hello"; // test-hello.jsp
>>     }
>> }
>>
>> 2. How to config filter xml file. I want to accessce jsp page by
>> controller and not be filtered by cas.
>>
>> eg. i send a request like "http://localhost:8080/cas/test/hello.html"; on
>> browser, i want to receive  test-hello.jsp as result not goto login
>>
>>
>> ________________________________
>> yn.zhangyingd...@gmail.com
>>
>> --
>> You are currently subscribed to cas-dev@lists.jasig.org as:
>> ravikumar.sutagu...@gmail.com
>> To unsubscribe, change settings or access archives, see
>> http://www.ja-sig.org/wiki/display/JSG/cas-dev
>
>
> --
> You are currently subscribed to cas-dev@lists.jasig.org as:
> augustynw...@gmail.com
> To unsubscribe, change settings or access archives, see
> http://www.ja-sig.org/wiki/display/JSG/cas-dev

-- 
You are currently subscribed to cas-dev@lists.jasig.org as: 
arch...@mail-archive.com
To unsubscribe, change settings or access archives, see 
http://www.ja-sig.org/wiki/display/JSG/cas-dev

Reply via email to