protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
		response.setContentType("text/html");
		PrintStream out = new PrintStream(response.getOutputStream());
		try{
			Book newBook = ejb.createBook(request.getParameter("title"), request.getParameter("author"), request.getParameter("isbn"));
			out.println("Book successfully created.<br/>");
			out.println(newBook);
		}
		catch (EJBException e) {
			out.println("Book could not be created.<br/>");
			if(e.getCausedByException() instanceof ConstraintViolationException){
				out.println("Reason(s):<br/>");
				ConstraintViolationException cve = (ConstraintViolationException) e.getCausedByException();
				Set<ConstraintViolation<?>> violations = cve.getConstraintViolations();
				if(violations!=null)
					for(ConstraintViolation<?> cur : violations)
						out.println(cur.getMessage() + "<br/>");
				else
					out.println(cve.getMessage());
			}
		}
		finally{
			out.close();
		}
	}