This is a run-time check, not something that is checked statically by the type system. Though helpful, this behavior does not rely on Java being strongly typed.
hmm... good point about the services menu, i always forget about that. however 1) firefox doesn't support it at all, and 2) the inactive menu item says "Open in Camino" (firefox is the default browser). so i guess your suggestion would be great if firefox would fix its mac support.
regarding your other comment: the goal is to keep my hands on the keyboard and double-clicking is definitely out of the question.
Firefox and Konqueror should have a button for "Open the clipboard in a new tab".
Amen. On linux I constantly used the middleclick-paste-load-url. Now I'm using a new mac and though lack of unix autocopy/paste isn't a big deal, I can't stand that to load a new url i have to cmd-C, cmd-L (highlight text in address bar), cmd-V, Enter. It's exhausting just typing it all out. Having a key command in firefox to load a url from the clipboard would rock.
r =.999...9 ("ending" in 9) 10r = 9.999...0 ("ending" in *zero*!)
hmm... i don't buy it! 10r would only end in zero if there were a finite number of 9's in the mantissa. after all, when you say r =.999...9 you imply there is a "last" 9, which i reject.
what this really illustrates is how difficult and subtle the representation of real numbers as decimal sequences is. even things like addition and multiplication aren't very clear. what is pi + e anyhow...
anyway, i still think i'm right;-) convince me otherwise!
repeating infinitely, you would eventually need an infinite number of zeros before the 1 to be able to add it to the repeating 9. That infinitessimally small number actually turns out to be equal to zero, thus, 0.9(repeating) is equal to 1.
all you've done is transform the question of whether or not.999... = 1 to whether or not.00001 = 0! here's a stronger argument:
let r =.999... then 10r = 9.999... and 10r - r = 9, so 9r = 9, and r = 1.
voila! you can use the same argument to find the rational form of any repeating decimal.
It's the largest equivalence class in the reflexive transitive
symmetric closure of the relationship "can be reached by an IP
packet from". --Seth Breidbart
-1 redundant: an equivalence class implies an equivalence relation which implies reflexivity, symmetry and transitivity.
believe me, the amount of time it takes to start the actual shell, be it bash or tcsh, is completely negligible compared to the time it takes to launch the terminal.
I just finished writing two lengthy term papers in LaTeX, and my first two LaTeX documents ever. I read one good tutorial and was off and running. Sure from time to time I had to google around for a snippet of code to do one thing or another, but really 90% of even most technical articles is text. Typesetting math formulas is a breeze. Tables and figures are a little tricky, but nothing new if you're familiar with html. Just go ahead and learn it, once you do you'll never turn back.
The lack of a common code base is one of the things that has held back the database community and has been a huge advantage for the operating systems community. The academic world has had a common operating system that everybody can talk about and experiment with.
It has the downside of creating a mob culture. But the positive side is everybody has a common language and a common set of problems they are working on.
ok, read that again and tell me you think he's talking about the open source community versus the academic community. think of "mob culture" as in "a lack of diversity" rather than "a disorderly crowd."
As an occasional website designer, I would like to avoid having to delve into the DOM to maintain a consistent appearance and functionality across platforms/browsers.
by replacing vendor-specific APIs, that is exactly the problem the DOM solves...
also, i don't think java is really "copying" C# features. you could say the same thing about most of C#'s features. in reality, both environments borrow heavily from years of computer science precedent.
the high-res versions that are offered here are great. i have access to a huge hp designjet, and plan on printing these out for office wall art. does anyone know of other sites that offer similarly good, free, printer-quality sciency images?
when i say that a lot of time is spent in StringBuffer i am referring to the concatenation of Strings (or primitive types converted to Strings). String concatenation is obviously a big part of servlet engine (just take a look at the.java file generated by your preferred jsp compiler). String concatenation with the + operator is equivalent to calling the StringBuffer.append method (thanks to the compiler). concatenating Strings across multiple statements is not equivalent to just calling.append multiple times. for each statement a new StringBuffer is allocated, which is costly, and then shortly gc'd, which is also costly.
for example:
String s = "one" + "two" + "three"; return s;
is roughly equivalent to:
StringBuffer sb = new StringBuffer("one").append("two").append("three"); return sb.toString();
whereas
String s = "one"; s += "two"; s += "three"; return s;
is roughly equivalent to:
StringBuffer sb = new StringBuffer("one").append("two"); String tmp = sb.toString(); sb = new StringBuffer(tmp).append("three"); return sb.toString();
the second set of statements requires more allocation and garbage than the first, and this is the optimization i'm referring to. if you have an idea of the target size of the finished StringBuffer, it's also helpful to declare the initial size of the internal buffer with:
new StringBuffer(int size)
obviously optimizations of StringBuffers or other similarly basic methods (equals, hashCode, etc) are important in gaining every last ounce of efficiency, but i'm also not saying this is the only way, or even a good place to start. architectural efficiencies will probably make the most crucial difference, so start there before profiling your StringBuffers:)
one of the simplest tomcat performance improvements i've made is by switching from sun's vm to bea's jrockit. jrockit is free to use, and in my experience a much more robust server side environment. it's faster, has more flexible garbage collection options, and a nice gui management console. it helps to have a lot of memory (i think by default it will use 75% of the available system memory), but for some of the webapps i've built, i've seen tomcat+jrockit turn out 15-20% more pages/sec than tomcat+hotspot. jrockit 8 beta came out recently; it supports jdk-1.4 and has been solid for me (so far) running tomcat, jetty, and jboss. i've even been using jrockit on my personal workstation while developing with jboss because it cuts the startup time from about 1m:45s to 50s.
other than that, i've found a big tomcat performance problem to be that of spawning new threads. the default connector's configuration sets minProcessors=5 (ie: 5 threads in the threadpool available to handle new requests). i find that when load is high enough to warrant more than the number of initial threads, requests get dropped on the floor while more threads are added to the pool. so don't be shy about starting enough request processors from the beginning.
also, don't be afraid to run some load tests on your app while profiling. you'll need a fast machine to run tomcat+cocoon under a profiler, but the results are often very helpful in finding bottlenecks. in particular, you'll probably find a lot of time spent in StringBuffers, which is normal for an app like yours, but it's a good place to start when you're interested in shaving a few seconds here and there.
Can you elaborate on the deficiencies you've found in the JDBC implementation?
sure. for starters, take a look here: http://lab.applinet.nl/postgresql-jdbc/
those are the results of the jdbc compliance tests, ringing in at around 43%. peruse that page and get ready to live with all those shortcomings when writing your application. the last few things that have bitten me personally are the slew of methods not implemented (or that just return empty strings...) in DatabaseMetaData and ResultSetMetaData, the lack of any sort of performance gain by using PreparedStatements, and the fact that the org.postgresql.Datasource barely works (no distributed transaction support, and no connection pooling). i believe only recently have cvs checkins been made to allow updatable recordsets. though i can see from your other posts you're aware of these issues, it's still a bummer.
I think that's an unfair assessment.
you're correct in that i'm only evaluating JDBC support. however, that's a pretty big chunk of your enterprise web-app marketshare. i have no experience with the other interfaces, and so of course can't comment on their degree of quality.
This is a run-time check, not something that is checked statically by the type system. Though helpful, this behavior does not rely on Java being strongly typed.
Tsk: as if that weren't bad enough!
Wondering how to pronounce Christiaan Huygens' name? You're in luck: http://frank.harvard.edu/~paulh/misc/huygens.htm
:)
Unfortunately, if you were raised in America, it's probably impossible for you
hmm... good point about the services menu, i always forget about that. however 1) firefox doesn't support it at all, and 2) the inactive menu item says "Open in Camino" (firefox is the default browser). so i guess your suggestion would be great if firefox would fix its mac support.
regarding your other comment: the goal is to keep my hands on the keyboard and double-clicking is definitely out of the question.
hmm... i don't buy it! 10r would only end in zero if there were a finite number of 9's in the mantissa. after all, when you say r =
what this really illustrates is how difficult and subtle the representation of real numbers as decimal sequences is. even things like addition and multiplication aren't very clear. what is pi + e anyhow...
anyway, i still think i'm right
all you've done is transform the question of whether or not
let r =
then 10r = 9.999...
and 10r - r = 9,
so 9r = 9,
and r = 1.
voila! you can use the same argument to find the rational form of any repeating decimal.
his heart was in the right place though.
believe me, the amount of time it takes to start the actual shell, be it bash or tcsh, is completely negligible compared to the time it takes to launch the terminal.
I just finished writing two lengthy term papers in LaTeX, and my first two LaTeX documents ever. I read one good tutorial and was off and running. Sure from time to time I had to google around for a snippet of code to do one thing or another, but really 90% of even most technical articles is text. Typesetting math formulas is a breeze. Tables and figures are a little tricky, but nothing new if you're familiar with html. Just go ahead and learn it, once you do you'll never turn back.
mmm... those lies are quite reassuring!
ok, read that again and tell me you think he's talking about the open source community versus the academic community. think of "mob culture" as in "a lack of diversity" rather than "a disorderly crowd."
He's not talking about us like that. He's talking about the academic world.
if you're looking for great music, american or otherwise, there's no better place than pitchfork.
As an occasional website designer, I would like to avoid having to delve into the DOM to maintain a consistent appearance and functionality across platforms/browsers.
by replacing vendor-specific APIs, that is exactly the problem the DOM solves...
it's in the works: http://www.jcp.org/en/jsr/detail?id=175
also, i don't think java is really "copying" C# features. you could say the same thing about most of C#'s features. in reality, both environments borrow heavily from years of computer science precedent.
the high-res versions that are offered here are great. i have access to a huge hp designjet, and plan on printing these out for office wall art. does anyone know of other sites that offer similarly good, free, printer-quality sciency images?
when i say that a lot of time is spent in StringBuffer i am referring to the concatenation of Strings (or primitive types converted to Strings). String concatenation is obviously a big part of servlet engine (just take a look at the .java file generated by your preferred jsp compiler). String concatenation with the + operator is equivalent to calling the StringBuffer.append method (thanks to the compiler). concatenating Strings across multiple statements is not equivalent to just calling .append multiple times. for each statement a new StringBuffer is allocated, which is costly, and then shortly gc'd, which is also costly.
;
:)
for example:
String s = "one" + "two" + "three";
return s;
is roughly equivalent to:
StringBuffer sb = new StringBuffer("one").append("two").append("three")
return sb.toString();
whereas
String s = "one";
s += "two";
s += "three";
return s;
is roughly equivalent to:
StringBuffer sb = new StringBuffer("one").append("two");
String tmp = sb.toString();
sb = new StringBuffer(tmp).append("three");
return sb.toString();
the second set of statements requires more allocation and garbage than the first, and this is the optimization i'm referring to. if you have an idea of the target size of the finished StringBuffer, it's also helpful to declare the initial size of the internal buffer with:
new StringBuffer(int size)
obviously optimizations of StringBuffers or other similarly basic methods (equals, hashCode, etc) are important in gaining every last ounce of efficiency, but i'm also not saying this is the only way, or even a good place to start. architectural efficiencies will probably make the most crucial difference, so start there before profiling your StringBuffers
one of the simplest tomcat performance improvements i've made is by switching from sun's vm to bea's jrockit. jrockit is free to use, and in my experience a much more robust server side environment. it's faster, has more flexible garbage collection options, and a nice gui management console. it helps to have a lot of memory (i think by default it will use 75% of the available system memory), but for some of the webapps i've built, i've seen tomcat+jrockit turn out 15-20% more pages/sec than tomcat+hotspot. jrockit 8 beta came out recently; it supports jdk-1.4 and has been solid for me (so far) running tomcat, jetty, and jboss. i've even been using jrockit on my personal workstation while developing with jboss because it cuts the startup time from about 1m:45s to 50s.
d ex .shtml
http://www.bea.com/products/weblogic/jrockit/in
other than that, i've found a big tomcat performance problem to be that of spawning new threads. the default connector's configuration sets minProcessors=5 (ie: 5 threads in the threadpool available to handle new requests). i find that when load is high enough to warrant more than the number of initial threads, requests get dropped on the floor while more threads are added to the pool. so don't be shy about starting enough request processors from the beginning.
also, don't be afraid to run some load tests on your app while profiling. you'll need a fast machine to run tomcat+cocoon under a profiler, but the results are often very helpful in finding bottlenecks. in particular, you'll probably find a lot of time spent in StringBuffers, which is normal for an app like yours, but it's a good place to start when you're interested in shaving a few seconds here and there.
hope that helps a little.
no, i can't imagine that you would have any performance issues with that site... just look at those auction statistics!
registered users: 11
auctions listed: 2
total funds: $19
you study web development, perl, gcc, grep, sql, cisco... and the emphsis is on theory? um, right.
20 degrees of freedom? doesn't this thing still need to be attached to your arm?