forked from zanata/zanata-server
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
7 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,6 +31,8 @@ | |
import javax.servlet.http.HttpServletRequest; | ||
import javax.servlet.http.HttpServletResponse; | ||
|
||
import lombok.extern.slf4j.Slf4j; | ||
|
||
import org.apache.commons.fileupload.FileItem; | ||
import org.apache.commons.fileupload.FileItemFactory; | ||
import org.apache.commons.fileupload.disk.DiskFileItemFactory; | ||
|
@@ -60,6 +62,7 @@ | |
* @author Alex Eng <a href="mailto:[email protected]">[email protected]</a> | ||
* | ||
*/ | ||
@Slf4j | ||
public class FileUploadServlet extends HttpServlet { | ||
private static final long serialVersionUID = 1L; | ||
|
||
|
@@ -71,9 +74,6 @@ public class FileUploadServlet extends HttpServlet { | |
|
||
private TranslationService translationServiceImpl; | ||
|
||
private static final Logger LOGGER = LoggerFactory | ||
.getLogger(FileUploadServlet.class); | ||
|
||
@Override | ||
protected void doPost(final HttpServletRequest request, | ||
final HttpServletResponse response) throws ServletException, | ||
|
@@ -120,8 +120,10 @@ private void doWork(HttpServletRequest req, HttpServletResponse resp) | |
HashMap<String, FileItem> params = | ||
new HashMap<String, FileItem>(); | ||
for (FileItem item : items) { | ||
LOGGER.info("param- " + item.getFieldName() + " value-" | ||
+ item.getString()); | ||
if (log.isDebugEnabled()) { | ||
log.debug("param- " + item.getFieldName() + " value-" | ||
+ item.getString()); | ||
} | ||
params.put(item.getFieldName(), item); | ||
} | ||
|
||
|