I got a good chuckle when I read about Ozzie Guillen's latest tirade. This is just sweet justice. They so deserve to stink. Their lineup is full of the kind of players that ruin your team. Their love affair with small ball has their roster full of guys who can't take a pitch and just make outs constantly. Guys like Scott Podsednik, Darin Erstad, and Jerry Owens. They've gotten about what you would expect out of Jim Thome, Paul Konerko, and Jermaine Dye, but I'm sure that's where the blame will fall. The only guy in their whole lineup who has any plate discipline is Thome. He's had a slightly subpar year by his standards, but he's 37. What can you expect? They are dead last in the AL in runs scored, but this exactly what they should have expected. They're also dead last in OBP at .317 (!!!) -- funny that.
Their pitching has been bad, too. John Garland has been a little worse than you might have expected, and Jose Contreras has been truly awful. Mark Buehrle and Javier Vazquez have been about what you would expect. Their bullpen has been bad except for Bobby Jenks. Again most of these guys haven't been any worse than you would expect.
So yeah the White Sox are really bad, but they should be really bad. Their management put together a bad team. Who knows how much of that equation is Guillen. He's certainly shown a love for putting fast guys with no patience at the top of his batting order, and that is a major reason for their terrible offense.
Thursday, August 30, 2007
Wednesday, August 29, 2007
HTTP Request Headers and Flash
I've been doing a lot of Flash/Flex work over the past few months. I recently had a colleague ask me if a SWF embedded in a page has access to the cookies for that domain. I knew the answer was no, and said as much. Then I started thinking, that just seems wrong. Why doesn't a SWF have access to cookies, and for that matter, all the HTTP headers that were sent as part of the request for the SWF?
It's easy to create a simple page with a SWF embedded in it and load up Firebug to watch the HTTP traffic. I created a simple two page app to experiment with this. On the first page, I used so JavaScript to write a cookie. By the way, this is annoyingly mundane. I know there are JS libraries for abstracting this and providing a clean API, but you would think that IE or Mozilla would have added an extension to JavaScript that does exactly this. Having to do document.cookie.indexOf(...) and document.cookie.substring(...) all the time is just ridiculous.
Back to the app. After setting some cookies, there is a link that goes to page two. Page two includes an embedded SWF. Watching the traffic on page two, I could clearly see cookies, user-agents, referrers, etc. all being sent as part of the HTTP request for the SWF. One interesting thing is that the referrer was page two, not page one. That makes sense, though.
So everything is clearly there, it's just not available to the SWF runtime. Any parameters on the query string are available. In Flex you can get to them using Application.application.parameters. This gives you a classic ActionScript Object, i.e. an associative array. So if you put the URL for the SWF as http:///widget.swf?foo=bar then you can write AS code like Application.application.parameters.foo. So not all of the HTTP request is being thrown away, though the headers certainly are.
All I can think of is that this is a security issue. It creates other potential security problems though. Imagine if page one in my app was a login page, and page two was some kind of personalized home page. A lot of websites use cookies for authentication, and that authentication is not being passed to the SWF. What's a developer to do? There are lots of options, but you can imagine some very unsavory and horribly insecure ones.
Anyways, I thought maybe I was wrong all along, and just didn't know what I was talking about. It certainly wouldn't be the first time, and especially considering I didn't know any Flash 12 months ago. So I posted the question on Flexcoders... It's been about 24 hours with no responses, which usually means nobody knows the answer.
It's easy to create a simple page with a SWF embedded in it and load up Firebug to watch the HTTP traffic. I created a simple two page app to experiment with this. On the first page, I used so JavaScript to write a cookie. By the way, this is annoyingly mundane. I know there are JS libraries for abstracting this and providing a clean API, but you would think that IE or Mozilla would have added an extension to JavaScript that does exactly this. Having to do document.cookie.indexOf(...) and document.cookie.substring(...) all the time is just ridiculous.
Back to the app. After setting some cookies, there is a link that goes to page two. Page two includes an embedded SWF. Watching the traffic on page two, I could clearly see cookies, user-agents, referrers, etc. all being sent as part of the HTTP request for the SWF. One interesting thing is that the referrer was page two, not page one. That makes sense, though.
So everything is clearly there, it's just not available to the SWF runtime. Any parameters on the query string are available. In Flex you can get to them using Application.application.parameters. This gives you a classic ActionScript Object, i.e. an associative array. So if you put the URL for the SWF as http://
All I can think of is that this is a security issue. It creates other potential security problems though. Imagine if page one in my app was a login page, and page two was some kind of personalized home page. A lot of websites use cookies for authentication, and that authentication is not being passed to the SWF. What's a developer to do? There are lots of options, but you can imagine some very unsavory and horribly insecure ones.
Anyways, I thought maybe I was wrong all along, and just didn't know what I was talking about. It certainly wouldn't be the first time, and especially considering I didn't know any Flash 12 months ago. So I posted the question on Flexcoders... It's been about 24 hours with no responses, which usually means nobody knows the answer.
Michael Galpin: May 9, 1974 - October 14, 2007
It's official. I'm going to die on October 14, 2007. That's the date of the San Jose Rock n' Roll Half-Marathon. I've been training for it for a couple of months now, and I've stepped that up recently. I did a 10-Mile run about a month ago, and that was definitely a huge physical challenge. I've got less than six weeks to get ready for 13 miles! Definitely going to die...
Saturday, August 18, 2007
iWork '08 Stupidity
I downloaded the trial of iWork '08 last week. I would really like to stop using MS Office on my MacBook. I had a new IBM article I needed to start working on, so I figured one good way to see if I could switch to iWork would be to use Pages to write the article. It's an easy test really, since I don't do anything too complex.
I was working on the article on the plane this morning. When we were about to land in Dallas, I saved my work and closed iWork. I'm going to be in Florida for the next week, so I decided to switch over my time to central, as Dallas is also in the central time zone. So I did that.
Now I'm sitting at my gate with a two hour layover. I decided to do so more week after I ate lunch. I put together a nice graphic in Pages, where I overlayed a screenshot and drew on it to highlight important parts of the screen. This is something I usually use a separate program for because it's awkward in Word. I was able to do it easily in Pages. The thought went through my head "Word, your days are done."
I was so happy with this accomplishment that I hit CMD-S to save my work. I got some cryptic message about not being able to save unless I either entered a serial or began a trial. I clicked trial, and it told me that my 30 day trial had ended. Thus I could not save my work.
WTF!?!?! The stupid program hasn't even been out for 30 days. I'm assuming that it did this because I had tinkered with my date (changing the time zone) earlier. This indicates several layers of stupidity. First, iWork is verifying the trial against the clock on the computer. I didn't think anybody was dumb enough to do that anymore because it's so easy to circumvent. Oh, but Apple is smart. They're also doing a check to see if you mess with the date/time. Only problem is that their cleverness isn't clever at all. Changing timezones caused a false positive.
At this point I did consider going ahead and buying iWork. I figured I'm probably going to do it anyways. I just couldn't do that though. It would be like I had been bait-n-switch'ed. Apple broke their part of the deal (letting me use their product for 30 days) and I was supposed to now pay them for this? There's no way I could do that. I might not even buy iWork at all now.
So instead I opened up Word, and copied the document over to it. Luckily I wasn't too far along, so it wasn't too hard to re-assemble or reproduce the non-text parts (like tables, code samples, and the infamous screenshot.)
I was working on the article on the plane this morning. When we were about to land in Dallas, I saved my work and closed iWork. I'm going to be in Florida for the next week, so I decided to switch over my time to central, as Dallas is also in the central time zone. So I did that.
Now I'm sitting at my gate with a two hour layover. I decided to do so more week after I ate lunch. I put together a nice graphic in Pages, where I overlayed a screenshot and drew on it to highlight important parts of the screen. This is something I usually use a separate program for because it's awkward in Word. I was able to do it easily in Pages. The thought went through my head "Word, your days are done."
I was so happy with this accomplishment that I hit CMD-S to save my work. I got some cryptic message about not being able to save unless I either entered a serial or began a trial. I clicked trial, and it told me that my 30 day trial had ended. Thus I could not save my work.
WTF!?!?! The stupid program hasn't even been out for 30 days. I'm assuming that it did this because I had tinkered with my date (changing the time zone) earlier. This indicates several layers of stupidity. First, iWork is verifying the trial against the clock on the computer. I didn't think anybody was dumb enough to do that anymore because it's so easy to circumvent. Oh, but Apple is smart. They're also doing a check to see if you mess with the date/time. Only problem is that their cleverness isn't clever at all. Changing timezones caused a false positive.
At this point I did consider going ahead and buying iWork. I figured I'm probably going to do it anyways. I just couldn't do that though. It would be like I had been bait-n-switch'ed. Apple broke their part of the deal (letting me use their product for 30 days) and I was supposed to now pay them for this? There's no way I could do that. I might not even buy iWork at all now.
So instead I opened up Word, and copied the document over to it. Luckily I wasn't too far along, so it wasn't too hard to re-assemble or reproduce the non-text parts (like tables, code samples, and the infamous screenshot.)
Thursday, August 16, 2007
Have MacBook, Will Travel
Saturday I'm flying to Florida to visit family. I'm planning making heavy use of my MacBook both on the flight and in Florida. The thought occurred to me that maybe I should buy one of Apple's MagSafe power adapters that work on the airplane. Reading the reviews on Apple's site was very useful. Here's what I learned:
- First, make sure your airline seat has a power outlet. This turns out to be easy. Just go to SeatGuru. This is an awesome site! For me, I looked up my flight on American Airlines (I needed the confirmation code, but that was included in my itinerary on Expedia.) For each flight, I could look at the Flight Details and see what kind of plane it would be. I then went to SeatGuru, picked airline, and then picked plane model. You get a map of the seats with not only information on what seats have power outlets, but also other info like "this seat doesn't tilt back" or "it gets cold or loud here" etc. Very nice! I found out that neither of the seats on my two flights (coming and going) had power outlets, but I could change my seat assignment on American Airlines' site and pick seats that did!
- Next, the Apple airplane adapter does not provide much juice! It will not re-charge your laptop, and in some cases you will continue to drain your battery albeit at a slow rate. So if you're going to use it, start using it as soon as you get out your Mac. Don't wait until you get the warning about being low on juice.
- Finally, the adapter has a removable tip of some sort that allows it to work with different kinds of outlets used by different airlines. This tip is a major source of problems because you can pull the adapter out of the outlet, and the tip remains behind. Many people have left their tips behind, forcing them to buy a new adapter ($60.)
Tuesday, August 14, 2007
Silicon Valley Millionaires
There's been a lot of talk about this article in the NY Times and once again I felt compelled to join the echo chamber. The thing that struck me about this was how the NYT spun things.
On one hand, we have hard-working professionals who have made a lot of money. They made a lot of money, and yet they continue to work hard. They continue to worry about sending their kids to college. They drive modest cars and live in modest homes. In short, they made a lot of money and it didn't change them.
How is this bad? If you make a lot of money you're supposed to suddenly not want to work, not care about your kids, and live lavishly?So that would be good, and continuing to work hard and living modestly is bad?
Then the article is littered with statements like "People around here, if they have 2 or 3 million dollars, they don’t feel secure" ... Ouch. But who said that? Maybe it was an engineer at a startup? Or maybe it was a salesman at large software company? Nope. That quote (and another similar one) are from an estate planner. That's right it's a quote from a guy whose job is to tell people they need to worry about their ... financial security.
Now I can't forget another quote that's the big finale of the article: "Here, the top 1 percent chases the top one-tenth of 1 percent, and the top one-tenth of 1 percent chases the top one-one-hundredth of 1 percent." Now who said this? This time it's from a serial entrepreneur. Clearly that's a good source for a generalization about the millions of people in The Valley.
Look, I don't expect the NYT to understand The Valley. This is a very unique place. There's a lot of smarts and a lot of money. The thing is that both of those ingredients are necessary and you have to understand both to have any hope of understand The Valley. It's easy for outsiders to concentrate on the money and try to explain everything. So if rich people are working hard it must be because they feel like they aren't rich enough, right? Um, no...
On one hand, we have hard-working professionals who have made a lot of money. They made a lot of money, and yet they continue to work hard. They continue to worry about sending their kids to college. They drive modest cars and live in modest homes. In short, they made a lot of money and it didn't change them.
How is this bad? If you make a lot of money you're supposed to suddenly not want to work, not care about your kids, and live lavishly?So that would be good, and continuing to work hard and living modestly is bad?
Then the article is littered with statements like "People around here, if they have 2 or 3 million dollars, they don’t feel secure" ... Ouch. But who said that? Maybe it was an engineer at a startup? Or maybe it was a salesman at large software company? Nope. That quote (and another similar one) are from an estate planner. That's right it's a quote from a guy whose job is to tell people they need to worry about their ... financial security.
Now I can't forget another quote that's the big finale of the article: "Here, the top 1 percent chases the top one-tenth of 1 percent, and the top one-tenth of 1 percent chases the top one-one-hundredth of 1 percent." Now who said this? This time it's from a serial entrepreneur. Clearly that's a good source for a generalization about the millions of people in The Valley.
Look, I don't expect the NYT to understand The Valley. This is a very unique place. There's a lot of smarts and a lot of money. The thing is that both of those ingredients are necessary and you have to understand both to have any hope of understand The Valley. It's easy for outsiders to concentrate on the money and try to explain everything. So if rich people are working hard it must be because they feel like they aren't rich enough, right? Um, no...
Thursday, August 09, 2007
The Age Question
I've avoided joining the echo chamber on the question of age and entrepreneurs, but then Marc Andressen wrote something really interesting about it. One of the important "scientific" conclusions he sites is that in some disciplines (math, physics) people peak in their late 20's to early 30's, but in others (writing, history) they peak much later, in their 40's or even 50's. So then the question becomes are entrepreneurs more like mathematicians or historians?
Of course most people would say that entrepreneurs are more like mathematicians, so the younger the better. I will argue that entrepreneurs are nothing like mathematicians and physicists, but that does not mean that they are not more like those types than they are like historians and writers.
First some disclaimers. I have a degree in mathematics, and like to humor myself by considering myself a mathematician at my core. Truth is that I am a software engineer, a very different discipline, and I cannot deny this.
Ok, first off entrepreneurs are completely full of themselves for trying to enter this kind of comparison. By even making these analogies, you are equating the creativity and skill of scientists and scholars with the ... attributes ... of entrepreneurs. This is ridiculous. It is like trying to compare the skills of a microsurgeon with the skills of a race horse. It just doesn't make any sense.
Entrepreneurs definitely have creativity, intelligence, and skill, but it is not of the same species as scientists and scholars. Entrepreneurs have any measurement of their prowess: money. If their ideas make money, they are good ideas. If they do not make money, they are not good ideas. It's painfully simple.
Scientists and scholars are held to very different standards. Now it is true that scientific endeavor is open to experimentation and verification, a kind of litmus test similar to the success or failure of an entrepreneur's business. But a lot of the really great scientists have theories that are so theoretical and advanced that they cannot just be easily verified in a lab experiment. Similarly mathematicians must write proofs of their theories. These proofs must judged both objectively and subjectively by peers. Of course scholars have no "out" in terms of being proven right or wrong. Thus they all share something similar: their success is measured in the near term by the scrutiny of the most brilliant minds in the world.
This is a kind of scrutiny that no entrepreneur can experience. If the top two dozen computer scientists all thought that Google had a great search engine eight years ago, it would not have meant anything for Google. If those same elite scientists decided Google was crap, again it meant nothing.
The other flip side to the world of science and scholarship is that the very peers who decided your success or failure, are often wrong. That's why there are numerous examples of scientists whose work is not appreciated until after their death.
I could easily make arguments about how scientists and scholars have to be so much "smarter" than entrepreneurs, but I think just looking at the criteria for success is sufficient.
Again, given my background in mathematics, I have a little insight into why mathematicians peak in their late 20's or early 30's. The obvious reason is that solving highly theoretical problems requires tremendous time and submersion into you work. This is true, but it's only part of the reason. The other reason is that to solve those kind of problems, you need to have very little else to think about. I'm not talking about things outside of your work and study, I'm talking about things inside it.
As you progress in any field, you absorb more and more knowledge. This knowledge is tapped in some way, even if subconsciously, whenever you set out to solve a new problem. Knowing less, and thus have more focussed concentration on what you do know, is exactly the kind of thing needed to solve certain kinds of problems. Those kinds of problems are much more common in mathematics and physics than in history and literature.
So even if I humor the self-loving entrepreneurs out there and compare them to scientists and scholars, I cannot really say who they are more similar to. I do think that engineers play a significant role in the kind of technological endeavors common to entrepreneurs. As an engineer who was once a mathematician, I can say with confidence that engineers are much more like writers and historians than like mathematicians and physicists. Extra knowledge and experience definitely help an engineer to be more creative and productive. Computer scientists may be more like physicists. I wouldn't know, as I am an engineer, not a computer scientist.
Of course most people would say that entrepreneurs are more like mathematicians, so the younger the better. I will argue that entrepreneurs are nothing like mathematicians and physicists, but that does not mean that they are not more like those types than they are like historians and writers.
First some disclaimers. I have a degree in mathematics, and like to humor myself by considering myself a mathematician at my core. Truth is that I am a software engineer, a very different discipline, and I cannot deny this.
Ok, first off entrepreneurs are completely full of themselves for trying to enter this kind of comparison. By even making these analogies, you are equating the creativity and skill of scientists and scholars with the ... attributes ... of entrepreneurs. This is ridiculous. It is like trying to compare the skills of a microsurgeon with the skills of a race horse. It just doesn't make any sense.
Entrepreneurs definitely have creativity, intelligence, and skill, but it is not of the same species as scientists and scholars. Entrepreneurs have any measurement of their prowess: money. If their ideas make money, they are good ideas. If they do not make money, they are not good ideas. It's painfully simple.
Scientists and scholars are held to very different standards. Now it is true that scientific endeavor is open to experimentation and verification, a kind of litmus test similar to the success or failure of an entrepreneur's business. But a lot of the really great scientists have theories that are so theoretical and advanced that they cannot just be easily verified in a lab experiment. Similarly mathematicians must write proofs of their theories. These proofs must judged both objectively and subjectively by peers. Of course scholars have no "out" in terms of being proven right or wrong. Thus they all share something similar: their success is measured in the near term by the scrutiny of the most brilliant minds in the world.
This is a kind of scrutiny that no entrepreneur can experience. If the top two dozen computer scientists all thought that Google had a great search engine eight years ago, it would not have meant anything for Google. If those same elite scientists decided Google was crap, again it meant nothing.
The other flip side to the world of science and scholarship is that the very peers who decided your success or failure, are often wrong. That's why there are numerous examples of scientists whose work is not appreciated until after their death.
I could easily make arguments about how scientists and scholars have to be so much "smarter" than entrepreneurs, but I think just looking at the criteria for success is sufficient.
Again, given my background in mathematics, I have a little insight into why mathematicians peak in their late 20's or early 30's. The obvious reason is that solving highly theoretical problems requires tremendous time and submersion into you work. This is true, but it's only part of the reason. The other reason is that to solve those kind of problems, you need to have very little else to think about. I'm not talking about things outside of your work and study, I'm talking about things inside it.
As you progress in any field, you absorb more and more knowledge. This knowledge is tapped in some way, even if subconsciously, whenever you set out to solve a new problem. Knowing less, and thus have more focussed concentration on what you do know, is exactly the kind of thing needed to solve certain kinds of problems. Those kinds of problems are much more common in mathematics and physics than in history and literature.
So even if I humor the self-loving entrepreneurs out there and compare them to scientists and scholars, I cannot really say who they are more similar to. I do think that engineers play a significant role in the kind of technological endeavors common to entrepreneurs. As an engineer who was once a mathematician, I can say with confidence that engineers are much more like writers and historians than like mathematicians and physicists. Extra knowledge and experience definitely help an engineer to be more creative and productive. Computer scientists may be more like physicists. I wouldn't know, as I am an engineer, not a computer scientist.
#756
One of the great things about eBay is the endless opportunities for profit. It's like when the iPhone debuted. The only company (besides Apple) hoping for Apple stores to sell out quickly was eBay. Of course we would love to have #756 auctioned on our site. For that matter, how about #757 hit just last night? And don't forget #755. You get the picture.
Anyways, I was pretty surprised to see the Hank Aaron video message to Bonds after Barry hit #756. Everyone wants to be so righteous and hold Barry in contempt. At the same time, they realize that people everywhere were following the chase, so they wanted a piece of that action. Bud Selig may hate Barry, but how much coin has Barry put in his and the other owners' pockets?
I like having Barry Bonds as the top player of my generation. I like that we have a guy who was already the best in the sport, but who went out, broke the rules, used technology and took the game to levels it had never seen before. He did it and never apologized for being better than everybody else before him.
When Mark McGwire broke the single season record, I remember thinking "man if he suddenly stays healthy into his 40's, he could break Aaron's record." I am so glad that didn't happen. McGwire was always ashamed of his use of juice. He just wanted to fit in with the greats and be liked by the masses. He needed the juice to do that, but he also needed for people to not know about the juice at the same time. He was too weak to break the record, and too weak the represent my generation.
Barry is perfect. He doesn't care about people liking him. He doesn't want to fit in with the greats of the game, he wants to tower over them. He's egotistical, self-centered, and completely focussed on success at all costs. He's the modern day Ty Cobb.
Anyways, I was pretty surprised to see the Hank Aaron video message to Bonds after Barry hit #756. Everyone wants to be so righteous and hold Barry in contempt. At the same time, they realize that people everywhere were following the chase, so they wanted a piece of that action. Bud Selig may hate Barry, but how much coin has Barry put in his and the other owners' pockets?
I like having Barry Bonds as the top player of my generation. I like that we have a guy who was already the best in the sport, but who went out, broke the rules, used technology and took the game to levels it had never seen before. He did it and never apologized for being better than everybody else before him.
When Mark McGwire broke the single season record, I remember thinking "man if he suddenly stays healthy into his 40's, he could break Aaron's record." I am so glad that didn't happen. McGwire was always ashamed of his use of juice. He just wanted to fit in with the greats and be liked by the masses. He needed the juice to do that, but he also needed for people to not know about the juice at the same time. He was too weak to break the record, and too weak the represent my generation.
Barry is perfect. He doesn't care about people liking him. He doesn't want to fit in with the greats of the game, he wants to tower over them. He's egotistical, self-centered, and completely focussed on success at all costs. He's the modern day Ty Cobb.
Wednesday, August 08, 2007
Numbers
I had to try Apple's latest addition to iWork, Numbers. It's not just a pure Excel clone. It has a very nice UI. I really liked the templates it came with. I was most impressed with being able to copy HTML tables and past them into Numbers. That's a nice feature of Excel 2004 on the Mac. On Windows, you only get that if you use IE with Excel. It doesn't have pivot tables though. That is a deal breaker for power users. Still, it's pretty nice. I'm going to see if Pages has improved more. If it has, I could definitely seeing myself using Pages and Numbers instead of Office, especially since Office is still not a universal binary. Keynote was already superior to PowerPoint IMO.
Artile on TheServerSide.com
My first article for TheServerSide.com is now available. It's about calling a SOAP-based web service from JavaScript. It uses WSO2, a powerful set of web service tools built on several of Apache's products like Axis2. WSO2 is similar to Geronimo. It takes a lot of best-of-breed technologies and ties them together in an integrated, and easy to use package. The article talks a lot about a JavaScript library called WSRequest. This is a very cool JS library for calling web services. It lets you expose your application through a web service, and then leverage the same web service for building a UI on top of that service. It's classic don't repeat yourself.
Tuesday, August 07, 2007
New Articles on IBM
There's a couple of new articles that I wrote that are now available on IBM developerWorks:
The Geronimo renegade: Using integrated packages: Codehaus' Woodstox: This is an article all about Geronimo's StAX implementation, Woodstox. If you're an old veteran of XML parsing like I am, you have to love StAX. Woodstox is not only an excellent StAX implementation, it is a killer piece of software. We use it in a lot of places at eBay because it is so fast.
Use JavaScript to make your XForms more robust: This is a very cool article about mixing JavaScript and XForms together. XForms has become kind of a forgotten technology, which is a real shame. It has so much to offer. I think part of the reason it is forgotten is because people don't realize that it is standardized and integrated with other technologies. It plays nice. It's not some one-off technology that lets you do some cute things in a sandbox. This article shows how everything in the XForms world is accessible through JavaScript. It's not a read-only kind of access either. You can modify models and forms, etc. I'm planning on writing some more on XForms and how it integrates with a certain well known AJAX framework that is usually referred to as a three letter acronym...
The Geronimo renegade: Using integrated packages: Codehaus' Woodstox: This is an article all about Geronimo's StAX implementation, Woodstox. If you're an old veteran of XML parsing like I am, you have to love StAX. Woodstox is not only an excellent StAX implementation, it is a killer piece of software. We use it in a lot of places at eBay because it is so fast.
Use JavaScript to make your XForms more robust: This is a very cool article about mixing JavaScript and XForms together. XForms has become kind of a forgotten technology, which is a real shame. It has so much to offer. I think part of the reason it is forgotten is because people don't realize that it is standardized and integrated with other technologies. It plays nice. It's not some one-off technology that lets you do some cute things in a sandbox. This article shows how everything in the XForms world is accessible through JavaScript. It's not a read-only kind of access either. You can modify models and forms, etc. I'm planning on writing some more on XForms and how it integrates with a certain well known AJAX framework that is usually referred to as a three letter acronym...
Monday, August 06, 2007
Mmm Frameworks...
Java guys love frameworks. Instead of solving problems, we'd much rather build things to help others solve problems. We feel like we've accomplished so much more that way. There are a number of different, but equally interesting motivations for frameworks.
- Make things easier ... This is the one we're all the biggest fans of. Ain't it great when a framework turns hundreds of lines of code into a dozen? That's why Rails is so popular. There is tremendous tangible evidence of what the framework is doing for.
- Incremental improvement ... We've all got our favorite frameworks, and we always wind up finding the warts in them. You inevitably find yourself saying "the guys who wrote this framework should've just done X, Y, and Z. Then it would be perfect." This leads to somebody doing X,Y, and Z. You could probably fork, but it's so much more glamorous to claim your own territory. All the Struts clones like Spring MVC and Stripes are great examples.
- Port ... A lot of frameworks are just ports of other frameworks from other languages: NHibernate, Grails, even Cake for that matter. Sometimes it's somebody's way to prove that thier language is still better than that other language, or maybe they've just been forced to write in some other language and miss their favorite framework.
- Solving hard problems ... These are the least glamorous kind of frameworks. They take on really hard problems and try to solve them, or at least make some progress. There's no Hello World fluff in these frameworks. They may not be easy to use, heck they might be really hard to use. Google Web Toolkit is a pretty good example of this kind of framework, though it also seeks to make some things easier (a la #1.)
What do you look for in a framework?
Wednesday, August 01, 2007
Tomcat 6 on OSX
I needed to run Tomcat, so I decided to use Tomcat 6 for a change. I got an all too familiar when I tried to start things with catalina start:
Grrr... I've had this error before, but I couldn't remember at first what the deal was. Then I remembered it... The shells scripts in $CATALINA_HOME/bin aren't executable by default...
cd $CATALINA_HOME/bin
chmod +x *.sh
./catalina.sh start
Using CATALINA_BASE: /Users/michael/dev/apache-tomcat-6.0.13/
Using CATALINA_HOME: /Users/michael/dev/apache-tomcat-6.0.13/
Using CATALINA_TMPDIR: /Users/michael/dev/apache-tomcat-6.0.13//temp
Using JRE_HOME: /System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Home
Ahh, much better!
The BASEDIR environment variable is not defined correctly
Grrr... I've had this error before, but I couldn't remember at first what the deal was. Then I remembered it... The shells scripts in $CATALINA_HOME/bin aren't executable by default...
cd $CATALINA_HOME/bin
chmod +x *.sh
./catalina.sh start
Using CATALINA_BASE: /Users/michael/dev/apache-tomcat-6.0.13/
Using CATALINA_HOME: /Users/michael/dev/apache-tomcat-6.0.13/
Using CATALINA_TMPDIR: /Users/michael/dev/apache-tomcat-6.0.13//temp
Using JRE_HOME: /System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Home
Ahh, much better!
Lunch 2.0 @ Facebook
Or should I say Lamebook... This is not my first Lunch 2.0. You can't help but compare these things a little, and Facebook does not fare well in any comparison.
First, they did a "happy hour" which meant beer and finger foods. So what you say? It's Lunch 2.0 damnit, not Snacky Snacky 2.0. The food matters.
Next it was very crowded and hot. Now I know that's partially just because so many people wanted to go to it because it was at Facebook. It's also because it was an inside event. Very limited space and lots of people = hot, noisy, sweaty, stinkiness. I'm sure this was the largest space that Facebook has available to it, but that's just another flaw in their based in Palo Alto logic (more on that later.)
Bad food, bad environment, what could save the event? How about some cool schwag! Oh wait, how about no schwag... You would think a company so obsessed with its collegiate roots would at least give out some t-shirts or knapsacks. Oh well. Simply Hired is still the king o' schwag.
Well what about the crowd? Well this was a decidedly younger crowd. I saw a lot of folks who had written on their nametags their names and their college. What the hell? Since when did Lunch 2.0 become Frat Party 2.0? Heh heh, I've become such an old fart. The crowd also had a lot more A-listers... Not sure if that's good or bad. I wonder how many of those folks will be at AOL next week. All in all, not as geeky a crowd as usual.
All that being said, I had a great time for one simple reason. I met up with an old Caltech classmate of mine, Robert Johnson, who's an infrastructure guru at Facebook. It was cool to catch up and talk about ye olden times. It was also cool to hear about some of the scale issues that Facebook has faced and things they're going to do about it, especially since we've faced and solved many similar issues over the years at eBay.
So that brings me back to Facebook, the company. I was really surprised to hear how they have three different buildings scattered around downtown Palo Alto. These guys really need to get a big space somewhere. Maybe they need to IPO or something to afford that. Seems unlikely they'd be able to do that in downtown Palo Alto. I know they are so in love with that area because of its ties to Stanford, but guess what guys. You're not in college anymore. Remember when you were in college and alumni would show up to hang out and pretend they were still in school? Remember how lame you thought those guys were? Umm...
First, they did a "happy hour" which meant beer and finger foods. So what you say? It's Lunch 2.0 damnit, not Snacky Snacky 2.0. The food matters.
Next it was very crowded and hot. Now I know that's partially just because so many people wanted to go to it because it was at Facebook. It's also because it was an inside event. Very limited space and lots of people = hot, noisy, sweaty, stinkiness. I'm sure this was the largest space that Facebook has available to it, but that's just another flaw in their based in Palo Alto logic (more on that later.)
Bad food, bad environment, what could save the event? How about some cool schwag! Oh wait, how about no schwag... You would think a company so obsessed with its collegiate roots would at least give out some t-shirts or knapsacks. Oh well. Simply Hired is still the king o' schwag.
Well what about the crowd? Well this was a decidedly younger crowd. I saw a lot of folks who had written on their nametags their names and their college. What the hell? Since when did Lunch 2.0 become Frat Party 2.0? Heh heh, I've become such an old fart. The crowd also had a lot more A-listers... Not sure if that's good or bad. I wonder how many of those folks will be at AOL next week. All in all, not as geeky a crowd as usual.
All that being said, I had a great time for one simple reason. I met up with an old Caltech classmate of mine, Robert Johnson, who's an infrastructure guru at Facebook. It was cool to catch up and talk about ye olden times. It was also cool to hear about some of the scale issues that Facebook has faced and things they're going to do about it, especially since we've faced and solved many similar issues over the years at eBay.
So that brings me back to Facebook, the company. I was really surprised to hear how they have three different buildings scattered around downtown Palo Alto. These guys really need to get a big space somewhere. Maybe they need to IPO or something to afford that. Seems unlikely they'd be able to do that in downtown Palo Alto. I know they are so in love with that area because of its ties to Stanford, but guess what guys. You're not in college anymore. Remember when you were in college and alumni would show up to hang out and pretend they were still in school? Remember how lame you thought those guys were? Umm...