com.baloise.maven.solr.ShutDownServlet Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of solr-maven-plugin Show documentation
Show all versions of solr-maven-plugin Show documentation
A maven plugin to help develop and deploy SOLR based applications.
package com.baloise.maven.solr;
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.ServletOutputStream;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
public class ShutDownServlet extends HttpServlet {
@Override
protected void service(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
ServletOutputStream outputStream = resp.getOutputStream();
outputStream.print("Shutting down");
outputStream.flush();
System.exit(0);
}
}