- show more lines in online log

- reverse order is default now
pull/1/head
Michael Peter Christen 13 years ago
parent 55bdafbaf1
commit 1baf498d59

@ -47,7 +47,7 @@ java.util.logging.FileHandler.encoding=UTF-8
# Properties for the GuiHandler # Properties for the GuiHandler
net.yacy.kelondro.logging.GuiHandler.level = ALL net.yacy.kelondro.logging.GuiHandler.level = ALL
net.yacy.kelondro.logging.GuiHandler.formatter=net.yacy.kelondro.logging.SimpleLogFormatter net.yacy.kelondro.logging.GuiHandler.formatter=net.yacy.kelondro.logging.SimpleLogFormatter
net.yacy.kelondro.logging.GuiHandler.size = 400 net.yacy.kelondro.logging.GuiHandler.size = 10000
# Properties for the ConsoleOutErrHandler # Properties for the ConsoleOutErrHandler
net.yacy.kelondro.logging.ConsoleOutErrHandler.level = ALL net.yacy.kelondro.logging.ConsoleOutErrHandler.level = ALL

@ -11,7 +11,7 @@
<form action="ViewLog_p.html" method="get" accept-charset="UTF-8"> <form action="ViewLog_p.html" method="get" accept-charset="UTF-8">
<fieldset> <fieldset>
<input type="text" name="lines" id="lines" size ="4" value="#[lines]#" maxlength="9" /><label for="lines"> Lines (max. #[maxlines]#)</label> <input type="text" name="lines" id="lines" size ="5" value="#[lines]#" maxlength="9" /><label for="lines"> Lines (max. #[maxlines]#)</label>
<input type="checkbox" name="mode" id="mode" value="reversed" #(reverseChecked)#::checked="checked"#(/reverseChecked)# /><label for="mode">reversed order</label> <input type="checkbox" name="mode" id="mode" value="reversed" #(reverseChecked)#::checked="checked"#(/reverseChecked)# /><label for="mode">reversed order</label>
<input type="text" name="filter" id="filter" size ="30" value="#[filter]#" maxlength="60" /> <input type="text" name="filter" id="filter" size ="30" value="#[filter]#" maxlength="60" />
<input type="submit" value="refresh" /> <input type="submit" value="refresh" />

@ -48,9 +48,9 @@ public class ViewLog_p {
public static serverObjects respond(@SuppressWarnings("unused") final RequestHeader header, final serverObjects post, @SuppressWarnings("unused") final serverSwitch env) { public static serverObjects respond(@SuppressWarnings("unused") final RequestHeader header, final serverObjects post, @SuppressWarnings("unused") final serverSwitch env) {
final serverObjects prop = new serverObjects(); final serverObjects prop = new serverObjects();
String[] log = new String[0]; String[] log = new String[0];
boolean reversed = false; boolean reversed = true;
boolean json = false; boolean json = false;
int maxlines = 400, lines = 200; int maxlines = 10000, lines = 1000;
/* Usually a regex like this would make no sense, ".*" would be /* Usually a regex like this would make no sense, ".*" would be
* sufficient, but ".*.*" makes it a little bit more convenient * sufficient, but ".*.*" makes it a little bit more convenient
* for the user to input regexes like ".*FOO.*" in the HTML * for the user to input regexes like ".*FOO.*" in the HTML
@ -58,7 +58,7 @@ public class ViewLog_p {
*/ */
String filter = ".*.*"; String filter = ".*.*";
if(post != null){ if (post != null){
reversed = (post.containsKey("mode") && "reversed".equals(post.get("mode"))); reversed = (post.containsKey("mode") && "reversed".equals(post.get("mode")));
json = post.containsKey("json"); json = post.containsKey("json");

@ -799,7 +799,7 @@ body#Surftips div.searchresults {
overflow:hidden; overflow:hidden;
} }
body#ViewLog div.log { body#ViewLog div.log {
height:600px; height:900px;
overflow:scroll; overflow:scroll;
} }

@ -40,7 +40,7 @@ import java.util.logging.SimpleFormatter;
public class GuiHandler extends Handler { public class GuiHandler extends Handler {
private final static int DEFAULT_SIZE = 400; private final static int DEFAULT_SIZE = 10000;
private int size = DEFAULT_SIZE; private int size = DEFAULT_SIZE;
private LogRecord buffer[]; private LogRecord buffer[];
private int start, count; private int start, count;

Loading…
Cancel
Save