clintropolis commented on issue #6923: Adding a Unified web console.
URL: https://github.com/apache/incubator-druid/pull/6923#issuecomment-459260535
Worth considering:
Add a redirect to allow existing user bookmarks to things such as
`http://overlord:8090/console.html` to redirect to their new locations using
the [jetty rewrite
module](https://www.eclipse.org/jetty/documentation/9.4.x/rewrite-handler.html)
(there might be other ways to achieve this too, but I tested this one out).
What I did:
[In top level
`pom.xml`](https://github.com/apache/incubator-druid/pull/6923/files#diff-600376dffeb79835ede4a0b285078036L498):
```
org.eclipse.jetty
jetty-rewrite
${jetty.version}
```
[In
`server/pom.xml`](https://github.com/apache/incubator-druid/pull/6923/files#diff-6e7afd3f31ee906a6644f66ac7bcfe87L133):
```
org.eclipse.jetty
jetty-rewrite
```
[The to redirect old overlord landing page
`CliOverlord.java`](https://github.com/apache/incubator-druid/pull/6923/files#diff-4c7dd412119cb3f42b1c8c83eb72c44aR404):
```
RewriteHandler rewrite = new RewriteHandler();
rewrite.setRewriteRequestURI(true);
rewrite.setRewritePathInfo(false);
rewrite.setOriginalPathAttribute("requestedPath");
RedirectPatternRule redirectRule = new RedirectPatternRule();
redirectRule.setPattern("/console.html");
redirectRule.setLocation("/legacy-overlord-console.html");
rewrite.addRule(redirectRule);
```
and then add `rewrite` to the `handlerList` below.
[and the same thing for
`CoordinatorJettyServerInitializer`](https://github.com/apache/incubator-druid/pull/6923/files#diff-028c3802186ed6f2afab394bf99f05b2R158)
```
...
RedirectPatternRule redirectRule = new RedirectPatternRule();
redirectRule.setPattern("/console.html");
redirectRule.setLocation("/legacy-coordinator-console.html");
rewrite.addRule(redirectRule);
```
Any downside to doing this?
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org
With regards,
Apache Git Services
-
To unsubscribe, e-mail: commits-unsubscr...@druid.apache.org
For additional commands, e-mail: commits-h...@druid.apache.org