I'm on my first vacations in more than 4 years and I got very good news... While my brother came to San Francisco to visit me, I helped him out with his experiments for this MS dissertation questionings about the DCCP protocol. His findings about how that protocol helps multimedia applications over the Internet was published at the Linux Magazine, August 2008 issue. "Congestion Control: Developing multimedia applications with DCCP". I just got my name spelled Marcello Junior :) instead of my de Sales. I usually omit my suffix, commonly shortened to Jr.
For more about the article http://www.linux-magazine.com/issues/2008/93
Monday, July 28, 2008
Friday, April 25, 2008
No Eclipse crash after FRESH INSTALLATION OF UBUNTU 8.04 64bits (sharing with Ubuntu 7.10 and Vista)
Hello all,
It has been a while since I last posted something... These days I can finally work with Eclipse without any crash!!! Yes, Ubuntu 8.04 finally was released yesterday and I downloaded the 64bit alternate version for AMD 64bit processors and installed it on my Dual Core Intel 32bit. The reason is that I have 4GB of physical memory and a 32bit OS can only address 3GB...
The installation process was smoothly done using the alternate CD, it recognized all my other OS's and I'm just migrating from one to another little by little... Although everything was just find during the installation, JAVA 5 doesn't run on Ubuntu and Java 6 was the only way to have JAVA-based applications running... Another negative point is the shipment of Firefox 3 beta, which can be really fast on gmail email accounts but high memory consumption is still an issue and for this reason a downgrade to Firefox 2.x was my solution.
All the steps of the installation are described at http://ubuntuforums.org/showpost.php?p=4794923&postcount=458
Good luck!
It has been a while since I last posted something... These days I can finally work with Eclipse without any crash!!! Yes, Ubuntu 8.04 finally was released yesterday and I downloaded the 64bit alternate version for AMD 64bit processors and installed it on my Dual Core Intel 32bit. The reason is that I have 4GB of physical memory and a 32bit OS can only address 3GB...
The installation process was smoothly done using the alternate CD, it recognized all my other OS's and I'm just migrating from one to another little by little... Although everything was just find during the installation, JAVA 5 doesn't run on Ubuntu and Java 6 was the only way to have JAVA-based applications running... Another negative point is the shipment of Firefox 3 beta, which can be really fast on gmail email accounts but high memory consumption is still an issue and for this reason a downgrade to Firefox 2.x was my solution.
All the steps of the installation are described at http://ubuntuforums.org/showpost.php?p=4794923&postcount=458
Good luck!
Friday, February 22, 2008
AOP rescued me today!!!
Agility has to do with how you can apply programming techniques to solve usual problems that usually takes long time to be developed. If it's not a time constraint, it is code design and this "bad smell" is going to rest there until you use refactoring methods to organize "your home".
During the development of my vOtopus, my personal web server for my Advanced Internet Design and Engineering class, I got the usual requirement of loggin capability, where I should print out the execution path for debug purposes, and about the clients' request information. So I started adding the following Logger information:
Anyway, it had been a long time when I first studied AOP, still in 2004 while taking my Internship at Motorola, and I was just using on simple and small applications by my own using AspectJ, one of the most used implementations and available at the Eclipse IDE as a plug-in. Today, I definitely felt the need to use this paradigm to quickly design and implement a simple and reusable solution, maintaining quality and integrity of my system already designed (VOtopus Architecture). I tried to maintain designed with as loosely coupled as possible (most of them a weak dependency) through the use of the "Program to an Interface, not to an Implementation" idea.
The next step was to create advices around the join points, or the moment in which we are going to do something related in the pointcut. That means before the execution, after the execution, during the execution... Find out more about it at Aspect-Oriented Programming. For my webserver, I just want to give the advice saying "I'm advising you that my join points are the ones exactly before the execution of any method or constructor from the pointcuts called loggableCalls". It's really clear that this is the only code I needed to implement the "tracer" for method calls (private, default, protected, public).
before() : loggableCalls() {
if (this.vologger.isLoggable(Level.INFO)) {
Signature sig = thisJoinPointStaticPart.getSignature();
this.vologger.logp(Level.INFO, sig.getDeclaringType().getName(), sig.getName(), "Entering");
}
}
There are a lot of discussions on this subject due to the a lot of things you can do with AOP. Check the links about and have fun being agile with AspectJ.
During the development of my vOtopus, my personal web server for my Advanced Internet Design and Engineering class, I got the usual requirement of loggin capability, where I should print out the execution path for debug purposes, and about the clients' request information. So I started adding the following Logger information:
import java.util.logging.Logger;
...
private Logger vologger = Logger.getLogger("tracer");I started smelling the bad code again when I had pasted the same line of code into 3 classes... When you only know OOP, or Object-Oriented Programming, you can do everything using the same old Pojo classes. However, I thought that this would be the best time to rescue myself and put AOP, or Aspect-Oriented Programming, into practice (Check the Wikipedia for a complete introduction to the concepts behind AOP).
Anyway, it had been a long time when I first studied AOP, still in 2004 while taking my Internship at Motorola, and I was just using on simple and small applications by my own using AspectJ, one of the most used implementations and available at the Eclipse IDE as a plug-in. Today, I definitely felt the need to use this paradigm to quickly design and implement a simple and reusable solution, maintaining quality and integrity of my system already designed (VOtopus Architecture). I tried to maintain designed with as loosely coupled as possible (most of them a weak dependency) through the use of the "Program to an Interface, not to an Implementation" idea.
- Log requirements
pointcut vOcotpusPackage() : execution(* edu.sfsu.cs.csc867.msales.voctopus..*(..)) || execution(edu.sfsu.cs.csc867.msales.voctopus..new(..));It's clear how Aspect-Oriented Programming deal with this cross-cutting concern. The "loggin concern" isn't part of the webserver business logic, but it is a concern that cross-cuts the entire application because each individual class need that functionality.
The next step was to create advices around the join points, or the moment in which we are going to do something related in the pointcut. That means before the execution, after the execution, during the execution... Find out more about it at Aspect-Oriented Programming. For my webserver, I just want to give the advice saying "I'm advising you that my join points are the ones exactly before the execution of any method or constructor from the pointcuts called loggableCalls". It's really clear that this is the only code I needed to implement the "tracer" for method calls (private, default, protected, public).
before() : loggableCalls() {
if (this.vologger.isLoggable(Level.INFO)) {
Signature sig = thisJoinPointStaticPart.getSignature();
this.vologger.logp(Level.INFO, sig.getDeclaringType().getName(), sig.getName(), "Entering");
}
}
There are a lot of discussions on this subject due to the a lot of things you can do with AOP. Check the links about and have fun being agile with AspectJ.
Friday, January 25, 2008
Off-topic: Admitted at the MS in Computer Science - SFSU
Well, this is not an agile post, but the happiest post ever: I was admitted to the M.S. in Computer Science program at San Francisco State University... This is something I dreamed since high-school and I believe God makes everything at His own time.... I will create a new blog about the life of a student-professional-student with life back to the academic world...
This will be fun... The ideas about a different Web 2.0 approach to my studies will be discussed on this new blog I'm thinking about just to address information about "flattening the world of academic research"... Will discuss much more there...
This will be fun... The ideas about a different Web 2.0 approach to my studies will be discussed on this new blog I'm thinking about just to address information about "flattening the world of academic research"... Will discuss much more there...
Monday, January 21, 2008
Never trust an IDE (shame on Eclipse's auto-completion feature)
Being agile sometimes brings us headaches that can make one lose hours of going through debugging log files, and sometimes without clues to the newly created puzzle. J2EE applications can make you feel that headache when we have to deal with applications and frameworks written without "proper" error-handling/logging.
My frustration started while finishing a personal application using the widely-used MVC framework Struts. I already had lots of "controlled" Actions and I was just adding a new Action to the play, but I was trying to be Agile :D I had downloaded the newest version of Eclipse 3.3 and imported my project accordingly. Then, I promptly just fired the "Create New Class" and extended the Action. That's it!!! (I thought), but my headache had just started after I trusted my loved IDE's auto-completion capabilities.
Before I describe what I had implemented on my execute method (the one we must override in order to have our application to "dance"), I found descriptions of which mistakes one can make in order to get the so-called blank/white page result after executing a strusts action. My application was also suffering from this well-known and poorly documented problem. According to a post at JMatrix, 2 are the possibilities of getting this blank page side-effect: If the Default Action is called instead of your Action class or if the input class on the action mapping is invalid. However, I'm writing this post just to add my 2 cents to the scope of this problem. Everything started when I trusted Eclipse to override the method signature below:
3. If you have NOT overridden the method execute, but overloaded it by having a different method signature. Be careful!!! It is HttpServletRequest and HttpServletResponse instead of ServletRequest and Servlet Response on the signature of the execute method. Never trust your loved IDE.
My frustration started while finishing a personal application using the widely-used MVC framework Struts. I already had lots of "controlled" Actions and I was just adding a new Action to the play, but I was trying to be Agile :D I had downloaded the newest version of Eclipse 3.3 and imported my project accordingly. Then, I promptly just fired the "Create New Class" and extended the Action. That's it!!! (I thought), but my headache had just started after I trusted my loved IDE's auto-completion capabilities.
Before I describe what I had implemented on my execute method (the one we must override in order to have our application to "dance"), I found descriptions of which mistakes one can make in order to get the so-called blank/white page result after executing a strusts action. My application was also suffering from this well-known and poorly documented problem. According to a post at JMatrix, 2 are the possibilities of getting this blank page side-effect: If the Default Action is called instead of your Action class or if the input class on the action mapping is invalid. However, I'm writing this post just to add my 2 cents to the scope of this problem. Everything started when I trusted Eclipse to override the method signature below:
public ActionForward execute(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)This is the correct signature of the method execute, the one that will be executed by the Action Executor. However, after using the code-completion feature, I got the following signature:
/* (non-Javadoc)Being agile is all about trusting the tools that help you be productive, and this was just a moment of sadness. For me, the code was totally correct, but it was completed with a different signature. Although the action is loaded, nothing will be executed with this scenario. I spent a few hours with the clue of just having, among others, the following lines of the debugger output that proved that my Action class was being created and used by the Action executor class ActionCommandBase to execute the default "execute method".
* @see org.apache.struts.action.Action#execute(org.apache.struts.action.ActionMapping, org.apache.struts.action.ActionForm, javax.servlet.ServletRequest, javax.servlet.ServletResponse)
*/
public ActionForward execute(ActionMapping mapping, ActionForm form, ServletRequest request, ServletResponse response)
throws Exception {
00:48:11,658 DEBUG CreateForumPosterAction:27 - Starting the create forum poster action...Any clues? The reason is that the method added was not overriding, but overloading the method execute from the class AbstractAction, which is just an empty method. Therefore, another reason to get the blank page from the execution of an Action struts class is when you trust an IDE such as Eclipse and hope that it will auto-complete the overridden method when you need. In other words, my 2 cents for JMatrix list is:
00:48:11,659 DEBUG AbstractCreateAction:93 - setting action to net.jsurfer.cryptonline.client.web.CreateForumPosterAction@192563a
00:48:11,660 DEBUG ActionCommandBase:49 - Executing org.apache.struts.chain.commands.servlet.ExecuteAction
3. If you have NOT overridden the method execute, but overloaded it by having a different method signature. Be careful!!! It is HttpServletRequest and HttpServletResponse instead of ServletRequest and Servlet Response on the signature of the execute method. Never trust your loved IDE.
Wednesday, January 16, 2008
Installing SourceForge Enterprise Edition VMWare-based on Ubuntu 7.10 Gutsy
What about managing your team with the first-class distributed software development tool? SourceForge Enterprise Edition allows project managers to better follow his/her teams of projects in a very convenient way. This post is just a hint on how to install SourceForge Enterprise Edition vmware player instance on Ubuntu 7.10...
First of all, I'm assuming that you have Ubuntu 7.10 installed as your own desktop, remote server, etc... For remote servers, I recommend one using NXServers and in order to access your server just use the NoMachine clients.
At this start point, you can download SourceForge Enterprise Edition 15 users from http://downloads.open.collab.net/sfee15.html. I had downloaded the file SourceForge-4_4-DL6.zip and unzipped its contents to my home directory by running
With VMWare up and running, go to Applications -> System Tools -> VMware Player. Then, click on "Open an existing Virtual Machine" and go to the directory where you unzipped the download of SourceForge-4_4-DL6.zip and select the only file for the SourceForge virtual machine... the VA software centOS server will begin to be loaded... We are almost there... :D
A lot of users (including me) are just reading the documentation available online, but for this installation the package includes the file "install_guide.pdf" with information about pre-installation instructions. I just needed to see which username and password allows me to make the first login to the SFEE server. When prompted, just use the following:
http://sfee.open.collab.net/sf-help/en/doc/User_Guide.pdf
First of all, I'm assuming that you have Ubuntu 7.10 installed as your own desktop, remote server, etc... For remote servers, I recommend one using NXServers and in order to access your server just use the NoMachine clients.
At this start point, you can download SourceForge Enterprise Edition 15 users from http://downloads.open.collab.net/sfee15.html. I had downloaded the file SourceForge-4_4-DL6.zip and unzipped its contents to my home directory by running
unzip SourceForge-4_4-DL6.zipWith the access to the GUI, you can proceed with the installation of the VMPlayer... Just follow the instructions on how to do so at Ubuntu Forum. It's mandatory the installation of the build-essential package!!! If the package update bugs you complaining about the Ubuntu CD from where you installed Ubuntu and you don't have access to one, just comment the first line at the /etc/apt/source.list file about the cdrom access... Finally, just complete the installation answering to all the questions by default, HAVING ONLY THE BRIDGED configuration. If asked, verify which interface has your IP address by running "ifconfig" and use it on the configuration (mine was eth1)... Once configured, it will display a welcome message from the VMware team...
With VMWare up and running, go to Applications -> System Tools -> VMware Player. Then, click on "Open an existing Virtual Machine" and go to the directory where you unzipped the download of SourceForge-4_4-DL6.zip and select the only file for the SourceForge virtual machine... the VA software centOS server will begin to be loaded... We are almost there... :D
A lot of users (including me) are just reading the documentation available online, but for this installation the package includes the file "install_guide.pdf" with information about pre-installation instructions. I just needed to see which username and password allows me to make the first login to the SFEE server. When prompted, just use the following:
username: rootAt this step, since it's the first time you're running the installation, you will need to change the root password. Follow the instructions and go to the IP/Network configuration. I chose to have a static ip address in order to be able to have other http servers on my network... After following the installation procedures, the SFEE server will be restarted and the configuration script will show the ip address and host name on how to access your SFEE installation from your local network. After that, you are all set and you just need to hit the virtual host address on the browser and follow the welcome instructions... The following is the username and password for the admin account
password: sourceforge
username: adminFor management of projects using SFEE, a good starting point is the following documentation:
password: admin
http://sfee.open.collab.net/sf-help/en/doc/User_Guide.pdf
Thursday, January 3, 2008
Axis2, Take 1... Developing POJO based Services
I spent most of the last year developing using AXIS 1.3 ... Today I'm really happy with AXIS2 because of the Plug-and-play capabilities when it comes to publishing services. I'm rewriting a J2EE application I wrote 6 years ago using the latest technologies, and of course publishing the Interfaces using AXIS2.
First of all, install Axis2 service on your application service of choice (Tomcat, in my case). Then, start with the development of the aar POJO service: specifying the methods of the Interface, then describing the type of the messages (in-out, in only, out only) on the services descriptor file. After running the WSDL generator, one can customize the design or integrate with your own schema catalog (in case one exists). The next step is just to publish the service on the Upload tool from the Axis2 application.
The POJO implementation might be really slow, since there are other possibilities on how to implement the services using different techniques such as the use of an XML Pullparser, thus, giving direct implementation performance improvements to the developer. I have the idea to measure the execution of different implementations of services, analyzing development and deployment strategies. Everything would just differ on the deployment automation scripts and patch generation.
First of all, install Axis2 service on your application service of choice (Tomcat, in my case). Then, start with the development of the aar POJO service: specifying the methods of the Interface, then describing the type of the messages (in-out, in only, out only) on the services descriptor file. After running the WSDL generator, one can customize the design or integrate with your own schema catalog (in case one exists). The next step is just to publish the service on the Upload tool from the Axis2 application.
The POJO implementation might be really slow, since there are other possibilities on how to implement the services using different techniques such as the use of an XML Pullparser, thus, giving direct implementation performance improvements to the developer. I have the idea to measure the execution of different implementations of services, analyzing development and deployment strategies. Everything would just differ on the deployment automation scripts and patch generation.
Subscribe to:
Posts (Atom)