Giter Club home page Giter Club logo

core-redirects's Introduction

Core Redirects

Core-Redirects is a CoreMedia extension for managing redirects from within CoreMedia Studio. The project is Apache-2.0 licensed, so it can be easily used and modified.

Features

  • Static redirects from an absolute URL or a regular expression
  • Conditional redirects: redirect only, if:
    • the original page returns a 404
    • the source contains certain URL parameters
  • Features can be activated for members of certain CoreMedia groups.
  • Import of redirects from a CSV file
  • Optimized caching in the CAE to minimize response times
  • Configuration of redirects per site

Per default, requests can only be redirected to a CoreMedia content. Redirects to external URLs can be done in two ways:

  • linking a document of the type CMExternalLink
  • using targetUrls for certain redirects, instead of linking contents. This should be used with care, because it might redirect to a non-existing page. The nice thing about linking contents is that the redirect target will exist as long as the redirect exists.

Feedback

If you have any problems, questions, ideas, or feedback, please contact us or create an issue.

Compatibility

See the releases for tested compatibilities.

For earlier versions, take a look into these branches:

  • CoreMedia CMS-9 (v18.10). See the branch: 1904.2-compatible.

Usage

There is a simple user guide available.

Integration

Integrate the Code in your CoreMedia Blueprint Workspace:

GIT submodules

git submodule add https://github.com/tallence/core-redirects.git modules/extensions/core-redirects

Activate the extension using the respective CoreMedia Content Cloud activation scheme for the version in use, like e.g. the management tool for the latest releases:

mvn extensions:sync -Denable=core-redirects -f workspace-configuration/extensions/pom.xml

Alternative way

Of course, it would also be possible to download the repo and copy the files into your Blueprint-Workspace global Extensions-Folder modules/extensions. While you do not have to bother with submodules, you also lose the direct connection to the original repository and the option to easily contribute or merge new things.

Setup

  1. Change the groupId and versionId of all pom.xml to your project values.

  2. The schema.xml (this link only works, if this code is within a blueprint workspace) of the content config-set must contain these two fields: <field name="source" type="string" indexed="true" stored="true"/> <field name="sourceUrlType" type="string" indexed="true" stored="true"/>

  3. Redirects are stored in/read from a site-specific folder (Options/Settings/Redirects), to which users need to have permissions to edit and publish Redirect documents.

Configuration

These options can be configured:

  1. core.redirects.filter.keepParams if enabled, the query parameters of the source URL will be appended to the redirect target URL.
  2. core.redirects.path the site-relative path where the redirect-documents are stored
  3. core.redirects.cache.parallel.site.recompute.threads Maximum number of threads for complete site index updates. Will be used at CAE start up.
  4. core.redirects.cache.parallel.item.recompute.threads Maximum number of threads for item (single redirect) updates. Will be used for changes in a running CAE.
  5. core.redirects.permissions.targetUrlGroup The group, which allows members to describe a redirect target with a URL instead of a document. Should be used with care. Use "*" to allow this for editor.
  6. core.redirects.permissions.regexGroup The group, which allows members to use the sourceType "regexp". Should be used with care.

core-redirects's People

Contributors

dfolgner avatar dhoeckcore avatar mgoellnitz avatar peter-mauritius avatar svkroschwald avatar tallencejanhendrikpopp avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

core-redirects's Issues

the targetLinkName in the gridView is not updated

When the targetLink of a redirect is changed in the RedirectEditPanel, the linkName in the GridView keeps the name of the old targetLink. An editor might be irritated of the old linkName.
The linkName will be updated after clicking on "reload" or after editing the redirect again. It seems to be an issue with the remoteStore-usage, which needs to be updated after updating the single redirect

Disable "save"-button when modification is not allowed

The "modify"- and "delete"-Buttons in the contextMenu should be disabled if the user is not allowed to write (creating or modifying redirects in the current site) which already works. It shouldn't be allowed also, if the currently selected redirect contains regular Expressions and if the user is not allowed to modify these (mayNotUseRegexVE).

Changing redirects causing to invalid plainRedirects and patternRedirects maps

Hi,

when I edit an existing Redirect document and change only the source URL, the plainRedirects and patternRedirects maps in com.tallence.core.redirects.cae.service.SiteRedirects gets invalid. After com.tallence.core.redirects.cae.service.SiteRedirects#addRedirect the map contains an old empty entry.

Maybe you can solve it by remove those entries:

patternRedirects.get(key).add(redirect);
/*Fix*/
patternRedirects.entrySet().removeIf(e -> e.getValue().isEmpty());

Redirect Manager with Identity Provider?

Aloha Tallence team,

One of our customers can use the redirect manager on their sandbox, where they use "internal users". However, when they deploy it to UAT, the redirect manager is available, but all buttons are grayed out.

I looked into the console and saw that he is trying to authenticate with a coremedia:///cap/user/ instead of coremedia:///cap/user/123

image

We are using a cognito-authentication in UAT and Prod. The administrative user group for this should be "admininistrator@cognito" instead of admininistratoren. Can I configure this group somewhere?

Are you aware of CMCC Service setups with your extension?

Best, Uli

Ulrike Heidler
VP of Customer Growth

E-Mail: [email protected]

Support Coremedia 10 - Version 2001.1/2001.2

hi,

not really an issue but just a question regarding cm 10 support. is it planned for near future? and if so, can u tell a potential release date? otherwise we'll fork it and maybe can contribute the working version.

kind regards

content is cut off when using "after_not_found"-mode

I created a redirect, listening to the url "/my-url" and the redirectType "after_not_found".
A page with the same segment exists, I expect the RedirectFilter to deliver the page and ignore the redirect.

What happens:
The page is delivered, but the html from the servlet-response is cut off. The response contains a header "content-length" other responses does not. I assume an error in https://github.com/tallence/core-redirects/blob/master/core-redirects-cae/src/main/java/com/tallence/core/redirects/cae/filter/RedirectHttpServletResponseWrapper.java

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.