Friday, March 20, 2009

Updating to Mylyn 3.1

I tried updating to the latest release of Mylyn through the update manager and I encountered the following error:
"Cannot find a solution satisfying the following requirements org.eclipse.swt [3.4.0.v3448f]."

This is how I fixed it:
1) Installed the Eclipse Platform SDK and Eclipse SDK.
2) Restarted Eclipse
3) Added the update site: http://download.eclipse.org/tools/mylyn/update/e3.4 (for some reason it disappeared)
4) Ran an update on all Mylyn Features and Mylyn Integration components (I don't need Mylyn Plug-in Development)
5) Restart Eclipse
6) Voila!

Go to http://www.eclipse.org/mylyn/new/ for what's new in Mylyn 3.1.

-Pablo

Tuesday, November 4, 2008

Clean Code

Now that my team is working on some big and exciting development tasks for our Eclipse-based product, there is no better reading than Clean Code by Uncle Bob, the book that the Toronto Design Patterns Study Interest Group has chosen to read for this season.

Currently, I am working on a task that involves consolidating the model for our business process editor. Due to the adoption of GEF, our product has been running with two parallel models, a new one based on GEF and a legacy model that does not follow an MVC architecture. As a result, there is a lot of code duplication and dead code.

While I am working on the task previously mentioned, I have found how easy is to write bad code. Although, it is not hard to write clean code as a personal activity, it is harder to provide a sustainable policy for improving existing code as a collective activity. A fundamental rule in this policy is nicely described by Robert Martin’s book. In Chapter 1, he makes reference to the Boy Scout Rule: “Leave the campground cleaner than you found it”

In conclusion, the key point is not just to write clean code, but to polish existing code and leave it cleaner than how we found it. The benefits and advantages of clean code are widely discussed in the book, however my suggestion to you is to not commit code to your versioning control repository if your changes do not leave the code cleaner than you found it. Believe me, it will make your professional life easier.

Feliz coding,
Pablo

Friday, August 29, 2008

Eclipse Copyright Tool

The other day I tried the Copyright Tool, part of the Eclipse Releng Tools (org.eclipse.releng.tools) however I could not find documentation for it.

I was trying to update the copyright statements in our source code so I modified the copyright template in the preference page. Then I ran the “Fix Copyrights…” action and the copyrights changed but not with the text I specified in the template. Then I found this thread in Eclipse newsgroups explaining the difference between the "Fix Copyrights..." and "Advanced Fix Copyrights..." actions. The action that updates the copyright statement with the text in the template is “Advanced Fix Copyrights…” and it is available only in the Navigator view!
At the end, after playing a bit with it, I found this tool interesting but not useful for our specific case; it needs to be more customizable.

Hope this posting gives you some heads up…

Puzzle for killing your brain cells

A friend of mine sent me this Fantastic Contraption puzzle. Good one if you like thinking.

Enjoy!

Tuesday, August 26, 2008

Debugging WebSphere with Eclipse

This is how I attach my Eclipse 3.3 to WebSphere 6.1 for debugging my deployed applications.

WebSphere
In WebSphere’s console, I go to Application Servers > my-server-to-debug > Java and Process Management > Process Definition > Java Virtual Machine. Near the bottom of the page, I check Debug Mode and the values I am using in Debug arguments are:
-Djava.compiler=NONE -Xdebug -Xnoagent
-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=7777

After applying the changes, I restart WebSphere.

Eclipse
In the Debug Dialog, I create a new configuration under the category Remote Java Application. I specify the project containing the source code of my deployed application, localhost (my WebSphere is running locally) and the port 7777.

Now I am ready to debug. I add some breakpoints, launch the debug configuration and run my deploy application.


Hope this helps you.


Until next…

Monday, August 18, 2008

Java Certifications

Here is a nice article with a list of different Java certifications available (not just from Sun): http://java.dzone.com/articles/certifications-may-i-see-the-m

Right after finishing my Computer Science degree, I pursued my SCJP certification and although it was not a guarantee for a job, it definitely gave me an advantage over other candidates.

Whether if the certification made me a better programmer or not, I am not sure. However, I noticed that the certification gave me extra knowledge that my programming classes did not teach me and that my colleagues did not know.

After a few years programming, I realized that good programmers are made of experience, knowledge and creativity, not just certifications or good grades at school.

Until next…

Thursday, August 14, 2008

Eclipse blog en Español

After some incredible vacation, I am back.

While I was doing a short research over the internet, I found out that there aren't many Eclipse blogs in Spanish. Therefore, I will start one.

I will continue posting all my entries in this blog. However, for those entries about Eclipse, I will translate them and post them in the new blog. Stay tune for the next entry...

Hasta la próxima...