Uploaded image for project: 'Jackrabbit Content Repository'
  1. Jackrabbit Content Repository
  2. JCR-3634

New method: JackrabbitRepository.login(Credentials, Map<String, Object>)

    XMLWordPrintableJSON

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.7.1
    • Fix Version/s: 2.7.1
    • Component/s: jackrabbit-api
    • Labels:
      None

      Description

      As discussed [1] we need a way for passing session attributes on login without having to fall back to credentials. The latter might not support credentials or not be present at all when authentication is handled externally.

      I suggest to add the following method to JackrabbitRepository:

      /**

      • Equivalent to <code>login(credentials, workspace)</code> where
      • <ul>
      • <li><code>workspace = attributes.get(ATT_WORKSPACE_NAME)</code>,</li>
      • <li><code>credentials</code> carry all and only the attributes passed
      • through the <code>attributes</code> map.</li>
      • </ul>
        *
      • @param credentials the credentials of the user
      • @param attributes the attributes to put into the session
      • @return a valid session for the user to access the repository.
      • @throws javax.jcr.LoginException if authentication or authorization for the
      • specified workspace fails.
      • @throws javax.jcr.NoSuchWorkspaceException if the specified workspace is not recognized.
      • @throws javax.jcr.RepositoryException if another error occurs.
        */
        Session login(Credentials credentials, Map<String, Object> attributes);

      See also OAK-803 for some more background.

      [1] http://markmail.org/message/lwhpglehee3jgpip

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                mduerig Michael Dürig
                Reporter:
                mduerig Michael Dürig
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: