Revision 2668
Added by sgarg over 18 years ago
MetaCatServlet.java | ||
---|---|---|
502 | 502 |
username = "public"; |
503 | 503 |
sess.setAttribute("username", username); |
504 | 504 |
} else { |
505 |
logMetacat.warn("The session is not new or "
|
|
506 |
+ " has sessionid parameter");
|
|
505 |
logMetacat.warn("The session is either old or "
|
|
506 |
+ "has sessionid parameter"); |
|
507 | 507 |
try { |
508 | 508 |
if (params.containsKey("sessionid")) { |
509 | 509 |
sess_id = ((String[]) params.get("sessionid"))[0]; |
... | ... | |
535 | 535 |
} |
536 | 536 |
|
537 | 537 |
username = (String) sess.getAttribute("username"); |
538 |
logMetacat.warn("The user name from session is: "
|
|
538 |
logMetacat.info("The user name from session is: "
|
|
539 | 539 |
+ username); |
540 | 540 |
password = (String) sess.getAttribute("password"); |
541 | 541 |
groupnames = (String[]) sess.getAttribute("groupnames"); |
... | ... | |
739 | 739 |
} |
740 | 740 |
|
741 | 741 |
String un = ((String[]) params.get("username"))[0]; |
742 |
logMetacat.warn("user " + un + " try to login");
|
|
742 |
logMetacat.warn("user " + un + " is trying to login");
|
|
743 | 743 |
String pw = ((String[]) params.get("password"))[0]; |
744 | 744 |
|
745 | 745 |
String qformat = "xml"; |
... | ... | |
1852 | 1852 |
+ needSchemaValidate); |
1853 | 1853 |
return needSchemaValidate; |
1854 | 1854 |
} |
1855 |
System.out.println("before get target line");
|
|
1855 |
logMetacat.info("before get target line");
|
|
1856 | 1856 |
String targetLine = getSchemaLine(xml); |
1857 |
System.out.println("after get target line");
|
|
1857 |
logMetacat.info("after get target line");
|
|
1858 | 1858 |
// to see if the second line contain some keywords |
1859 | 1859 |
if (targetLine != null |
1860 | 1860 |
&& (targetLine.indexOf(SCHEMALOCATIONKEYWORD) != -1 || targetLine |
... | ... | |
1993 | 1993 |
out.println("<error>"); |
1994 | 1994 |
out.println("Docid not specified."); |
1995 | 1995 |
out.println("</error>"); |
1996 |
logMetacat.error("Docid not specified for the document to be deleted."); |
|
1996 | 1997 |
} else { |
1997 | 1998 |
|
1998 | 1999 |
// delete the document from the database |
... | ... | |
2008 | 2009 |
out.println("<success>"); |
2009 | 2010 |
out.println("Document deleted."); |
2010 | 2011 |
out.println("</success>"); |
2012 |
logMetacat.warn("Document deleted."); |
|
2011 | 2013 |
} |
2012 | 2014 |
catch (AccessionNumberException ane) { |
2013 | 2015 |
response.setContentType("text/xml"); |
... | ... | |
2016 | 2018 |
//out.println("Error deleting document!!!"); |
2017 | 2019 |
out.println(ane.getMessage()); |
2018 | 2020 |
out.println("</error>"); |
2021 |
logMetacat.error("Document could not be deleted: " |
|
2022 |
+ ane.getMessage()); |
|
2019 | 2023 |
} |
2020 | 2024 |
} |
2021 | 2025 |
catch (Exception e) { |
... | ... | |
2024 | 2028 |
out.println("<error>"); |
2025 | 2029 |
out.println(e.getMessage()); |
2026 | 2030 |
out.println("</error>"); |
2031 |
logMetacat.error("Document could not be deleted: " |
|
2032 |
+ e.getMessage()); |
|
2027 | 2033 |
} |
2028 | 2034 |
} |
2029 | 2035 |
} |
Also available in: Unified diff
Changes in log levels of some commands mentioned in the previos commit.