Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gradle build: allow selection of a customized web.xml #32

Closed
belgattitude opened this issue Feb 15, 2017 · 4 comments
Closed

Gradle build: allow selection of a customized web.xml #32

belgattitude opened this issue Feb 15, 2017 · 4 comments

Comments

@belgattitude
Copy link
Owner

belgattitude commented Feb 15, 2017

Currently the gradle build includes by default the web.xml stored in the webapp folder.

By doing so the build register the PHPCGIServlet for every build (which requires a php-cgi binary installed and make the install more difficult).

As the PHPCGIServlet is not technically required for common usage, it should be possible to pass a parameter to the gradle command to select a different web.xml (without registration of PHPCGIServlet) for building the war and document it.

@cplerch
Copy link
Contributor

cplerch commented Feb 16, 2017

What exactly is the proplem with PHPCGIServlet?
I'm asking because the javadocs say that it will fail gracefully whenever there is no FastCGI server available:

     * Create a new FastCGI servlet which connects to a PHP FastCGI server using a connection pool.
     * <p>
     * If the JavaBridge context exists and the JavaBridge context can
     * start a FastCGI server and the current context is configured to
     * connect to a FastCGI server, the current context connects to
     * the JavaBridge context to start the server and then uses this
     * server for all subsequent requests until the server is
     * stopped. When FastCGI is not available (anymore), the parent
     * CGI servlet is used instead.

@belgattitude
Copy link
Owner Author

Yes it should, but from stackoverflow, looks like it doesn't...

And most installation problems comes from a missing 'php-cgi'... I'll make a test soon to confirm. So let's wait a bit.

@cplerch
Copy link
Contributor

cplerch commented Feb 16, 2017 via email

@belgattitude
Copy link
Owner Author

Yes I got it, but my point is a bit different:

  1. It should complain/error if the php-cgi is missing and the PHPCGIServlet is enabled. Otherwise it becomes very difficult to determine error (on my experience, who's reading the log ?). The idea is to keep the error as it is probably right now... The reasoning behind:

    • Easy to help if I someone open an issue on github, about it. The message is clear... no 'Can I see your log ? Maybe it's that or this' questions needed ;)
  2. The possibility to build without the PHPCGIServlet. (I suppose most will do). thus no missing php-cgi complain.

That's why I think the possibility should be offered when building (gradle.build). This way it also help me to product clear documentation...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants