Tag Archives: software

My response to “7 Open Source Projects to cut your teeth on (and the ones to avoid)”

I’ve been meaning to write an article about a few of the communities in the open source world. However, I believe that the article “7 Open Source Projects to cut your teeth on (and the ones to avoid)” by Rikki of ITWorld has said what I wanted to. Some of the open source projects that I’ve had good/bad experiences contributing to have been:

Good:

Bad:

  • XBMC [They will not take bug reports or feature suggestions]
  • Tiny-Tiny RSS
  • OpenStack Folsom Install Guide [The official documentation doesn’t agree with some of the suggestions, and I’ve tried to point this out]

I understand that these tend to be non-work projects, and that it can take a lot of work to maintain a community. But its rather frustrating that people who attempt to chip in to help make the system/application/code better are treated rather roughly.

Don’t let the User Fail

One of the things that has been bothering me quite a bit as of late is debugging setup issues with OpenStack. Usually this consists of tracking down errors amongst 12 different log files when something goes wrong. There are multiple issues going on here. Firstly, the guides for setting up OpenStack, Folsom, are not so great, or situated for different environments (multinode vs single-node). [That being said, DevStack is pretty cool and easy to use]  Secondly, debugging a new setup and learning at the same time can be a pain.

The major issue of installing OpenStack could be solved through a dedicated install process. However, the larger issue is that the user is allowed to fail so quickly. It’s similar to refusing to validate an email address prior to submission and processing on a website. My suggestion is that many of these issues can be solved by doing step by step confirmations of the process. For example, if you were to install a web framework, the installation process/script should confirm:

  1. That a server is installed
  2. The installing user has permissions, or can be elevated to the permission level, to install the web application
  3. Copy the files over to the web server and start the web application
  4. The web application prompts for a configuration on the first run (I.e. Checking for writable permissions at the get go, setting up users, etc.)

Asking a system administrator to do all of these manual confirmations causes quite a few issues. For example, Some web applications have an issue with the database configuration after the web site has been put in use.  Lastly, if a script fails it should fail in a sandbox rather than the live environment. Gentoo sandboxes ebuilds prior to installing the executables on the system.

Another thing to note, if a user is configuring a database on install ask for the host, confirm that the host is enabled, and then allow for a database selection.

Review: “What Compsci textbooks don’t tell you: Real world code sucks”

I’ve been catching up on my reading queue. I’ve been quite busy in the last few months that many articles has slipped by me, and they’re in my backlog. One article I’ve been meaning to review is: “What Compsci textbooks don’t tell you: Real world code sucks.” The author attempts to make a claim that textbooks should acknowledge the messy world of software development, or should be less than stellar.

I agree with a few of the author’s points on what causes bad code/designs, however I believe that the author misses the point when he relates it to the content of textbooks. Textbooks are meant to be condensed learning resources. They tend not to be fluffy and full of relatable content. With a textbook one should be able to reliably consume the facts associated with the subject, and not the current commentary of the industry surrounding it. Textbook-code that was relatable to practice would be an inefficient method of delivery to the reader. Unless it is briefly mentioned, it would be silly and unprofessional for a computer science textbook to make snide remarks on real-world coding practices, gender politics/representation in the computer industry, how most technologies are not used fully, or any other non-topic rants within a textbook. A good text book will stand the test of time.

In short, I believe that Mr. Mandl, the author, would be more interested in industry and learning social trends.

PSA: Software Development Tip: Clean out your Code Base

There is a diplomatic mindset that many developers have: It’s better to orphan code, than it is to delete it. This, although less destructive in the short term, can become very destructive in the long run. Leaving orphaned code may:

  • Encourage Reuse later on
  • Dramatically increase build times
  • Increase the amount of time needed to perform version control [A bigger code base takes longer to examine]
  • Reduces one’s ability to navigate through the code.
  • Increase the executable size
  • Increase maintenance times

So in short: If the code is no longer needed and used, remove the dead code. If you’re using source control properly, the change can be reverted.

If the team you are working with still insists on orphaning code, at least have them to agree on periodic spring cleaning of the project.


 

Good News to those who use Maven and are working on J2EE web projects in IntelliJ: Here’s a guide.

 

A Few Signs That Your Project May Be In Some Serious Trouble

  1. Lack of leadership in developer operations
  2. A lack of reporting of improvements in code reuse, coverage, test cases, and stability.
  3. Underutilization of frameworks and libraries used within the project.
  4. Lack of disposable runtime environments [for development and testing].
  5. Build times are unknown.
  6. Long and detailed documentation is required to build your product.
  7. Dead code is left in the code base to rot for years.
  8. Bugs are being reproduced as unit tests.
  9. Third Party dependencies are not being upgraded.
  10. Code is badly organized. Models are placed anywhere, packages aren’t organized, etc.

Review: The Java Virtual Machine Specification: Second Edition (Java 2 Platform)

Despite the age and subtitle. This book is still relevant for the Java 6 and 7 platform. The Java Virtual Machine Specification,by Tim Lindholm and Frank Yellin, is a specification book from a pre-Oracle time. The book goes over how the Java language is structured and designed. This is a great guide for any serious Java developer. The book provides insight on the reasons why things are designed the way they are, Java [assembly like] byte code, the classfile format, and a handy reference for the bytecode [including the op codes].

I read this book for non-professional reasons. It was more of a curiosity to read this book. At times, the book went into more detail than I cared about. Also, I skimmed over the documentation on the bytecode. However, I really did like that it introduced the detailed bytecode documentation and then followed it up with examples of how code is transformed into its related bytecode.

Reading this book should make Java Performance (Hunt) a bit easier to read, understand, and more interesting. That is when I can get to reading the book. At the moment, I have more than 30 [physical and non-physical] books on my reading queue.

Features I’d like to see Added in Wikis

For the last decade, wikis have not changed very much. Even minor features such as AJAX support are still uncommon items. The following is a list of features I’d like to see added. A few of these items are available as plugins, however I am referring to having these features baked into the actual product.

Live Collaborative Editing

If you use Google Documents with others you will notice this: live collaborative editing. Usually the first time that someone notices this it either freaks him out, or just blows his mind. Multiple users can edit the same document at the same time, whilst receiving the changes in real-time. Having this support on a wiki would make the page lock / change conflict problem go away.

Importing Data Framework

It would be immensely helpful to have some sort of feature within a wiki to import data from other sources: images, RSS feeds, CSV feeds, etc. With a uniform way of bringing-in data, plugins could become a bit more generic and support the transformation. For example: let’s say that you have a build system, and it produces a build log file. Wouldn’t it be helpful for having that file be placed on the wiki [within a certain section] where it could be commented on? With a data framework, there could even be a plugin that could grep the output and only show the important sections.

Graphing Support

Charts are important for simple visualizations of data. Why this requires selecting and learning how to use a new plugin is beyond me.

Drawing

Wikis seem to be text based only. I have only found a small handful of plugins that support the editing of pictures. Even fewer use SVG. I’d like to see the ability to edit an SVG picture built into the wiki software.

OpenID

Why wiki software continues to roll their own authentication system by default is beyond me. This item seems like a no brainer. Create an OpenID authentication mechanism that uses the top providers [Yahoo, Google, Facebook]. If need be, revert to a local authentication method if there is a lack of internet access – or if the wiki is being deployed exclusively internally.

APIs for Dealing with Content On The Wiki

Lastly but not the least important, create and promote a uniform wiki API. This would allow for other systems to automatically push content onto the wiki, or pull it. This would be great for a monitoring system to:

  • create a new page on the wiki
  • post configuration details and current state
  • maybe even show statistics

Also with the API, the same monitoring system could grab a wiki page and check for changes in the configuration details. Granted, there are potential issues with the configuration details changing on a wiki, however at the moment this is more of an idea rather than a real world implementation.

Another example: WordPress could use wiki support to have multiple editors collaborate over a post within a wiki Page. WordPress could also, with an API, pull the wiki page to make it a blog post.

New Repository ogg2mp3

Ogg2mp3 is a new script that I adapted from a flac2mp3 script I found elsewhere online. The script allows for you to convert an entire directory of ogg files into their similar MP3 version. This helps those who have MP3 device and players, which do not include support for OGG files. Anyways, I put the script on my GitHub account, and I’m willing to accept pull requests if they improve the script.

Repository: https://github.com/monksy/ogg2mp3

To use this script give the script execute privileges, navigate to the folder which contains the OGG files that you want to convert and run the script. The script will traverse the current directory, and all of the sub –directories within. From there it will convert the OGG file into a MP3 file with the same filename and metadata.

In Support Of Maven

In the last few days there has been an article completely bashing Maven on hacker news. I found this a little aggravating. Much of the article spent time complaining about how the files are structured, and how much effort it takes to maintain a Maven file. Also, the article complained about the plug-in structure.

To some extent I can agree with the original author. The plug-in system makes Maven a little difficult to learn and get completely right. On the other hand, the plug-in system makes it easy to deliver a single meta-build system that can easily adapt to what you need it to do. Building a Java web app? It has a plug-in to build and package it for you.

My main beef with the article is that it completely ignores why we got Maven in the first place. It builds, packages, and manages your dependencies better than ANT does. Before, you had to manually acquire, and grab your dependencies. If you had ANT or make, then you had to include the declarations for the dependencies in the build file, and put the dependency in your project. This is a pain for those that are using source control, and for setting up new developer machines. However, with Maven, just declare the dependency and the scope in the build file and you’re done. If you’re using an IDE it’ll bring in the references and may be able to pull the Javadoc if it’s available. Additionally, any new upgrades to the dependencies could be added just by changing the version number. Imagine doing that without a Maven like build system. Maven can even go the extra mile and create a redistributable package [this is a little tricky, but you can do it], deploy your new package to a repository, check in your code for you, or even deploy it to a webserver. For example, if you have a web service and don’t have Tomcat7 downloaded, run it with an embedded instance with mvn tomcat7:run . You’re done, Maven grabs Tomcat7, its dependences and tries to deploy your webapp to the new instance of Tomcat7. No installation of the server required.

In closing, Maven is a build tool. Unless you’re making project structure changes you shouldn’t be messing about with the way it builds things.

Rant on Web Interfaces: Quick Context Menus

For any of those that have seen one of my highest voted answers, they could conclude that I’m largely in favor of web applications. However, that’s not entirely the case. Many technical journalists, venture capitalists, and startup executives would have you to believe that desktop applications are no longer relevant. To put it simply, that is what they used to say. The “replacement” for desktop applications are mobile applications on a tablet/mobile and a web application. It’s lunacy to make these claims, but they remain unquestioned when someone smug makes them.

There are distinct advantages of having a desktop application. Many of the reasons – I won’t mention or address all of them here – are offline support, OS integration, local computation, tolerance against servers being down, and lower latency. However, imagine if your file manager became web based. You’d pretty much lose the support for contextual menus, or at least until it became a big enough priority for the organization running the site to add it. In the web-based file manager, to email a file, you’d have to open up the file [say a document] and go to file send every time you wanted to email a file. Let’s say you wanted to send the document to be printed at Kinko’s/FedEx: Just hope the provider of the file browser offered that support. What I’m complaining about is the lack of right-click functionality on objects you want to manipulate on the web.

Most applications do this wrong. They tend to list all of the objects [mail, messages, timesheets, etc] you would like to manipulate and then crowd the space with the same repetitive actions on each line (Edit, Delete, etc) Let’s take the example of Gmail: by right-clicking on a message, you don’t get the same options as you do in Outlook. There is no contextual support, you’ll see your standard web browser “contextual menu” (Back, reload, save as, Print [the web page], View Source….) With Outlook you’ll be provided the following options: Open, Print (the message),  Follow up, Reply, Reply All, Forward, Create Rule, Send to Evernote, etc. Imagine how much faster an experienced user would be if that functionality was exposed from the Inbox.

Imagine that you were able to perform a search and then able to perform a right-click action. You’d be given the option to Share, Remove from your search, save the link to some external site, etc. Hotel search sites should give you an option to right click on the hotel and give the option to search nearby, or save to a list elsewhere. Saving to a list for later would be helpful when you are comparing hotels and rates between two locations that are far apart.

Weirdly enough, Google Documents does a good job with their contextual menus. Within a document, right clicking gives you a simplified menu that you’d see in the equivalent desktop application. Even going further, it gives you the ability to “research” the selected text, with the option of Google, Google Scholar, and within your own Google Docs. That’s awesome. In the document view it gives you the options that you’d see in most file managers [Open, Move, change metadata, Delete, etc]. The web client on Dropbox also does a good job about this.
Not all web applications fail to provide menus, some applications do a good job, but they tend to be incredibly rare to see.

Some websites that could benefit from contextual menus:

  • News articles: (Right click for the printable page, sharing highlighted bits, or to qoute in the comments)
  • Most websites that allow you to save an object (individual item to buy, compare etc): Right click to save, or remove the item from the list
  • User generated content sites – Report, ignore [user], reply, and share [to other sites]
  • Pages that display an order confirmation: Bring up the carrier’s tracking page, printable invoice
Related Posts Plugin for WordPress, Blogger...
Better Tag Cloud