RequestHandlers

0
I am RequestHandler to redirect the URL to a deeplink which is configured, but the request handler is not getting triggered, Could anyone please help me in this? Code Used to add the request Handler is Java Action to add the requesthandler (which is getting called during startup) Core.addRequestHandler("hello", new URLRedirectRequestHandler()); URLRedirectRequestHandler() - Class to redirect @Override public void processRequest(IMxRuntimeRequest arg0, IMxRuntimeResponse arg1, String arg2) throws Exception { HashMap<String,Object> newMap = new HashMap<String,Object>(); IContext context = Core.getSystemContext(); arg1.setStatus(HttpServletResponse.SCSEEOTHER); arg1.addHeader("Location", "/link/hello"); } But the url is not getting redirect when i give http://localhost:8080/hello to http://localhost:8080/link/hello
asked
3 answers
1

You cannot register urls at /hello, only at /hello/ and deeper. The link /hello will always be handled by the static content server. (The add request handler registration is correct, just your test url not)

answered
0

Why do it the difficult way with a java action? Why not use the URL redirector widget? Just create a form with this widget. After calling this form the user gets redirected to the URL of that form. That could be an outside URL but also a deeplink URL.

answered
0

Suggestion

check the EFP webportal

this portal will be for internal use mostly, as the separate parts will be done in the normal EFP site using DEEPLINK

eg. use

http://efpwebsite.mendixcloud.com/link/pillo/main

to get to the PILLO part of the portal !

answered