> I notice merb-core has an exception defined as SwitchingProtocols > which returns a 101 status. I don't it being used anywhere. Would > something like this be appropriate for when I need to redirect from > http to https?
merb-core has exceptions defined for all of the HTTP status codes, but I wouldn't use a 101 for HTTP->HTTPS. From the RFC: > The server understands and is willing to comply with the client's > request, via the Upgrade message header field (section 14.41), for a > change in the application protocol being used on this connection. > The server will switch protocols to those defined by the response's > Upgrade header field immediately after the empty line which > terminates the 101 response. > > The protocol should only be switched when it is advantageous to do > so. For example, switching to a newer version of HTTP is > advantageous over older versions, and switching to a real-time, > synchronous protocol may be advantageous when delivering resources > that use such features. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "merb" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/merb?hl=en -~----------~----~----~----~------~----~------~--~---
