From: Roland Haeder Date: Mon, 24 Aug 2015 13:04:30 +0000 (+0200) Subject: Added Serializable to BaseBasket + added log4j-web and filter for it (all URLs) X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=16dda102f7fd00bb43c85725faadca08d0d89a00;p=pizzaservice-war.git Added Serializable to BaseBasket + added log4j-web and filter for it (all URLs) Signed-off-by:Roland Häder --- diff --git a/lib/log4j-web-2.3.jar b/lib/log4j-web-2.3.jar new file mode 100644 index 00000000..e87ef9ab Binary files /dev/null and b/lib/log4j-web-2.3.jar differ diff --git a/nbproject/build-impl.xml b/nbproject/build-impl.xml index b0f7fcc0..da3c5391 100644 --- a/nbproject/build-impl.xml +++ b/nbproject/build-impl.xml @@ -1027,6 +1027,7 @@ exists or setup the property manually. For example like this: + @@ -1036,6 +1037,7 @@ exists or setup the property manually. For example like this: + diff --git a/nbproject/genfiles.properties b/nbproject/genfiles.properties index 9e11a91a..2ef60e31 100644 --- a/nbproject/genfiles.properties +++ b/nbproject/genfiles.properties @@ -1,8 +1,8 @@ -build.xml.data.CRC32=04817f3c +build.xml.data.CRC32=9e7a0782 build.xml.script.CRC32=a6f5a733 build.xml.stylesheet.CRC32=651128d4@1.68.1.1 # This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml. # Do not edit this file. You may delete it but then the IDE will never regenerate such files for you. -nbproject/build-impl.xml.data.CRC32=04817f3c -nbproject/build-impl.xml.script.CRC32=7f4d7ef9 +nbproject/build-impl.xml.data.CRC32=9e7a0782 +nbproject/build-impl.xml.script.CRC32=221b1210 nbproject/build-impl.xml.stylesheet.CRC32=99ea4b56@1.68.1.1 diff --git a/nbproject/project.properties b/nbproject/project.properties index d63eef99..d02847ea 100644 --- a/nbproject/project.properties +++ b/nbproject/project.properties @@ -31,6 +31,7 @@ file.reference.commons-codec-1.10.jar=lib/commons-codec-1.10.jar file.reference.log4j-api-2.3.jar=lib/log4j-api-2.3.jar file.reference.log4j-core-2.3.jar=lib/log4j-core-2.3.jar file.reference.jcore.jar=lib/jcore.jar +file.reference.log4j-web-2.3.jar=lib\\log4j-web-2.3.jar includes=** j2ee.compile.on.save=true j2ee.copy.static.files.on.save=true @@ -49,7 +50,8 @@ javac.classpath=\ ${file.reference.log4j-api-2.3.jar}:\ ${file.reference.log4j-core-2.3.jar}:\ ${file.reference.commons-codec-1.10.jar}:\ - ${libs.MySQLDriver.classpath} + ${libs.MySQLDriver.classpath}:\ + ${file.reference.log4j-web-2.3.jar} # Space-separated list of extra javac options javac.compilerargs=-Xlint:unchecked javac.debug=true @@ -72,6 +74,7 @@ javadoc.notree=false javadoc.preview=true javadoc.private=true javadoc.reference.commons-codec-1.10.jar=/home/quix0r/public_html/JARs/commons-codec-1.10-javadoc.jar +javadoc.reference.log4j-web-2.3.jar=../../../JARs/log4j-web-2.3-javadoc.jar javadoc.splitindex=true javadoc.use=true javadoc.version=true @@ -90,6 +93,7 @@ runmain.jvmargs= source.encoding=UTF-8 source.reference.commons-codec-1.10.jar=/home/quix0r/public_html/JARs/commons-codec-1.10-sources.jar source.reference.jcore.jar=../jcore/src +source.reference.log4j-web-2.3.jar=../../../JARs/log4j-web-2.3-sources.jar source.root=src src.dir=${source.root}/java test.src.dir=test diff --git a/nbproject/project.xml b/nbproject/project.xml index d97b82e6..b2afc27b 100644 --- a/nbproject/project.xml +++ b/nbproject/project.xml @@ -26,6 +26,10 @@ ${libs.MySQLDriver.classpath} WEB-INF/lib + + ${file.reference.log4j-web-2.3.jar} + WEB-INF/lib + diff --git a/src/java/org/mxchange/pizzaapplication/basket/BaseBasket.java b/src/java/org/mxchange/pizzaapplication/basket/BaseBasket.java index be976ece..93886702 100644 --- a/src/java/org/mxchange/pizzaapplication/basket/BaseBasket.java +++ b/src/java/org/mxchange/pizzaapplication/basket/BaseBasket.java @@ -16,6 +16,7 @@ */ package org.mxchange.pizzaapplication.basket; +import java.io.Serializable; import java.sql.SQLException; import java.text.MessageFormat; import java.util.LinkedHashMap; @@ -32,7 +33,10 @@ import org.mxchange.pizzaapplication.product.Product; * * @author Roland Haeder */ -public class BaseBasket extends BaseFrameworkSystem implements Basket { +public class BaseBasket extends BaseFrameworkSystem implements Basket, Serializable { + // Serial number + private static final long serialVersionUID = 784396762230845717L; + /** * Item map */ diff --git a/web/WEB-INF/web.xml b/web/WEB-INF/web.xml index 78c62db0..69d45229 100644 --- a/web/WEB-INF/web.xml +++ b/web/WEB-INF/web.xml @@ -35,6 +35,11 @@ Utf8ServletFilter org.mxchange.pizzaapplication.filter.servlet.utf8.Utf8ServletFilter + + A servlet filter for logging + Log4jServletFilter + org.apache.logging.log4j.web.Log4jServletFilter + A filter for handling added basket items BasketItemAddedFilter @@ -44,6 +49,10 @@ BasketItemAddedFilter /form_handler/add_item.jsp + + Log4jServletFilter + /* + Utf8ServletFilter /*