Ubuntu 8.10: Pure Frustration
Having computers at home means your holidays will be spent on them. Last Christmas, I fought a Windows virus. This Thanksgiving weekend, my old computer gao-2002 became unbearably unreliable.
I guess that's what Black Friday is for. So I got up early in the morning and went to Best Buy and Office Depot looking for bargains. I haven't been looking at computer systems for the last couple of years so I don't know what to expect. I'm surprised to find a Intel(R) Core 2 Quad system with 8GB RAM and 750 GB hard drive at a reasonable price. So that's what I took home.
It's an HP Pavilion Elite with 64-bit Vista Home Premium SP1. And maybe it's the quad-core CPU, or maybe it's the 8GB of RAM, Vista is not slow on this machine, unlike on the dual-core/2GB laptop from last year. It even has a pre-installed JRE.
Vista's "Shrink Volume" disk management feature makes it really easy to free up disk partition space for my GNU/Linux installation. For this machine, I chose the newly released Ubuntu 8.10 Desktop amd64. While its installation is really streamlined and consumer-oriented, there were a few glitches that threw me off balance.
The first hurdle is the partition setup screen:
The good thing about the screen is that it has graphics that illustrate what each choice will do. The bad thing about the screen is that the illustration does not match the selection. I know I want to use the largest contiguous free space, but that's not what the graphics shows. I ended up manually editing the partition table.
Another, more serious, problem is that the Ubuntu 8.10's NetworkManager does not save its settings in a way that would survive a reboot. During installation, Ubuntu 8.10 detected the Ethernet card and configured it to be "Automatic (DHCP)", which works fine for web browsing but is not enough for sshd. Again, there is a very intuitive way to change it with the NetworkManager tray icon:
After I change the method to "Manual" and put in all the information and click OK, I can restart the connection using the tray icon and my change would take effect. However if I reboot the machine, my setting will go back to "Automatic (DHCP)".
This is very frustrating. So frustrating that I would recommend against using Ubuntu 8.10 if DHCP is not sufficient for your network needs.
[Update Sun Nov 30 20:21:29 CST 2008] Just found out that I can no longer login successfully after logging out.
Holliday Java Quiz: ConcurrentModificationException
Tomorrow is Thanksgiving in the US. And here is a little Java quiz that you may want to ponder on while the turkey is in the oven. (BTW, I just recently realized I've been pronouncing the word 'oven' wrong all these years. Apparently it's not [oh-vn], but [uh-vn].)
Q: For the following Foo.java, is it ever possible for line 21 to throw a java.util.ConcurrentModificationException?
1 import java.util.ArrayList; 2 import java.util.List; 3 4 public class Foo { 5 private final List<Bar> bars = new ArrayList<Bar>(); 6 7 public void add(Bar bar) { 8 synchronized(bars) { 9 bars.add(bar); 10 } 11 } 12 13 public void remove(Bar bar) { 14 synchronized(bars) { 15 bars.remove(bar); 16 } 17 } 18 19 public void close() { 20 synchronized(bars) { 21 for (Bar bar: bars) { 22 bar.close(); 23 } 24 bars.clear(); 25 } 26 } 27 }
Have a happy Thanksgiving.
Friday Java Quiz: Static Fields In Inner Classes
(Mario Aquino suggested this quiz.)
Q: Will the following Java source compile?
public class Outer { public class Inner { public static int ONE = 12; } }
Strict rules: No actually running the compiler.
Sea Island Mathematical Manual (海岛算经)
Brian asked a question yesterday about estimating the height of a tree using a stretched arm and a pencil and measuring surface distances, which turned out to be quite easy to solve. It reminded me of similar problems I studied in the past. The most famous set is from the book 海岛算经 (Hai Dao Suan Jing or Sea Island Mathematical Manual) by the third century Chinese mathematician 刘徽(Liu Hui), who is famous for calculating π to 3.1416.
I reread the book again, and find its problems still refreshing to ponder. Here is the first problem, translated into English, posed to you as today's math quiz (can you, with your computers and calculators, out smart someone from AD 263?):
Q: Now one surveys a sea island. He erects two poles, both three zhangs tall, and one thousand bus apart. He lets the two poles and the sea island line up. From the forward pole he walks back one hundred and twenty-three bus, puts his eye to the ground and sees that the tip of the pole coincides with the top of the island. From the rare pole he walks back one hundred and twenty-seven bus, puts his eye to the ground and sees that the tip of the pole coincides with the top of the island. What is the height of the island and the distance from the island to the poles?
(In ancient Chinese measurement, 1 zhang(丈) = 10 chi(尺), and 1 bu(步) = 6 chi(尺).)
Goodbye Bloglines.com
As much as I like Bloglines.com and want to remain loyal to a company that has been served me excellently for the past five years, there is a limit to my loyalty.
And that limit is reached today. For the past few days, it has becoming unreliable, from arbitrarily marking things as unread, to the website simply not loading (try click on the link and you will see—it's been that way for a day now that I'm sure by the time you click on it, it would still be down).
I'm the kind of person who has low expectations and high tolerance for pain. And I tend to stick with a company long past the point where everyone else have switched. One of the things that we say at home is "If they piss off even us, they won't remain open for long."
So, it's "Goodbye, Bloglines.com. And thanks for all the feeds."
And please keep this in mind as I keep on talking about Windows 3.1, COM, and Java.
[Update] And of course, minutes after I posted this blog entry, Bloglines.com came back to life.
Friday Is Almost Over, But We Can Always Have A Late Quiz...
(Courtesy of crazybob.)
Bob Lee: Java: interface A extends B {} interface B extends A {} ⇒ javac says, "Error: cyclic inheritance." That's a good one for Weiqi.6 minutes ago from twitterrific
Q: What happens when you compile the two files:
// A.java
public interface A extends B {
}
// B.java
public interface B extends A {
}
If the answer is obvious, try this: Change B.java into a marker interface then compile A.java. Put the class file aside. Do the same for B.java. Then bring both class files together.
Q: Will the following code compile against such A.class and B.class?
// C.java
public class C implements A, B {
}
Randall Hauch: JBoss DNA
Just got back from the St. Louis JUG. Randall Hauch of Red Hat gave a presentation on JBoss DNA.
JBoss DNA is a Java Content Repository (JCR) implementation whose major differentiation feature is its federated repositories.
OpenDDS 1.2 Released
Jonathan has announced a new release of OpenDDS, an open source C++ implementation of the Object Management Group (OMG) Data Distribution Service (DDS) by OCI.
OpenDDS.org:Version 1.2 Released
We are pleased to announce the release of OpenDDS version 1.2!
- Java Bindings for OpenDDS
- Added the ability for using multiple repositories to provide redundant service metadata management
- Implemented the WaitSet, GuardCondition, and StatusCondition interfaces from the OMG DDS specification
- Implemented DomainParticipant::get_current_time() from formal/07-01-01
- Removed requirement for repository domain specification files
- Internal service Entity identifiers have been expanded to 128 bits
- dcps_ts.pl changes
- DCPSInfoRepo changes
- Fixed bug in DCPSInfoRepo that did not re-evaluate the compatibility and associations when QoS change is made
- Fixed bugs that affected connection establishment
- Added datalink_release_delay and removed keep_link configuration
- Fixed a potential deadlock in reliable multicast transport
See the Release Notes for details.
JavaFX: December 2
(Via Patrick Wright on the JavaPosse Google Group.)
This Ain't Your Dad's Java (podcast, 4:36—7:25, transcripted):
Unless you are Korean or read Korean press, you'll hear it hear first. At the Sun Tech Days in Korea Rich and I decided to announce the date that FX would ship to the public. It never got picked up outside of Korea. Even though there were 2000 people and I was waiting to see for it to get piked up but it didn't. I'm going to say it again here and see it if get picked up this way. We quietly say it in a number of places then we try to figure out when people figure it out.
We actually announced that we are going to ship FX Desktop 1.0 on December 2. We have an event planned in San Fransisco. We are on track for the deliverable. We felt like it was great to make the announcement overseas as opposed to doing it in the US and give all of our partners in Korea a "you heard it here first."
So this is technically "you heard it here second," the first time in English, maybe, ... So we are going to ship on December 2. Again the engineering team is on track. We had originally hoped to get it out a little bit earlier then this. We were still within the window we set to the public at JavaOne. But we've found a couple of issues we want to look around media performance, and just getting the frame rate and a couple of things up just even beyond what the minimum requirement would be, but to what we as real Java developers would want.There are a couple of things we want to do: a little polish time, quite honestly on the marketing side we've been working on our web site. If you've been to Javafx.com, ... we sort of did JavaFX.com, initially delivered at JavaOne. It was really a gorrila effort. It was actually done out of our engineering organization. It was sort of a labor of love of just a few folks. We've got a lot feedback from users about that site, it usability, readability, all that good stuff, things that were not shocking to us.
So we've actually gone off and designed a full beautiful site. It' very pretty. It's actually turned out really really well. So I think when JavaFX.com re-rolls out, gets its update, people will really like not only the visual changes we've made to the site but the content of it. It's top notch.
People have been just busting their butts inside the building to get that ready. On December 2 FX really goes out of the door. It's truly an 1.0 product. We are all really really excited about it.
They didn't mention it, but I think they meant December 2, 2008.
Curious Development: Microsoft Joins...
... the AMQP Working Group.
(Via INfoQ.)
Microsoft Press Release, Oct. 24, 2008: Microsoft Corp. today announced that it is joining the Advanced Message Queuing Protocol (AMQP) Working Group...
Given that the goal of AMQP is to commodities message queuing products by standardizing on a wire protocol and a programming model, and that 29 months after the original announcement (as I reported 870 days ago) of the intent to publish AMQP 1.0 within 18 months, AMQP 1.0 hasn't been finalized, I believe this move by Microsoft, a proprietary messaging product vendor, means only one thing:
- (I'm drawing a blank. Help me, internet!)...
This much is clear, with Microsoft in, IBM will have to join. And you know what results when Microsoft and IBM collaborate!
Can They Do That?
I know the television networks like to make projections when only a few percentage of the votes are reported. But look at these screenshots I grabbed off of ABC and Fox News. Are you allowed to make projections with 0.0% of precincts reporting and each candidate has gotten 0% of the votes?
Tue 04 Nov 2008 07:11:24 PM CST
Tue 04 Nov 2008 07:01:15 PM CST
Another Day, Another Blogger Turns Twitterer
Is the writing on the wall for the demise of the blogosphere?
Jython 2.5 Beta0 Released
Frank Wierzbicki: Happy Halloween! On behalf of the Jython development team, I'm pleased to announce that Jython 2.5b0 is available for download. See the installation instructions.
Jython 2.5 Beta0 is the beginning of a code cooling period where the number of new features should significantly slow as we concentrate on solidifying Jython 2.5 for an eventual release. There are still a number of features that we will squeeze in (like jythonc).
This is a beta release so be careful.
I tried it out on my Debian GNU/Linux 4.0 x86_64 machine with OpenJDK 6. Everything from my March 2001 JNB article on Scripting Languages for Java still works, including the Turtle example:
Oh, boy. This brings back old memories. That article was listed on the old Jython website as the first few "press mention" of Jython. That was five months after the Jython project was announced. And the jython interpreter bore this version number:
Jython 2.0 on java1.2.2 (JIT: sunwjit)
While the jython folks were thrilled that they got anther press mention, I was thrilled to be called "press". Of course at the time I have no way of knowing that Jython will go through several years of slow progress. I am very happy to see the attention Jython has gotten lately and am looking forward to Jython 2.5 final release early next year, and the Jython 3.0 that's going to come after.