oasp / oasp4j

The Open Application Standard Platform for Java
Apache License 2.0
60 stars 303 forks source link

White label error #572

Closed kiran-vadla closed 7 years ago

kiran-vadla commented 7 years ago

Fix for the issue #564 is provided as part of this PR . File that is pushed as part of this PR is needed if the user is deploying the war file (without the angular or sencha client integrated) for the sample restaurant application onto external Tomcat . If the user is deploying the war (with the angular or sencha client integrated) , then the user has to follow the section 'Deploy on Tomcat' in the wiki https://github.com/devonfw/devon-guide/wiki/getting-started-deployment-on-tomcat

Thanks, @kiran-vadla

oasp-ci commented 7 years ago

Can one of the admins verify this patch?

amarinso commented 7 years ago

How does this PR solve the issue? I mean it is only an static file and the error seems to be because there is nothing mapped to the /error route

Also, on the WAR file it goes into WEB-INF/classes/static/index.html is it there on purpose?

If this has to reflect a 404 error, then the page should not be presenting content without notifying also the error, something that the Whitelabel page already does just fine

kiran-vadla commented 7 years ago

Thanks for the feedback @amarinso . So, this scenario of user receiving 404 error (WhiteLabel Error) when the user tries to access the application after deploying the oasp-sample-server.war file (without the angular or sencha client integrated) onto external tomcat should be thought of as 'Business As Usual' case ? If so, only changes in the wiki https://github.com/devonfw/devon-guide/wiki/getting-started-deployment-on-tomcat under section 'Deploy on Tomcat' suffice except for the 'Note' at the end of the section . It has to be removed . Kindly let me know.

Thanks, @kiran-vadla

amarinso commented 7 years ago

When you run the app in WAR format on a Tomcat, when accessing the root path it redirects to `/jsclient´ and thus you get an error.

I think we should remove the redirection from the index.jsp on the OASP4J sample if not compiled with the -Pclient profile because it is misleading and has no sense if you only want a backend solution

kiran-vadla commented 7 years ago

@amarinso , So, we can document it saying that if the user is not compiling OASP4J sample using 'jsclient' profile , he can delete or comment the redirection code in index.jsp from OASP4J sample.

amarinso commented 7 years ago

Having the engagement "removing" options not needed makes no good "user experience" of the framework. We should provide just the functionality needed.

imagine that we have more options... if we add them "by default" then the engagement has to work around it every time...

kiran-vadla commented 7 years ago

ok. Thanks @amarinso . Let me analyse on these options.

Thanks, @kiran-vadla

kiran-vadla commented 7 years ago

Solution for the functionality 'Adding the file when compiling with the -Pjsclient' is submitted in PR #587. Please refer it in future. This is being closed .

Thanks, @kiran-vadla.