abdera-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Elliot Metsger (JIRA)" <j...@apache.org>
Subject [jira] Created: (ABDERA-271) ServletRequestContext.initBaseUri(...) appends the webapp context path
Date Wed, 17 Nov 2010 20:06:13 GMT
ServletRequestContext.initBaseUri(...) appends the webapp context path

                 Key: ABDERA-271
                 URL: https://issues.apache.org/jira/browse/ABDERA-271
             Project: Abdera
          Issue Type: Bug
    Affects Versions: 1.0
            Reporter: Elliot Metsger

I may be mis-interpreting, but according to RequestContext's {{getBaseUri()}} method should
not include the webapp context path:

   * Get the absolute base URI ... this is the request URI up to the Context 
   * Path of the web application within which the Abdera Servlet is deployed
  IRI getBaseUri();

Yet in the {{ServletRequestContext.initBaseUri(...)} method the webapp context path is appended:
  private static IRI initBaseUri(
    Provider provider, 
    HttpServletRequest request) {
      StringBuilder buffer = 
        new StringBuilder(
      int port = getPort(provider,request);
      if (port != 80) {
      // So that .resolve() works appropriately.
      return new IRI(buffer.toString());

Am I mis-reading the Javadoc, or is ServletRequestContext doing the incorrect thing?

This bug is causing incorrect <collection> href urls to appear in our Service Documents.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message