Technology

Real-time co-editing of code in Eclipse

Monday, October 13th, 2008

This weekend I ran across a great way to collaboratively work on Salesforce.com code in Eclipse. The Docshare plugin for Eclipse that as part of the Eclipse Communications Framework allows you to collaboratively edit an Eclipse text document with another developer anywhere on the Internet.

DocShare is similar to subEthaEdit, a Mac text editor that allows multiple editors at once. It’s kind of freaky when you first see it, because it breaks one of the fundamental rules of how computers work. Two people can actually edit the document at the exact same time, making different changes, and all of it happening in real-time with very little latency.

There are a couple cool things about DocShare. First, it’s embedded in Eclipse where I already work on my code. Second, it works over XMPP, the Jabber protocol that Google Talk is based on. So, you can share your code with anyone with a Google Talk account. It also works with Skype, IRC, and a number of other protocols.

There is one limitation which makes this hard to use with Salesforce.com code–it doesn’t currently work with the Force.com editors (HTML, Apex). Aparently, it’s not hard to add it to the context menus, but I don’t have the info I’d need to make that work.

Even without working with the Force.com editors, it’s worth checking out.

Setting it up is pretty easy. First, go here to get the update site URL. Install the ECF.

Once you install it, you’ll need to modify your Force.com perspective to show the communications Views and Commands. Once you do that, you can add one of your XMPP accounts:

screenshot

When you do that, you’ll see your list of IM contacts. You now have a full IM client in Eclipse.

screenshot

Ideally, now you’d share your Apex classes. But like I said, you can’t do that yet. So take your class and copy the text.

screenshot

Paste the text into a temporary txt file.

screenshot

Then you’ll have a Share item on your right-click menu in that text file.

screenshot

Pick your friend and share away. If they are logged into Eclipse, they’ll get a pop up asking them if they want to accept your shared file. If they do, you can both start editing! When you’re done, just copy the contents of the text file and put it back in the class.

It’s a great way to do remote code reviews. I’ve used it to get help with an issue today from Matthew in Bellingham–worked very well. And he even fixed my problem while I watched.

So, if any Salesforce.com staff are listening, make the minor changes necessary to have this work with the Force.com editors and you’ve got a killer Dreamforce demo!

I’m a nerd with kids

Thursday, October 9th, 2008

Loved this!

Chrome–fastest Salesforce browser

Tuesday, October 7th, 2008

If you use Salesforce.com, you must try Google’s new browser Chrome. For me, it is blazing fast. They wrote a new javascript engine which speeds up Salesforce.com pages, which are heavy in JS.

Give it a try. I haven’t experienced anything faster.

CRMFusion releases DupeBlocker–realtime dupe protection for Salesforce

Monday, October 6th, 2008

The awesome folks at CRMFusion have release their killer app–realtime dupe creation blocking in Salesforce.com.

DupeBlocker has been developed to complement the existing Salesforce data quality tools developed by CRMfusion Inc and used by over 2000 Salesforce administrators worldwide, DemandTools and PeopleImport. While DemandTools cleans duplicates out of Salesforce (among the 100’s of other things DemandTools does) and PeopleImport stops duplicates from being imported (such as from a trade show list), DupeBlocker stops the users from being able to create duplicates in REAL time.

I can’t say enough about DemandTools, and I can’t wait to try DupeBlocker. Go get your 30-day free trial today!

I’m running an ad in Ohio

Thursday, September 11th, 2008

After Chris Bowers’ brilliant idea about how to run your own paid media campaign, I decided to give it a shot and personally run a google ad in Ohio. Heck, it’s a free country and I wanted to try to point people searching for information on John McCain to a cool site that shows his lobbyist connections. Here’s the ad as it’s running in Ohio right now.

screenshot

This ad will show up for the search terms that Chris laid out in his post. After a day and a half, here are my results:

screenshot

I’ve limited the ad run to $100/month, because I didn’t have an ad budget before yesterday…

Agree or disagree with my politics? Run your own ad! Google adsense makes it a breeze.

John McCain’s technology policy is more of the same

Wednesday, September 10th, 2008

Since you’re reading this blog, you’re most likely interested in technology. You probably work in the tech industry, or understand the value of technology infrastructure in the life of our country. I wanted to pass on some great analysis that Lawrence Lessig did of John McCain and Barack Obama’s technology policies as one particularly relevant point as we choose our next president.

Lessig took a look at John McCain’s technology platform, which he released on 8/14. While the platform touted McCain’s experience on the Senate’s Commerce, Science and Technology committee, he found it wanting in many ways.

First, Lessig points out that over the last 8 years the US has plummeted from 5th in the world in broadband penetration to 22nd. Compared to the rest of the world, we have less broadband access today than we did 8 years ago.

This a stunning setback for a country that likes to think it sets the standard for a technological citizenry. MeCain has been at the helm of congress in regards to policies that have brought this reversal about, so Lessig looks for anything in the platform that might reverse this trend.

He finds nothing. But not only does he find nothing to help with this current problem, he finds no acknowledgment of the problem at all. McCain wishes to continue the policies that lead us to this place:

  • He wants tax cuts for business to help spur innovation.
  • He wants low income people to get more access to broadband by subsidizing companies to make this happen.

Lessig points out that these proposals have one thing in common–they drive money to the largest Internet companies. And there are now basically two major Internet providers in the US–a consolidation that the US government has been complicit in while John McCain was head of the Technology committee. It didn’t have to be this way.

France didn’t do this. Lessig compares Paris, where you can get 200mbps Internet, telephone service and TV for $45/month to San Francisco, where $90/month will get you those services, but with 1/10th the speed for Internet.

Lessig calls our policy a “failure” and posits the solution is net neutrality. He suggests that you think about the internet as you think about phones. Should your phone provider decide which numbers you can call? Should they be able to listen in on your convervsations and lower the quality depending on what you’re talking about? No provider should get to pick who I get to connect to.

Network operators want more control, they want the Internet to look more like cable TV where you don’t get to choose.

Net neutrality says the internet is like the phone system–you get to call anyone and say anything, as long as it’s legal. Attach whatever devices as long as they aren’t harmful.

Obama’s policy is distinctly different from John McCain’s as it proposes a new direction for how the country uses technology. He recognizes that the last 8 years have been failed policy. He realizes we need a CTO for the country, that we need to use technology to make government transparent.

We have a clear choice in this election when it comes to technology. Should we continue to funnel money to Comcast and fall farther behind the rest of the world, or should we try a new direction based on openness and innovation. I think the better policy is clearly Obama’s plan, and I suggest that if you want more information you check out his plan online and compare it to McCain’s.

Dreamforce is on Election Day

Thursday, August 28th, 2008

Don’t forget your shirt…

Tips for working with Force.com IDE

Wednesday, August 27th, 2008

I’ve doing Salesforce.com development with Eclipse as my IDE for over two years now and it’s truly indispensable. It hasn’t been the easiest thing to learn and use, however. Eclipse is a complex beast–it’s really trying to meet the development needs of an amazing disparate group of users. And it’s a framework on which plugins sit, which is a powerful but scary proposition.

As I said, though, it’s indispensable for Salesforce coding. And even though it’s big and gnarly, I genuinely like using it most of the time. Here are some tips that might help you like using Eclipse for Salesforce as well:

Get latest “supported” versions of Eclipse and plugin

The Eclipse framework is an open source tool that periodically comes out with a new release. The Force.com IDE is a plugin that sits on top of that framework, and it has it’s own release cycle, controlled by the folks at Salesforce.com.

You should get on the latest version of Eclipse and the Force.com IDE that Salesforce.com recommends. At the time of this writing, that’s Eclipse 3.3 and Force.com IDE 13.0.

The latest Eclipse version is 3.4, but Salesforce.com hasn’t tested IDE 13.0 with it, so they don’t recommend it. I’m using 3.4 and haven’t had any problems except the small one that if you delete an Open Force.com project your code will be deleted from your Salesforce.com instance! Trust me, you want to stay on the Eclipse version Salesforce.com recommends–you’ll be happiest that way.

Whitelist your network

Eclipse is a “client app” which means it’s accessing Salesforce.com from your desktop. Because of that, it’s not trusted, and needs to be given the OK to talk to Salesforce.com. You can do this one of two ways–get your security token and use that or whitelist your network.

I highly recommend never using security tokens if you don’t have to! You can white list your network at Setup | Security Controls | Network Access

screenshot

Once you do that, Eclipse will be able to connect to your Salesforce.com instance from that location.

Change your fonts

Maybe I’m just getting old, but the fonts in Eclipse are hard to read. I can’t easily tell a { from a (, which in coding is a pretty important distinction to make! Set your text font in Eclipse under Window | Preferences.

screenshot

After trying some different fonts, I landed on Consolas with cleartype turned on in Windows.

Maximize screen real estate when coding

The Eclipse is set up with panels that you can drag around to create the look you want. It’s very flexible. It’s nice to see your code and the list of all code files and the test runner, all in one view. But, when you’re coding, use CTRL+M to quickly hide all the other panes, then hit it again to bring them back.

Refresh your projects often when multiple people are involved

In Eclipse you are working with local text files. Because of this, what you’re looking at might not reflect what is really in Salesforce.com at that instant, especially if you have multiple people working in the same instance. You can refresh what you have on your computer with what is in Salesforce.com, and I recommend doing it pretty regularly so you don’t get in the situation where you’re working on old code. The new IDE is much better at warning you when that happens, but it’s much better to not get into that situation.

Be Patient

Working on local text files is quick, but saving those up to Salesforce.com isn’t. You’re pushing files to San Francisco, and that takes time. But, there are other things going on. The two things that take the most time are compiling and running of tests. It’s great that these things happen automatically for you, but you have to be patient as they take the time to make sure you’re not breaking your instance. It’s worth the wait.

When you save a file, the Problems tab turns to italics. When the save is done, it goes back to regular text.

screenshot

Close Projects to Keep Workspace Smaller

Having many projects handy is great, because you can go and steal code from on to put in another, but slows down the workspace. Searches and synchronization take longer. You can create Force.com projects for all your instances and close the ones you don’t care about right now. It’s two clicks to open them back up.

screenshot

Compare and Merge Files Across Instances

This is a basic one, but very handy–Eclipse has a text compare feature where you can take two files and show how they differ. This is great for adding functionality from one instance to another where similar code already exists.

screenshot

Deploy when possible, but Drag and Drop is Quicker

The Force.com IDE has a deployment wizard which is great for moving code between two instances. It’s really nice. The latest release of the IDE has gone one step further, adding robust drag and drop functionality. It’s kind of like deploying without the deploy wizard. Sometimes it’s faster to just drag and drop, but sometimes only the deploy wizard will work for what you’re trying to do.

Connect to other systems

I said earlier that Eclipse was trying to meet the needs of a very diverse developer audience. The good part of that is there are some killer plugins for connecting Eclipse to other systems out there.

You can connect your Force.com project to a Subversion code repository so that all your Salesforce.com code can be version controlled in the industry standard system.

Mylyn is a cool add-on (included in Eclipse 3.4) that allows you to connect to ticket or task management systems out there like Trac, or Google Code Projects. It makes managing code issues and bugs very nice and collaborative.

Conclusion

It’s becoming increasingly mandatory to use Eclipse for developing with Force.com. That’s a good thing, once you climb the learning curve. Eclipse is a good IDE that is amazingly extensible. Just think about what Salesforce.com is doing with their plugin–they’ve taken a tool that is used to dealing with text files and have it working with their database-stored code and config. Pretty amazing, really.

If you are using Eclipse with Force.com, please comment with any cool things I’m missing–it’s a sprawling tool. If you haven’t been using Eclipse, you really should!

Proposal: Simplify Vertical Response Emails to Campaigns

Monday, August 25th, 2008

Here is a modest proposal for making it easier for sending Vertical Response emails from a Campaign.

screenshot

Am I missing something? Seems like this would be really easy for Vertical Response to implement.

New stuff for Winter ‘09

Monday, August 25th, 2008

Scott, a master of the URL hack, has found the URL for Coming in Winter ‘09 Ideas.

Here are my favorites: