or is there a way to rewrite request to index.html if they don't match
another servlet path or a static file?

On Sun, Apr 24, 2016 at 12:30 PM, Rj Ewing <[email protected]> wrote:

> sorry, thinking again, having the error handler would be nice in order to
> remove false 404's with angular app and page reloads.
>
> do you know what the classcastexception might be about?
>
> On Sun, Apr 24, 2016 at 12:14 PM, Jesse McConnell <
> [email protected]> wrote:
>
>> check this out:
>> http://www.eclipse.org/jetty/documentation/current/custom-error-pages.html
>>
>> --
>> jesse mcconnell
>> [email protected]
>>
>> On Sun, Apr 24, 2016 at 2:11 PM, Rj Ewing <[email protected]> wrote:
>>
>>> I'm mainly want to use an ErrorHandler for my angular app can deal with
>>> the 404's. Is there a way to specify different error-page in web.xml for
>>> different servlets?
>>>
>>> On Sun, Apr 24, 2016 at 12:09 PM, Rj Ewing <[email protected]> wrote:
>>>
>>>> hm, when I do that, I get a ClassCastException:
>>>>
>>>> java.lang.ClassCastException: biocode.fims.rest.FimsErrorHandler cannot
>>>> be cast to org.eclipse.jetty.servlet.ErrorPageErrorHandler
>>>>
>>>> On Sun, Apr 24, 2016 at 12:03 PM, Jesse McConnell <
>>>> [email protected]> wrote:
>>>>
>>>>> no, right the first time, you need to be able to see the
>>>>> ContextHandler that and is hidden by default from the classloader
>>>>>
>>>>> anyway, give that a whirl, I didn't try it but at first blush should
>>>>> be fine
>>>>>
>>>>> --
>>>>> jesse mcconnell
>>>>> [email protected]
>>>>>
>>>>> On Sun, Apr 24, 2016 at 1:59 PM, Jesse McConnell <
>>>>> [email protected]> wrote:
>>>>>
>>>>>> oh wait, not right, that is a handler...hm.
>>>>>>
>>>>>> --
>>>>>> jesse mcconnell
>>>>>> [email protected]
>>>>>>
>>>>>> On Sun, Apr 24, 2016 at 1:56 PM, Jesse McConnell <
>>>>>> [email protected]> wrote:
>>>>>>
>>>>>>> check out
>>>>>>>
>>>>>>>
>>>>>>> http://download.eclipse.org/jetty/9.3.8.v20160314/apidocs/org/eclipse/jetty/webapp/WebAppContext.html#setParentLoaderPriority-boolean-
>>>>>>>
>>>>>>> --
>>>>>>> jesse mcconnell
>>>>>>> [email protected]
>>>>>>>
>>>>>>> On Sun, Apr 24, 2016 at 1:52 PM, Rj Ewing <[email protected]>
>>>>>>> wrote:
>>>>>>>
>>>>>>>> is there anyway to include it in the webapp? I'd rather not have to
>>>>>>>> add it to each jetty instance if possible
>>>>>>>>
>>>>>>>> On Sun, Apr 24, 2016 at 11:38 AM, Jesse McConnell <
>>>>>>>> [email protected]> wrote:
>>>>>>>>
>>>>>>>>> probably a classloader issue, if you have that class in the webapp
>>>>>>>>> you won't be able to see it from the webappclassloader itself
>>>>>>>>>
>>>>>>>>> typically those go in the server classes a la a module
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> jesse mcconnell
>>>>>>>>> [email protected]
>>>>>>>>>
>>>>>>>>> On Sun, Apr 24, 2016 at 1:01 PM, Rj Ewing <[email protected]>
>>>>>>>>> wrote:
>>>>>>>>>
>>>>>>>>>> I am trying to set a custom errorHandler for my web app, but am
>>>>>>>>>> getting a noSuchMethod Exception on WebAppContext:
>>>>>>>>>>
>>>>>>>>>> java.lang.NoSuchMethodException: class
>>>>>>>>>> org.eclipse.jetty.webapp.WebAppContext.setErrorHandler(class
>>>>>>>>>> biocode.fims.rest.FimsErrorHandler)
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> I'm using jetty 9. My jetty-env.xml looks like:
>>>>>>>>>>
>>>>>>>>>> <?xml version="1.0" encoding="UTF-8"?>
>>>>>>>>>> <!DOCTYPE Configure PUBLIC "-//Jetty//Configure//EN" "
>>>>>>>>>> http://www.eclipse.org/jetty/configure.dtd";>
>>>>>>>>>>
>>>>>>>>>> <Configure class="org.eclipse.jetty.webapp.WebAppContext">
>>>>>>>>>>     <Set name="errorHandler">
>>>>>>>>>>         <New class="biocode.fims.rest.FimsErrorHandler"/>
>>>>>>>>>>     </Set>
>>>>>>>>>> </Configure>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> When I look at
>>>>>>>>>> http://download.eclipse.org/jetty/9.3.8.v20160314/apidocs/org/eclipse/jetty/webapp/WebAppContext.html,
>>>>>>>>>> it seems that the WebAppContext should have a setErrorHandler method
>>>>>>>>>>
>>>>>>>>>> _______________________________________________
>>>>>>>>>> jetty-users mailing list
>>>>>>>>>> [email protected]
>>>>>>>>>> To change your delivery options, retrieve your password, or
>>>>>>>>>> unsubscribe from this list, visit
>>>>>>>>>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> _______________________________________________
>>>>>>>>> jetty-users mailing list
>>>>>>>>> [email protected]
>>>>>>>>> To change your delivery options, retrieve your password, or
>>>>>>>>> unsubscribe from this list, visit
>>>>>>>>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> _______________________________________________
>>>>>>>> jetty-users mailing list
>>>>>>>> [email protected]
>>>>>>>> To change your delivery options, retrieve your password, or
>>>>>>>> unsubscribe from this list, visit
>>>>>>>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> jetty-users mailing list
>>>>> [email protected]
>>>>> To change your delivery options, retrieve your password, or
>>>>> unsubscribe from this list, visit
>>>>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>>>>>
>>>>
>>>>
>>>
>>> _______________________________________________
>>> jetty-users mailing list
>>> [email protected]
>>> To change your delivery options, retrieve your password, or unsubscribe
>>> from this list, visit
>>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>>>
>>
>>
>> _______________________________________________
>> jetty-users mailing list
>> [email protected]
>> To change your delivery options, retrieve your password, or unsubscribe
>> from this list, visit
>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>>
>
>
_______________________________________________
jetty-users mailing list
[email protected]
To change your delivery options, retrieve your password, or unsubscribe from 
this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users

Reply via email to