Overview
This time I joined a team DueDates-polu, and 4 developers in my group tried our best to enhance DueDates. So far DueDates was a command base application, but now we used web application framework called Wicket.
Process
We used Google code hosting to manage our project. It has functionality for Issues, svn, wiki, and many things we need. Everybody in my team worked well for the project. We split our project into small tasks and tried to set own due time for each tasks.
Communication
The best procedure of software development would be pair programming, however since everybody has different schedule we mostly met only before and after class to discuss our issues, for a few hours. So we often discussed online using Google chat. One thing I found out this time is, Google chat automatically saves what we typed, and we can see it under "Inbox" of G-mail. Since we discuss about our issues, it's very useful that we can take a look at the record anytime.
Development
I think we finished all the requirements. We also tried to enhance it for Extra Credit 2 and 3, which is back-end database and background processing, but we were not able to complete it and we are running out of time. I will try to experiment during winter break.
Software ICU
We also used a tool called Hackystat, and it automatically sends data to server while we work on Eclipse and it shows many aspects of how we are doing for our project. The only issue with that is, sometimes it takes a while that Hackystat sends our data to server. For example, if I worked on (S), it will not show there until (W), I think.
Conclusion
This was one of the most interesting project I did in my ICS courses. I think the reason is that group members help each other and each of them have their own strength. Rather than working alone, this time we could ask. If there is a next opportunity, I want to do more pair programming.
Our project
http://code.google.com/p/duedates-polu/
12/08/2008
11/21/2008
Stack Wicket
Overview
Last week I worked to use Wicket to enhance stack-johnson, so that everybody can use it on the web browser. With this, people do not need to use command prompt which is hard for some people, and also they even do not need to download the program.
What is Wicket?
Wicket is a web application framework for Java developers. Wicket focuses on programming with components and tries to use object oriented programming in web application. It is now part of Apache project.
Setup
Before I start development, I did setup for Jetty, Wicket, and SLF4J. Jetty is Java base web server, and SLF4J is library for logging.
Development
My professor provided us great examples of how Wicket works at the following.
http://code.google.com/p/ics-wicket-examples/
I was wondering how Jetty finds right html to display, but after looking at his Example01, I found out why. The program was executed in following order.
build.xml > Jetty > ExampleApplication > HelloWorldPage
ExampleApplication uses getHomePage to set HelloWorldPage as home page, then it works with HelloWorldPage.html to display. It was interesting to know its program flow.
Then I looked through examples and API for [ Jetty ] and [ Wicket ] to develop the application.
Conclusion
Implementing first Wicket application was very fun. Now I can access the program from anywhere. I'm looking forward to develop next applications. By the way, another wonderful resource I recommend is [ Wicket in Action ], which is available in both book and eBook.
The Wicket application can be downloaded from here.
Last week I worked to use Wicket to enhance stack-johnson, so that everybody can use it on the web browser. With this, people do not need to use command prompt which is hard for some people, and also they even do not need to download the program.
What is Wicket?
Wicket is a web application framework for Java developers. Wicket focuses on programming with components and tries to use object oriented programming in web application. It is now part of Apache project.
Setup
Before I start development, I did setup for Jetty, Wicket, and SLF4J. Jetty is Java base web server, and SLF4J is library for logging.
Development
My professor provided us great examples of how Wicket works at the following.
http://code.google.com/p/ics-wicket-examples/
I was wondering how Jetty finds right html to display, but after looking at his Example01, I found out why. The program was executed in following order.
build.xml > Jetty > ExampleApplication > HelloWorldPage
ExampleApplication uses getHomePage to set HelloWorldPage as home page, then it works with HelloWorldPage.html to display. It was interesting to know its program flow.
Then I looked through examples and API for [ Jetty ] and [ Wicket ] to develop the application.
Conclusion
Implementing first Wicket application was very fun. Now I can access the program from anywhere. I'm looking forward to develop next applications. By the way, another wonderful resource I recommend is [ Wicket in Action ], which is available in both book and eBook.
The Wicket application can be downloaded from here.
ICS Industry Day
Overview
This Thursday UH Manoa had ICS Industry Day, which many tech compnaies from Hawaii do presentation about their business. Below are companies that I took a look.
1. Datahouse
They often develop software with Ruby on Rails, C#, and PHP. Their clients include government, educational organization, financial services, and etc.
2. Camber Corporation
Since Ikayzo was late for the presentation, Camber Corporation did presentation after datahouse. Camber Corporation has its office nationwide and they make various applications. On their slide, there were many keywords that sound interesting. Here is a list of that and I will search more and experiment if I need it.
rubyonrails.org
Active Scaffold
REST
Flex
ExtJS
Google Earth / KML
BackgrounDRb
3. Ikayzo
Ikayzo developed TechHui. Some of their software also works for several languages including Japanese and Taiwanese. Many famous companies including Oracle purchased commercial licenses of their software.
4. Concentris Systems
They talked about their router which utilize mesh network. It allows traffic to split and provides us more reliable connection.
Conclusion
I learned many things from these presentations such as programming trend, what they develop, and ideal candidate as employees. In terms of programming trend, I have an impression that most of them talked about Ruby on Rails. In ICS department at UH, it is good to learn assembly language in order to understand computer architecture, but I also wanted to learn practical things such as Ruby and PHP.
With these presentations I really thought there are many great tech companies in Hawaii. In general I think we don't have strong image that Hawaii is a place for technology, but if these tech companies continue to develop great products as they do now, Hawaii can be like Sillicon Valley. It was really good experience to join ICS Industry Day. Whenever there is next opportunity, I want to join again.
This Thursday UH Manoa had ICS Industry Day, which many tech compnaies from Hawaii do presentation about their business. Below are companies that I took a look.
1. Datahouse
They often develop software with Ruby on Rails, C#, and PHP. Their clients include government, educational organization, financial services, and etc.
2. Camber Corporation
Since Ikayzo was late for the presentation, Camber Corporation did presentation after datahouse. Camber Corporation has its office nationwide and they make various applications. On their slide, there were many keywords that sound interesting. Here is a list of that and I will search more and experiment if I need it.
rubyonrails.org
Active Scaffold
REST
Flex
ExtJS
Google Earth / KML
BackgrounDRb
3. Ikayzo
Ikayzo developed TechHui. Some of their software also works for several languages including Japanese and Taiwanese. Many famous companies including Oracle purchased commercial licenses of their software.
4. Concentris Systems
They talked about their router which utilize mesh network. It allows traffic to split and provides us more reliable connection.
Conclusion
I learned many things from these presentations such as programming trend, what they develop, and ideal candidate as employees. In terms of programming trend, I have an impression that most of them talked about Ruby on Rails. In ICS department at UH, it is good to learn assembly language in order to understand computer architecture, but I also wanted to learn practical things such as Ruby and PHP.
With these presentations I really thought there are many great tech companies in Hawaii. In general I think we don't have strong image that Hawaii is a place for technology, but if these tech companies continue to develop great products as they do now, Hawaii can be like Sillicon Valley. It was really good experience to join ICS Industry Day. Whenever there is next opportunity, I want to join again.
11/17/2008
DueDates 1.2
Overview
We want to make DueDates even more useful to users and decided to add 3 more options as follow.
1. -console
Report will be sent to the console.
usage: -console
2. -email
E-mail will be sent to the address using the supplied SMTP server.
usage: -email < emailaccount > < smtpserver >
3. -wakeup
Program will run and check for due items with given interval.
usage: -wakeup < interval >
Process
I and my partner Jeho Jung worked on this development last week. We have been working as a partner for a while toward development of DueDates and now we really understand the most efficient way to proceed is pair programming. Our houses are close, so we met a few times and shared our knowledge.
Conclusion
With this update, now this program is able to do useful task. For example, following execution will run the program once a day and checks if there are books due within next 24 hours. If there is, the program will send E-mail and if not it does nothing.
-email name@hawaii.edu mail.hawaii.edu -wakeup 1 -within 1
I think this is a very useful option since people these days are busy and tend to forget many things. For now it only notifies us about books in the library, but if it had functions to tell us anything due it would be more useful. If I had enough time, I want to add such functions in the future.
We want to make DueDates even more useful to users and decided to add 3 more options as follow.
1. -console
Report will be sent to the console.
usage: -console
2. -email
E-mail will be sent to the address using the supplied SMTP server.
usage: -email < emailaccount > < smtpserver >
3. -wakeup
Program will run and check for due items with given interval.
usage: -wakeup < interval >
Process
I and my partner Jeho Jung worked on this development last week. We have been working as a partner for a while toward development of DueDates and now we really understand the most efficient way to proceed is pair programming. Our houses are close, so we met a few times and shared our knowledge.
Conclusion
With this update, now this program is able to do useful task. For example, following execution will run the program once a day and checks if there are books due within next 24 hours. If there is, the program will send E-mail and if not it does nothing.
-email name@hawaii.edu mail.hawaii.edu -wakeup 1 -within 1
I think this is a very useful option since people these days are busy and tend to forget many things. For now it only notifies us about books in the library, but if it had functions to tell us anything due it would be more useful. If I had enough time, I want to add such functions in the future.
11/07/2008
Software ICU
Software ICU tells us the condition of the software, indeed its health. For this time I took advantage of an open source software called Hackystat. Its role is to show various information such as coverage, complexity, coupling, and etc. I installed JavaNCSS and DependencyFinder here so that it will work on complexity and coupling respectively.
Result
Here is brief summary of vital signs.
For now coverage of duedates-green is low, so the source code should be modified to improve its reliability. Except that, Hackystat is showing we are not in danger.
Conclusion
Although it takes a while to download and setup various tools for Eclipse, Hackystat allows us to easily understand the condition and health of our software project. It is also possible to manually run each tools, but we are programmers and we should let computers to do it automatically. Hackystat is very useful which accomplishes that task.
Result
Here is brief summary of vital signs.
Vital Signs | What to measure |
Coverage | Percentage of code executed by tests. |
Complexity | Density of branches and loops. |
Coupling | Number of dependencies between classes. |
Churn | Lines of code added, deleted, and modified in a commit. |
CodeIssue | Number of warnings generated by QA tools. |
Commit | Number of commits to the repository. |
Build | Number of builds. |
UnitTest | Number of unit tests. |
Size | Amount of code. |
DevTime | Time spent. |
For now coverage of duedates-green is low, so the source code should be modified to improve its reliability. Except that, Hackystat is showing we are not in danger.
Conclusion
Although it takes a while to download and setup various tools for Eclipse, Hackystat allows us to easily understand the condition and health of our software project. It is also possible to manually run each tools, but we are programmers and we should let computers to do it automatically. Hackystat is very useful which accomplishes that task.
10/24/2008
Project Review: DueDates
Overview:
It's always good to review each other. It allows us to take a look at source code of others so that we get new insight. At the same time we also get comments from other developers about what was good or what should be improved. Therefore we did review on our project, DueDates.
Process:
First of all, members of each project made a copy of their source code to "svn/tags/Review-2008-10-20". We did it because this way we can save frozen snapshot of the system. If developers want to update their source code in "trunk", they don't need to wait for reviewers to finish and can always make changes.
Next we started to review source code of other projects. From the project page I went to "Source > Browser" and took a look at "svn/tags/Review-2008-10-20". I will see the code, so if there is something I noticed and I want to make comments, I do it by double-clicking the code so that small section to post will pop up. Then I went to "Changes" which is located right next to "Browse" and clicked the version I reviewed, then left comments there.
Review:
It's really good to know how other developers tried their best for the development. Since we worked on the same problem, we can easily understand the flow of program and what the issue is. Here is something I learned from other projects. One project was showing "Processing..." while they connect to database and get a result. I was thinking the connecting process takes a little long but didn't show any words like this. I think this is very user friendly. Other project was showing menu. It's also nice since as we enhance this project later it will have a lot more capability, and instead of using option we can choose from menu. For my project, I got some comments that I should clean up a bit more, and also some comments that our output of the library information is easily understandable to read.
Conclusion:
Reviewing is a really good way to improve each other. The only con is it takes some time to give out useful comments. I thought Google Code is a very useful tool for this purpose. When I make a review next time, I will take notes of what others were doing and I will try to remember them for future use.
It's always good to review each other. It allows us to take a look at source code of others so that we get new insight. At the same time we also get comments from other developers about what was good or what should be improved. Therefore we did review on our project, DueDates.
Process:
First of all, members of each project made a copy of their source code to "svn/tags/Review-2008-10-20". We did it because this way we can save frozen snapshot of the system. If developers want to update their source code in "trunk", they don't need to wait for reviewers to finish and can always make changes.
Next we started to review source code of other projects. From the project page I went to "Source > Browser" and took a look at "svn/tags/Review-2008-10-20". I will see the code, so if there is something I noticed and I want to make comments, I do it by double-clicking the code so that small section to post will pop up. Then I went to "Changes" which is located right next to "Browse" and clicked the version I reviewed, then left comments there.
Review:
It's really good to know how other developers tried their best for the development. Since we worked on the same problem, we can easily understand the flow of program and what the issue is. Here is something I learned from other projects. One project was showing "Processing..." while they connect to database and get a result. I was thinking the connecting process takes a little long but didn't show any words like this. I think this is very user friendly. Other project was showing menu. It's also nice since as we enhance this project later it will have a lot more capability, and instead of using option we can choose from menu. For my project, I got some comments that I should clean up a bit more, and also some comments that our output of the library information is easily understandable to read.
Conclusion:
Reviewing is a really good way to improve each other. The only con is it takes some time to give out useful comments. I thought Google Code is a very useful tool for this purpose. When I make a review next time, I will take notes of what others were doing and I will try to remember them for future use.
10/20/2008
Creating a project DueDates
Overview:
DueDates is a command base program that allows us to access library database and get information about our own account. I worked with Jeho Jung to enhance this project.
Procedures as a team:
It was challenging to do project with partners since our schedule are different, but we discussed about the project somehow and worked on it step by step. Since there were many things to do, we split work into subproblems and set deadline for each. That way we don't feel too much pressure and we can see if we are on the right track in terms of schedule.
Enhance:
First of all, we worked on formatting output. Since the original project didn't show due date, we added a feature to access it and format using String.format(). It was interesting to know we can use format such as "%1$-15s %2$-70s", which is similar to C language. Then we worked on error handling to check if it shows user friendly message. Lastly we worked on test case to make sure everything works well.
We also worked on writing Wiki page for UserGuide and DeveloperGuide while we enhance DueDates. Those Wiki pages are guide to others and at the same time they are notes for ourselves to remember later.
Conclustion:
Dealing with DueDates was a good review of what we learned so far in software engineering class. Now I'm confident with working on any projects in the world with other developers.
Our project, duedates-green
http://code.google.com/p/duedates-green/
executable jar file
http://duedates-green.googlecode.com/files/DueDates.jar
DueDates is a command base program that allows us to access library database and get information about our own account. I worked with Jeho Jung to enhance this project.
Procedures as a team:
It was challenging to do project with partners since our schedule are different, but we discussed about the project somehow and worked on it step by step. Since there were many things to do, we split work into subproblems and set deadline for each. That way we don't feel too much pressure and we can see if we are on the right track in terms of schedule.
Enhance:
First of all, we worked on formatting output. Since the original project didn't show due date, we added a feature to access it and format using String.format(). It was interesting to know we can use format such as "%1$-15s %2$-70s", which is similar to C language. Then we worked on error handling to check if it shows user friendly message. Lastly we worked on test case to make sure everything works well.
We also worked on writing Wiki page for UserGuide and DeveloperGuide while we enhance DueDates. Those Wiki pages are guide to others and at the same time they are notes for ourselves to remember later.
Conclustion:
Dealing with DueDates was a good review of what we learned so far in software engineering class. Now I'm confident with working on any projects in the world with other developers.
Our project, duedates-green
http://code.google.com/p/duedates-green/
executable jar file
http://duedates-green.googlecode.com/files/DueDates.jar
10/08/2008
Working with other developers on Google Code
This time I will experiment how to work with other developer using Google Code. Since I joined my partner's project stack-klau4, I checked out from https://stack-klau4.googlecode.com/svn/trunk.
After I checked out, I did verify as usual and it passed as I expect. Since there didn't exist any problem, I improved javadoc and committed.
The very important step is to do SVN Update right before I commit, so that if multiple developers made a change to the code it can be merged. Also I need to do verify and it must pass.
TortoiseSVN is a very useful tool that tells me if I made some change to the code. Its interface such as SVN Update or Commit is also easy to understand. It can be invoked from command line and there are more features that I need to explore. I haven't tried other SVN clients but I recommend TortoiseSVN.
With such useful tool, now I got how to work with other developers.
After I checked out, I did verify as usual and it passed as I expect. Since there didn't exist any problem, I improved javadoc and committed.
The very important step is to do SVN Update right before I commit, so that if multiple developers made a change to the code it can be merged. Also I need to do verify and it must pass.
TortoiseSVN is a very useful tool that tells me if I made some change to the code. Its interface such as SVN Update or Commit is also easy to understand. It can be invoked from command line and there are more features that I need to explore. I haven't tried other SVN clients but I recommend TortoiseSVN.
With such useful tool, now I got how to work with other developers.
Configuration management
In software engineering configuration management is one of the most important factor. For this time I will experiment SVN to work with other developers.
Initial Setup
I'm Windows user so that I installed TortoiseSVN, which is a client software of SVN. Next I decided where to store all the data, which is called repository. Since TortoiseSVN works with right click, I did it and chose "SVN Check Out" to connect to host. When I do check out, very important thing is to use https instead of http. This allows me to commit after change.
Create a new Google Hosting Project
Next I tried to experiment being an owner of the project, so that I made "stack-yasu" and dicussion list called "stack-yasu-discuss".
http://code.google.com/p/stack-yasu/
http://groups.google.com/group/stack-yasu-discuss
I also checked if codesite-noreply@google.com is working, and it does.
Now I can share my project and take advantage of it when I work with other developers to build a large system.
Initial Setup
I'm Windows user so that I installed TortoiseSVN, which is a client software of SVN. Next I decided where to store all the data, which is called repository. Since TortoiseSVN works with right click, I did it and chose "SVN Check Out" to connect to host. When I do check out, very important thing is to use https instead of http. This allows me to commit after change.
Create a new Google Hosting Project
Next I tried to experiment being an owner of the project, so that I made "stack-yasu" and dicussion list called "stack-yasu-discuss".
http://code.google.com/p/stack-yasu/
http://groups.google.com/group/stack-yasu-discuss
I also checked if codesite-noreply@google.com is working, and it does.
Now I can share my project and take advantage of it when I work with other developers to build a large system.
10/02/2008
StackOverflow
A programming Q&A site called StackOverflow was released. I like this kind of Q&A site and I have been using such website for a while when I cannot solve problems. Sometimes I get answers in 3 minutes and sometimes I don't get any reply, but it is wonderful that I can get right answer without any fee. I also think it's ok to pay if somebody gives me right information that I really want.
When I opened StackOverflow, the first thing I looked for is category. On this website category is called Tags, which can be found on top. When I clicked on that, many different tags can be found. I'm impressed that it has a lot more tags than other websites have. Minor topics such as regex, jquery, and flex were also there.
Make a post
Then I posted a question to see if I can get answers. Right before I make a post, it showed related questions and I thought it was good idea, since they can prevent overlap. My question is about JavaScript, "Can I pass parameter from different page?".
http://stackoverflow.com/questions/163444/can-i-pass-parameter-from-different-page
Surprisingly, I got a reply in 1 minute and got totally 5 replies in 8 minutes. Their answers are very specific and I got how to do it.
Vote and point system
I looked around the website and thought its voting and point system is interesting. If developers think the question is useful, they vote and we can find useful Q&A more easily. For the point system, developers with more points have more authority on this website. I think this is a good idea, but comment also requires people to have 50 points. This has good and bad aspects. With that they are able to prevent spam, but at the same time people who can comment will be a little limited.
Look around
There are a lot of questions that look interesting such as "How many people disable Javascript?" or "How Should a Non-Designer Interview a Web Designer?", and reading those will be more useful than reading ordinary newspaper.
Conclusion
For now StackOverflow doesn't have any ad posted, but since it is useful I think it is ok to put it in the future. It costs for hosting and maintenance, so it can be covered with that. The most impressed thing about this website is that I get quality responses very fast. It makes me think a lot of developers check this website often, and it is also very important thing for this kind of site. I'm glad that I get to know this website and I will use more to improve my technical skill.
http://stackoverflow.com
When I opened StackOverflow, the first thing I looked for is category. On this website category is called Tags, which can be found on top. When I clicked on that, many different tags can be found. I'm impressed that it has a lot more tags than other websites have. Minor topics such as regex, jquery, and flex were also there.
Make a post
Then I posted a question to see if I can get answers. Right before I make a post, it showed related questions and I thought it was good idea, since they can prevent overlap. My question is about JavaScript, "Can I pass parameter from different page?".
http://stackoverflow.com/questions/163444/can-i-pass-parameter-from-different-page
Surprisingly, I got a reply in 1 minute and got totally 5 replies in 8 minutes. Their answers are very specific and I got how to do it.
Vote and point system
I looked around the website and thought its voting and point system is interesting. If developers think the question is useful, they vote and we can find useful Q&A more easily. For the point system, developers with more points have more authority on this website. I think this is a good idea, but comment also requires people to have 50 points. This has good and bad aspects. With that they are able to prevent spam, but at the same time people who can comment will be a little limited.
Look around
There are a lot of questions that look interesting such as "How many people disable Javascript?" or "How Should a Non-Designer Interview a Web Designer?", and reading those will be more useful than reading ordinary newspaper.
Conclusion
For now StackOverflow doesn't have any ad posted, but since it is useful I think it is ok to put it in the future. It costs for hosting and maintenance, so it can be covered with that. The most impressed thing about this website is that I get quality responses very fast. It makes me think a lot of developers check this website often, and it is also very important thing for this kind of site. I'm glad that I get to know this website and I will use more to improve my technical skill.
http://stackoverflow.com
10/01/2008
Limitations of test coverage
I fixed Stack so that now Emma shows its coverage is 100%. However, some developers say it still possibly have bugs. This time, I try to put a bug in the code and still make it to have 100% coverage.
Insert a bug
After thinking for a while, I found out that I am able to do it by changing "this.top();" to "this.pop();" inside "getTop()". Emma still shows its coverage is 100%, but logically it returns different object.
Conclusion
I successfully inserted a bug in the code, yet Emma shows its coverage is 100%. This means that we are not able to think the code has definitely no bugs even the coverage is 100%. It is true that Emma help us a lot to detect what we didn't test yet or which part possibly have bugs, but we will need to do final check manually in order to make a reliable and secure system.
The code with a bug can be downloaded from here.
Insert a bug
After thinking for a while, I found out that I am able to do it by changing "this.top();" to "this.pop();" inside "getTop()". Emma still shows its coverage is 100%, but logically it returns different object.
Conclusion
I successfully inserted a bug in the code, yet Emma shows its coverage is 100%. This means that we are not able to think the code has definitely no bugs even the coverage is 100%. It is true that Emma help us a lot to detect what we didn't test yet or which part possibly have bugs, but we will need to do final check manually in order to make a reliable and secure system.
The code with a bug can be downloaded from here.
Testing with Emma + JUnit
In the previous entry I fixed various errors to pass Checkstyle, FindBugs, JUnit, and PMD, so that I got verified. However, if I take a look at the report of Emma, it says the coverage is still 82% for method, 72% for block, and 80% for line. This time, I will try to fix even more so that its line coverage is going to be 100%.
Adding Test Cases
On the report, red background specifies I haven't tested that part. It was shown that I didn't test methods such as toString, getTop, and etc. To fix it, I wroite a test case for those using methods such as "assertEquals()" or "testIllegalTop()".
While I was writing test cases, I also checked javadoc of JUnit and it helped me understand what the method is doing. There are a lot of methods that look useful, so in the future I will try those to test my code in various ways. On my PC, javadoc was located in the following address.
file:///C:/000/eclipse/tools/junit4.5/javadoc/index.html
Conclusion
Emma is a useful tool that let us know where we didn't test and allows us to fix it. By doing it we are able to improve the quality of the system and make it more reliable.
The fixed code can be downloaded from here.
Adding Test Cases
On the report, red background specifies I haven't tested that part. It was shown that I didn't test methods such as toString, getTop, and etc. To fix it, I wroite a test case for those using methods such as "assertEquals()" or "testIllegalTop()".
While I was writing test cases, I also checked javadoc of JUnit and it helped me understand what the method is doing. There are a lot of methods that look useful, so in the future I will try those to test my code in various ways. On my PC, javadoc was located in the following address.
file:///C:/000/eclipse/tools/junit4.5/javadoc/index.html
Conclusion
Emma is a useful tool that let us know where we didn't test and allows us to fix it. By doing it we are able to improve the quality of the system and make it more reliable.
The fixed code can be downloaded from here.
9/24/2008
Automated QA vs. manual QA
Overview
My task is to get used to various tools which is helpful in software development. Those tools include Ant, FindBugs, Checkstyle, and PMD. Then I need to think about pro and cons of automated QA and manual QA.
Checkstyle
I got 382 errors on my CodeRuler project, but errors from MyRuler.java are 17 and rest of them is from IBM. It says that MyRuler.java misses some Javadoc comments, and '}' should be alone, and we should use "{}", and so on. Most errors for IBM are about using tab character. Reviewer of my code also found those errors, but it would be fast if we use checkstyle. I think some of them can be fixed easily by using format feature of Eclipse.
PMD
There was 11 violations, and some of them says "avoid if(x != y)...; else...;" or "Avoid using if... else statement without using curly braces." Reviewer of my code also indicated those errors.
FindBugs
There was 1 warning, which was saying "Method MyRuler.initialize() uses the same code for two branches." Reviewer of my code did not indicate this. To check the content, it might be better to use this tool.
Conclusion
In terms of quality assurance, automated QA will be faster and more accurate than manual QA. However if we need to think about the logic of the program, we will need to think about it manually.
My task is to get used to various tools which is helpful in software development. Those tools include Ant, FindBugs, Checkstyle, and PMD. Then I need to think about pro and cons of automated QA and manual QA.
Checkstyle
I got 382 errors on my CodeRuler project, but errors from MyRuler.java are 17 and rest of them is from IBM. It says that MyRuler.java misses some Javadoc comments, and '}' should be alone, and we should use "{}", and so on. Most errors for IBM are about using tab character. Reviewer of my code also found those errors, but it would be fast if we use checkstyle. I think some of them can be fixed easily by using format feature of Eclipse.
PMD
There was 11 violations, and some of them says "avoid if(x != y)...; else...;" or "Avoid using if... else statement without using curly braces." Reviewer of my code also indicated those errors.
FindBugs
There was 1 warning, which was saying "Method MyRuler.initialize() uses the same code for two branches." Reviewer of my code did not indicate this. To check the content, it might be better to use this tool.
Conclusion
In terms of quality assurance, automated QA will be faster and more accurate than manual QA. However if we need to think about the logic of the program, we will need to think about it manually.
Stack
Overview
My task is to use various tools and fix Stack.
Task 1: Installation
I think installation was the hardest part of this assignment. After all I realized everything was explained in class, but it took me around 3 hours to setup all. I thought I should pay attention in class and take notes more. Below is the list of what I did to make it work. I often forget these kind of things so I write as a reminder.
1. Download Files
2. Set path for those tools
3. Create environment variables for those tools
4. Create an environment variable, JAVA_HOME
5. Restart PC
Task 2: Use Stack to create new project.
I just followed the instructions and everything went well.
Task 3: Fix the problems.
Since many useful tools told me where the error is, it didn't take a while to fix it.
Conclusion
I thought these tools are really useful in software engineering. It told me many errors and warnings that compiler never told me. It was a good opportunity and from now on I will take advantage of these tools when I develop software.
Zip File: Fixed Stack
My task is to use various tools and fix Stack.
Task 1: Installation
I think installation was the hardest part of this assignment. After all I realized everything was explained in class, but it took me around 3 hours to setup all. I thought I should pay attention in class and take notes more. Below is the list of what I did to make it work. I often forget these kind of things so I write as a reminder.
1. Download Files
2. Set path for those tools
3. Create environment variables for those tools
4. Create an environment variable, JAVA_HOME
5. Restart PC
Task 2: Use Stack to create new project.
I just followed the instructions and everything went well.
Task 3: Fix the problems.
Since many useful tools told me where the error is, it didn't take a while to fix it.
Conclusion
I thought these tools are really useful in software engineering. It told me many errors and warnings that compiler never told me. It was a good opportunity and from now on I will take advantage of these tools when I develop software.
Zip File: Fixed Stack
9/15/2008
CodeRuler Review
Overview
My task is to take a look at source code of other group "lau-sanchez", and check violations of Java coding and documentation standards. I should also take a look at how they implemented their strategy.
I run the code several times and their strategy was doing well against opponents. They won almost all. After reviewing their source code, I found some violations of Java coding standards.
Summary
Although their JavaDoc is not perfectly accurate, there are enough comments and organized structures that make me understand what they implemented. I also thought their strategy is effective.
Following coding style takes some time but it is also important, because in a real software engineering many programmers work together and if they do not follow it, it will be hard to do maintenance later.
Fortunately, now we have a useful tool such as format function of Eclipse. Some violations will be fixed with that. Eclipse also has a plug-in called Checkstyle, and it will help us follow coding styles more.
My task is to take a look at source code of other group "lau-sanchez", and check violations of Java coding and documentation standards. I should also take a look at how they implemented their strategy.
I run the code several times and their strategy was doing well against opponents. They won almost all. After reviewing their source code, I found some violations of Java coding standards.
File | Lines | Violation | Comments |
MyRuler.java | 1 | ICS-SE-Java-1 | All code should be within the package hierarchy "edu.hawaii". |
MyRuler.java | 4 | ICS-SE-Java-2 | Wildcard "*" is used in import statements. |
MyRuler.java | 7,15 | ICS-SE-Java-6 | JavaDoc is separated in two parts. |
MyRuler.java | 7,8,42,* | ICS-SE-Java-6 | JavaDoc is not accurately written. |
MyRuler.java | 83,87,90 | ICS-SE-Eclipse-2 | There are 3 spaces instead of 2. |
MyRuler.java | 96,97,98,* | ICS-SE-Eclipse-2 | There should be indent. |
MyRuler.java | 101,102 | EJS-2 | Curly brackets should be used. |
MyRuler.java | 111,142,169,* | ICS-SE-Java-6 | Beginning of the sentence should be capitalized. |
MyRuler.java | 159 | EJS-9 | Meaningful name should be used. |
Summary
Although their JavaDoc is not perfectly accurate, there are enough comments and organized structures that make me understand what they implemented. I also thought their strategy is effective.
Following coding style takes some time but it is also important, because in a real software engineering many programmers work together and if they do not follow it, it will be hard to do maintenance later.
Fortunately, now we have a useful tool such as format function of Eclipse. Some violations will be fixed with that. Eclipse also has a plug-in called Checkstyle, and it will help us follow coding styles more.
9/08/2008
Lessons learned from Code Ruler
Overview
CodeRuler is a game program from IBM, but it if different from ordinary games because we are able to control our force only with Java code. This program was made for students to let them practice Java. My task is to work with John Ly and beat sample Code Rulers.
My Group Members:
John Ly
Yasu Kaneshige (me)
Source Download:
Source
Results:
Lessons Learned:
Working with other team member takes a little more time because we need to discuss everything we have on our mind. However once we do it, we are able to split our work and have more ideas about the program.
For the Eclipse, it was good experience because now I know how to use plugin. I also got used to using its features such as auto format or making projects.
I think CodeRuler is a good program for exercise, because it reminds me basic materials like how to use interface or extend. Also there is infinity number of strategy that we can implement and we should think about what is the best way. It made me write pseudocode, which is also an important step when writing a program.
CodeRuler is a game program from IBM, but it if different from ordinary games because we are able to control our force only with Java code. This program was made for students to let them practice Java. My task is to work with John Ly and beat sample Code Rulers.
My Group Members:
John Ly
Yasu Kaneshige (me)
Source Download:
Source
Results:
Sample Ruler | Game | My Ruler | Opponent | Migrate Ruler | 1 | 477 | 5 | Migrate Ruler | 2 | 656 | 0 | Migrate Ruler | 3 | 565 | 10 | Gang Up Ruler | 1 | 634 | 36 | Gang Up Ruler | 2 | 536 | 119 | Gang Up Ruler | 3 | 549 | 54 | Split Up Ruler | 1 | 444 | 48 | Split Up Ruler | 2 | 571 | 77 | Split Up Ruler | 3 | 556 | 108 |
Lessons Learned:
Working with other team member takes a little more time because we need to discuss everything we have on our mind. However once we do it, we are able to split our work and have more ideas about the program.
For the Eclipse, it was good experience because now I know how to use plugin. I also got used to using its features such as auto format or making projects.
I think CodeRuler is a good program for exercise, because it reminds me basic materials like how to use interface or extend. Also there is infinity number of strategy that we can implement and we should think about what is the best way. It made me write pseudocode, which is also an important step when writing a program.
9/01/2008
The Open Source Software Experience
Overview
My task is to evaluate Java-based open source software which is available at "sourceforge.net". I chose an application called "XML Interactive Slide Show", which is a program to generate html and css files for slide show. Users will be able to upload those files and share it with others on the web.
XML Interactive Slide Show
http://sourceforge.net/projects/xiss-web/
Prime Directive 1 - The system successfully accomplishes a useful task.
I tried to make slide show with my own photos, and this program successfully made corresponding html and it worked as slide show. I also tried to experiment with large number of files, so I put 40 pictures and it still worked well.
Prime Directive 2 - An external user can successfully install and use the system.
To download and install this application was simple. To use this application, I need to read documentation a bit, otherwise I do not know how to create slide show. The good aspect of this application is users can customize the result with xml file. However it requires some knowledge of xml, therefore it would be better if users are able to customize using GUI.
Prime Directive 3 - An external developer can successfully understand and enhance the system.
Although there is a large documentation about how to use the software, there is relatively few comments and I did not see instructions of how to compile the source code. If the original developer could include those information, other developers will be able to enhance this software more effectively.
8/27/2008
Implementation of FizzBuzz
Tasks:
To implement a program which prints number from 1 to 100, one per line. Exception is, for mutiple of 3 it should print "Fizz", for mutiple of 5 it should print "Buzz", for mutiple of 3 and 5 it should print "FizzBuzz".
Observation:
I didn't have any problem writing this program since it was covered in class. It took less than 5 minutes to make it. However, the more important thing I learned is how to write a test case. With that we are able to know how the value is going to be.
I knew Eclipse has thousands of features for software development, but I didn't know how to use it so I was using Notepad. This semester I'm looking forward to learn those and be able to develop software more efficiently.
To implement a program which prints number from 1 to 100, one per line. Exception is, for mutiple of 3 it should print "Fizz", for mutiple of 5 it should print "Buzz", for mutiple of 3 and 5 it should print "FizzBuzz".
Observation:
I didn't have any problem writing this program since it was covered in class. It took less than 5 minutes to make it. However, the more important thing I learned is how to write a test case. With that we are able to know how the value is going to be.
I knew Eclipse has thousands of features for software development, but I didn't know how to use it so I was using Notepad. This semester I'm looking forward to learn those and be able to develop software more efficiently.
Code:
public class FizzBuzz {
public static void main(String[] args) {
for (int i=1; i<=100; i++) {
if ((i%15) == 0)
System.out.println("FizzBuzz");
else if ((i%3) == 0)
System.out.println("Fizz");
else if ((i%5) == 0)
System.out.println("Buzz");
else
System.out.println(i);
}
}
}
Subscribe to:
Posts (Atom)