Posts from July 2009

Google Summer of Code Flocks Together

Tuesday, July 28, 2009

One of the great things about Google Summer of Code™ is that it's a great way to meet other Open Source-minded people. Not only do students get paired with their mentors, but students get to know each other, as do mentors and project administrators.

Last month, Leslie Hawthorn, Cat Allman, and I attended the Google Summer of Code Birds of a Feather session at Open Source Bridge, organized by Jonathan Leto. We had the pleasure of meeting with Google Summer of Code students, mentors, admins, and potential participants to discuss what works, what doesn't work, and ways the program could be improved. We got some great feedback, and best of all, we had the opportunity to interact face to face with participants instead of solely via email, mailing lists, or IRC! You can see a photo and read more about the meetup on Jonathan's blog post about the event.

Last week, the Open Source Programs Office outreach team met with more Google Summer of Code participants at our BoF session at OSCON. Our session extended late into the night with some really interesting discussions about how to help students succeed in computer science.

If you would like to know about upcoming Google Summer of Code meetups, please join our meetups mailing list - we'd love to meet you!

Programming made Simple!

Monday, July 27, 2009

In the 90s, a big company from up north was extremely successful with a dialect of the programming language BASIC (acronym for Beginner's All-purpose Symbolic Instruction Code). One of the reasons it was so successful was that the language was easy to learn and use.

Bringing an easy to learn and use language to the mobile world and the Android platform is the goal of the Simple project. Simple is a BASIC dialect for developing Android applications. It is particularly well suited for non-professional programmers (but not limited to). Simple allows programmers to quickly write Android applications by using the components supplied by its runtime system.

Similar to its 90s relative, Simple programs are form definitions (which contain components) and code (which contains the program logic). The interaction between the components and the program logic happens through events triggered by the components. The program logic consists of event handlers which contain code reacting to the events. In reality it is even simpler than this description.
Let's see how simple it really is. We will quickly write a program simulating the famous Etch-A-Sketch on an Android device. Tilting the device will move the pen, shaking the device will clear the screen. The Simple runtime system gives us three components to provide most of the needed functionality:
  1. the Canvas component - for drawing
  2. the OrientationSensor component - to detect tilting
  3. the Accelerometer component to detect shaking
Let's take a look at the source code for this application:

Dim x As Integer
Dim y As Integer

Event OrientationSensor1.OrientationChanged(yaw As Single, _
pitch As Single, roll As Single)

If roll < -20 Then
x = Math.Min(Canvas1.Width, x + 1)
ElseIf roll > 20 Then
x = Math.Max(0, x - 1)
End If
If pitch < -20 Then
y = Math.Min(Canvas1.Height, y + 1)
ElseIf pitch > 20 Then
y = Math.Max(0, y - 1)
End If
Canvas1.DrawPoint(x, y)
End Event

Event AccelerometerSensor1.Shaking()
End Event

The code defines two global variables (lines 1 and 2) and two event handlers, one to handle changes in the device's tilt (lines 4 to 17) and another to handle shaking of the device (lines 19 to 21). The code in the first event handler makes sure to only react to tilting above a certain degree (lines 6, 8, 11 and 13), and if that is the case then it further ensures that the pen does not run off the drawing surface (lines 7, 9, 12 and 14). And finally a point is drawn at the pen position (line 16). As for the other event handler, the only thing it does is clearing the drawing surface in case of shaking (line 20).

Last part missing is the form definition. It defines the form and its properties (lines 24 to 27), followed by the components it contains (lines 28 to 33).

$Source $Form
$Define EtchSketch $As Form
Layout = 3
BackgroundColor = &HFFFFFFFF
Title = "EtchSketch: Tilt to draw - Shake to clear"
$Define Canvas1 $As Canvas
$End $Define
$Define OrientationSensor1 $As OrientationSensor
$End $Define
$Define AccelerometerSensor1 $As AccelerometerSensor
$End $Define
$End $Define
$End $Properties

That's it. The only thing left to do is to compile and deploy the application to an Android device. And voila, here is a screenshot of the application running:

For a definition of the Simple language see the Simple Language Definition (download, 199 KB PDF). For more information on writing Simple applications see the open source project page at You can also find information there on contributing to the project, and we encourage you to join our discussion list to provide us feedback.
Programming made Simple!

Midterm Report on Google Summer of Code

Saturday, July 25, 2009

(click on graph to enlarge)

Thursday at OSCON, Leslie Hawthorn gave an update on the state of the 2009 Google Summer of Code program. One of the points that she shared with the audience was the 93% student success rate as of midterm evaluations, which were submitted July 13th. Congratulations to our students, mentors, and admins for all their hard work! Based on our mentor survey, most of our students are doing well, with a few students already finishing their project!

For the rest of the students, the summer is not over yet and there is still lots of coding left to do. I hope that this year will be our most successful to date! Read the statistics about previous years here.

By Ellen Ko, Open Source Team

Congratulations to the Winners of the Google O'Reilly Open Source Awards

Wednesday, July 22, 2009

Yesterday evening, I was privileged to share a stage with OSCON Co-Chair, Allison Randal to present the 5th Annual Google O'Reilly Open Source Awards. We once again opened nominations to the Open Source world at large and we were pleased at the fantastic response we received from the community. From the hundreds of nominations we received, after much deliberation these five individuals were selected:

Our Award Winners & Presenters (listed from left to right):

Brian Aker, Leslie Hawthorn, Evan Prodromou, Bruce Momjian, Allison Randal, Nat Torkington
Photo Credit: Pinar Ozyger

Congratulations to Brian, Bruce, Clay, Evan and Penny! Each of them will receive a beautiful (and shiny!) glass statue, along with a 5000 USD cash prize in support of their Open Source development efforts.

The awards are just one part of Google's participation in OSCON 2009. If you're around, come find us, introduce yourself and share your thoughts on all things Open Source.

Where to Find Us at OSCON 2009

Monday, July 20, 2009

OSCON has returned to the San Francisco Bay Area for 2009, and Googlers will once again be out in force to spread the joy of all things Google and Open Source. Please make sure to join us on Tuesday, July 21st for the conference opening ceremonies, where we'll announce the winners of the 5th Annual Google O'Reilly Open Source Awards. If you've already arrived for the conference, you may want to stop by our Birds of a Feather session for the Google Summer of Code™ community this evening at 8:00 PM. We're also proud to feed all of you in the great Google tradition at Wednesday's lunch.

And, of course, there will be several talks and tutorials delivered by Googlers, including:

If you're around Silicon Valley and can't make the entire conference, keep in mind that the Birds of a Feather sessions, OSCamp and a host of other events at OSCON are free of charge to attend with your expo hall registration. We hope to see you there!

Crossing the Desktops in Gran Canaria

The Gran Canaria Desktop Summit ended just a few days ago, and now everyone is back to work sun-tanned and/or sun-burnt, but loaded with new ideas. The idea behind this summit was to organize GUADEC and aKademy, the yearly GNOME and KDE conferences, on the same spot so that developers from the two communities could get together and more freely exchange ideas.

The series of keynotes that opened the event was particularly interesting with, among others, Robert Lefkowitz sailing between computers and philosophy and, of course, Richard Stallman dressed up as St. IGNUcius.

We were given the chance to darken our hacker-pale skin a tiny bit thanks to the green towel that was offered to each participant. GNOME and KDE hackers alike delivered many keynotes and talks, especially cross-desktop talks to help explore and overcome problems encountered in both projects). Hacking and chatting on the beach was another popular conference activity.

All in all, one always comes back from such an event with starry eyes and a dreamy mind about the exciting (very near) future of the two desktops, and their tightened collaboration. Stay tuned for a lot of hot things happening soon in a desktop near you, and let's hope that next year's event will bring us the same amount of excitement and sunshine!

Releasing Debug Panel for GWT

Wednesday, July 15, 2009

A few years ago, we released GWT, the Google Web Toolkit, which allows code to be written in Java using your favorite editors and then compiled into JavaScript that runs smoothly on host browsers. Today, we're releasing some additional debug tools to make troubleshooting easier. See the post on the GWT blog for more details!

Making Beautiful Music Together

Tuesday, July 14, 2009

Google's Open Source Programs Office has been supporting the MetaBrainz Foundation for the last three years and has just let us know that they'll be continuing their support in 2009. The MetaBrainz Foundation operates the MusicBrainz project, which can be likened to Wikipedia for music. MusicBrainz knows which artists have released which CDs as well as where and when they were released. MusicBrainz also knows all of the tracks as well as who performed which instrument or vocals on a given track. This and many other data pieces are made available to the public and form the underpinnings of services such as audio CD identification and digital music collection cleanup tools.

Last year, Google's generous donation paid for a much needed server and it allowed us to hire our Google Summer of Code™ student (Oliver Charles) part time after the program wrapped up. The donation also helped pay for mundane things like keeping the lights on, backup disks and paying for insurance. But the most fun part that we spent money on last year was our phenomenal MusicBrainz Summit in London. Our summit allowed the community to come together and to bond face to face at the offices. MusicBrainz paid for its Summer of Code students to come to London from Sweden, Germany and Lancaster. MusicBrainz arranged for the summit space, subsidized accommodations and provided food. But, most important was our gathering at a pub near the offices — we had fun and bonded for many hours that evening.

Holding yearly summits has been a long tradition for MusicBrainz. We're planning on having another one this year and this year's donation will certainly help make this one memorable as well!

Thanks for your continued support Google!

Brazil Open Source Jam 2

Monday, July 13, 2009

On July 2nd, 2009 about 50 people gathered in our Belo Horizonte, Brazil office for the second edition of the Open Source Jam Brazil. Guests were welcomed with an aperitif of snacks and drinks. At about 19:00 we started a round of short talks on various topics.

Scott Kirkwood presented his Convertsy Wave Robot and gave a short introduction on how to write robots for Google Wave. Ricardo Bittencourt spoke about implementing an MC-1000 emulator on FPGAs. Rafael Sachetto Oliveira talked about his Ubuntu Simple Package Crawler project and demonstrated Web USPC. Fabrício Ceolin reported on integrating government software, CACIC, with Intel vPro technology. Licio Fonseca introduced the audience to GNOME Love, a project to help new contributors to the GNOME project, and Germano Teixeira de Miranda talked about speeding up cloning computers with Recuperao de Imagem de SO.

After the talks we had almost two hours to talk to one another and get some more snacks, including ice cream. The Brazilians are known for being quite sociable, and this quality was made very clear in the strength of its Open Source community; developers, enthusiasts and Google engineers shared their projects and ideas, and some even found new projects to work on together. The evening came to an end at about 22:00 when most people left.

Google Open Source Jam events are getting increasingly popular. It took less than 12 hours for the 50 attendees to sign up for this second Open Source Jam in Brazil, so join the Open Source Jam Brazil Google Group to stay updated on future events as soon as they are scheduled. Open Source Jams are hosted by the Google Open Source Team.

Releasing Neatx, an Open Source NX Server

Tuesday, July 7, 2009

We at Google have been looking at remote desktop technologies for quite a while. The good old X Window system can be used over the network, but it has issues with network latency and bandwidth. Neatx remedies some of these issues.

In 2003, NoMachine released a large portion of the source code of their NX product under the GPL licence. NX is a protocol compressing X requests and reducing round-trips. Although mostly Open Source, NoMachine's NX product contains one closed component, the NX server. It's the part connecting clients with the Open Source libraries doing the work.

A free implementation of an NX server based on NoMachine's libraries named FreeNX was published in 2004 by Fabian Franz. FreeNX's primary target is to replace the one closed component and is written in a mix of several thousand lines of BASH, Expect and C, making FreeNX difficult to maintain.

Last week, we released the source code of our own proof-of-concept implementation of an NX server, Neatx. Designed from scratch with flexibility and maintainability in mind, Neatx minimizes the number of involved processes and all code is split into several libraries. It is written in Python, with the exception of very few wrapper scripts in BASH and one program written in C for performance reasons. Neatx was also able to reuse some code from another Google Open Source project, Ganeti. The code still has some issues, but we're confident interested developers will be able to fix them.

Also, Neatx implements features not found in FreeNX, such as the drop-down menu for session control in rootless sessions. At the same time, not all of FreeNX's features are implemented in Neatx.

Michael Hanselmann gave a presentation at FISL 10 in Porto Alegre, Brazil describing our implementation and use of virtual workstations (slides: PDF, 200 KB).

More information and the code can be found at the Neatx project. You can also send us questions and feedback on the Neatx discussion list. Happy hacking!

London Open Source Jam 13

Thursday, July 2, 2009

Here in London, we recently hosted London Open Source Jam 13 (Our 14th jam, as naturally we count from zero.) - unlucky for some, but not for us! We threw the floor open to talks of any kind and we had a bumper crop of lightning talks on a diverse range of topics. We learned how to make a wiki in 58 lines of python, why open source developers should care about open standards, some new approaches to database design, and a whole lot more.

Kai Hendry talked about Webconverger, a teeny weeny Linux Live CD designed for web kiosks, and his experience commercialising an open source project by offering services to go with it.

Zak Cohen shared his experiences using open source libraries in the games world in developing the award-winning game Climbactic. It turns out there's some great open source stuff out there, but sometimes paying for support is the only way to get the features you need.

Frederik Dohr and Mike Mahemoff spoke about TiddlyWeb, a generic RESTful store for structured data, and Scrumptious, a jQuery-based web app that allows people to annotate and comment on web pages, which uses TiddlyWeb for storage.

Other contributors included:
The OSJam website has more information about all the talks, and the photographs taken at the event are available on Picasa Web Albums.

We'll be planning the next OSJam for a couple of months' time - subscribe to the London Open Source Jam Group or keep any eye on the OSJam website (Atom feed) for more details.

By Malcolm Rowe and Matt Godbolt, Software Engineering Team

Google Update, regularly scheduled

Wednesday, July 1, 2009

Client software products have unique challenges, with one of the important challenges being keeping the product up to date. Deploying critical security fixes in a timely and effective manner is one key way that we help keep users secure. Another benefit is that cool new features get deployed and adopted quickly. Google Update is the shared updating infrastructure used by Google Chrome, Google Earth and other Google software that runs on PCs to keep our products up to date on users' computers.

A couple of months ago we released the Google Update source code to give users and developers transparency into our update mechanism. One month later, we released Update Controls that allowed network administrators and advanced users the ability to control the installation and updating of Google products via Google Update.

We hope to help address concerns users have voiced around Google Update running as a continuous process. Until now, Google Update would always run in the background, functioning primarily as a reliable scheduler performing update checks at periodic time intervals. With today's release, Google Update now uses the Windows Task Scheduler to only run at periodic intervals. We have worked hard to ensure that automatic updates work just as reliably, and that our users are just as safe and secure as before.

There are a couple of details that we want to mention. First, in a very small number of cases when Google Update determines that the Windows Task Scheduler or Service mechanisms are not working as expected, we have added in fallback mechanisms that cause Google Update to begin running as a continuous process again to ensure users are still receiving updates to their Google software. Second, if you opted in to sending anonymous usage statistics and crash reports to Google for a particular Google application, we will run a process in the background called GoogleCrashHandler.exe. GoogleCrashHandler.exe is responsible for reporting crashes to Google when they occur in your Google product.

by S. Ganesh, Google Update Team

Introducing Apache Commons Math SimplexSolver

SimplexSolver is an easy-to-use, object-oriented method of solving linear programming problems. We're happy to announce today that we've Open Sourced the code that runs the newly released Google Spreadsheets Solve Feature and made it a part of Apache Commons Math 2.0.

While numerous other libraries are available that run linear optimization problems, SimplexSolver is the first written in Java with a commercially-friendly license.

Let's say we have the following LP:

MIN -2x + y - 5
x + 2y <= 6
3x + 2y <= 12
y >= 0

We could solve the problem in Java using the SimplexSolver:

// describe the optimization problem
LinearObjectiveFunction f = new LinearObjectiveFunction(new double[] { -2, 1 }, -5);
Collection constraints = new ArrayList();
constraints.add(new LinearConstraint(new double[] { 1, 2 }, Relationship.LEQ, 6));
constraints.add(new LinearConstraint(new double[] { 3, 2 }, Relationship.LEQ, 12));
constraints.add(new LinearConstraint(new double[] { 0, 1 }, Relationship.GEQ, 0));

// create and run the solver
RealPointValuePair solution = new SimplexSolver().optimize(f, constraints, GoalType.MINIMIZE, false);

// get the solution
double x = solution.getPoint()[0];
double y = solution.getPoint()[1];
double min = solution.getValue();

Looking at the LP problem and Java code side-by-side, we can see how easy it is to describe the problem in the Apache Commons Math API. More examples can be viewed in the SimplexSolverTest source code. Apache Commons Math 2.0 is not quite released yet, so for the time being if you want to use the SimplexSolver, you'll need to compile it from source.

So that's SimplexSolver: a clean, fast method of solving LP problems. We hope you like it as much as we do! Thanks to Luc Maisonobe and the rest of the Apache Team who helped integrate the SimplexSolver into the Apache codebase.