solid / solid/specification

configurable redirecting and remapping

Open
#136 11 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

category: new functionality topic: auxiliary resources
Dominant language
HTML
Stars
563
Forks
108
Avg merge
4d 13h
Merged PRs (30d)
3

Description

https://github.com/solid/specification/issues/107#issuecomment-568072489

@TallTed: Apache, nginx, etc., are configurable to redirect from (or deliver without actual redirection) / to /index.html or /index.php or /arbitrary.handler or whatever. (It's not just about index.*!) This is neither default, nor universal, behavior -- it is the choice of the server (or website, or directory) admin -- but the discussion I'm seeing seems to be trying to make the decision once and for all, and appears to be largely debating between people who would make different choices on their apache/nginx/whatever instance ... which would be OK if it's actually turned into a configuration option, but will remain a problem if we make it hard-and-fast as the way Solid works.

I think defining something like Apache .htaccess as part of LDP container metadata https://github.com/solid/data-interoperability-panel/pull/32 would provide general and explicit mechanism which would help us avoid some arbitrary implicit behavior. I think it should at least allow to:

  • defining redirecting with HTTP 3XX codes
  • define remapping with HTTP 2XX codes and Content-Location Header

It could possibly have RDF version of Apache mod_rewrite with equivalents of RewriteCond (HTTP_ACCEPT, HTTP_ACCEPT_LANGUAGE etc.) and RewriteRule.

This would allow explicit remapping for discussed in #69 case of serving HTML from URL denoting LDP Container, without arbitrary convention like index.*. Still implementations could opt-in to include index.* as default remapping rule while allowing applications with sufficient access to overwrite it for specific container in solid storage.

Very likely it could also provide configurable way to address discussed in #107 redirection for IRIs with or without trailing /.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the linked discussions in specification issues #69 and #107 and the referenced data-interoperability-panel pull request #32. Compare the proposed LDP container metadata approach with Apache .htaccess and mod_rewrite. Done means defining an agreed mechanism for HTTP 3XX redirects, HTTP 2XX remapping with Content-Location, and conditional rules for trailing slashes and content negotiation.

Written by the indexing model from the issue text.

Assessment

Tech stack
apache, nginx
Domain
backend-api-design, web-dev
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.