hobby collection django
It all started when…
My hobby collection of works such as books, games and anime grew to the point where it became obvious my ability to keep track of what I have - and at least as importantly - where I have it would not scale without the aid of technology.
primitive origins
My first attempt at a solution to this issue came at a time when I was primarily versed in C/C++ and had little experience with user interfaces and databases. As a result of working with what I knew, the first iteration of this project actually came in the form of a Win32 console application with numeric menus and command based data input/retrieval. The application could store and query games and videos stored in XML files. This was a step in a positive direction as at the very least I had a tool, crude as it was, to track my collection of games and anime. In daily use, however, it was always obvious the command-based interface and storage mechanism would not scale well.
Moving to the web
C# was the first high-level programming language I learned extensively beyond C++ and I fell in love with it and the .NET framework for its relative elegance and productivity. In an effort to explore web application development I picked my Hobby Collection console app as a prime candidate for a pedagogical project to explore web application development initially via ASP.NET web forms and later ASP.NET MVC. In doing so I transmigrated all data I had been storing in XML files into a SQL database schema. On top of this I built a CRUD web user interface complete with index views and edit forms and used the ASP.NET Entity Framework as an object-relational mapping interface between the frontend and backend. Perhaps needless to say this was a major step up for the project from its primitive origins. It was far more scalable and accessible, gave me experience working with cutting edge .NET features at the time such as LINQ and was my first hands on experience with Inversion of Control and dependency injection via Ninject.
platform-agnostic focus
The ASP.NET MVC version of this project was in use for quite some time. Its design made it relatively easy to maintain and its built-in web admin interface meant I could edit my collection from anywhere with a web browser. It was not without its notable drawbacks, however. The aforementioned admin interface was one I built myself and it was my first attempt at doing so. It was functional and fairly elegant but in a time when I was aware of many high profile web applications and services getting breached, including the infamous PlayStation Network breach with resulted in a prolonged outage, I couldn’t help but question the integrity of my built-in security efforts. In addition to this, the web application was only optimized for desktop browsers and was not responsive for mobile devices. Also, utilizing ASP.NET on the web at a time when IIS/Window Server was the only server-side option as well as Microsoft SQL Server serving as the backend made the project very much a “Microsoft” tech stack. I was beginning to learn how much more extensive and flexible Linux-based hosting options were and I myself had begun embracing Linux via Ubuntu/Linux Mint as an alternative development platform. I was also beginning to browse the web more on mobile devices and regularly experienced firsthand the pain of trying to navigate my Hobby Collection via a smartphone browser. This led to me making the call to not only re-imagine the UX, but also free myself from being tied to a particular platform/vendor and embrace more open source yet polished technologies which I could work with in more of a platform-agnostic fashion.
Enter django
After initially experimenting with Ruby on Rails I eventually discovered and quickly settled on the Django project. The biggest highlight of that discovery was the automatic admin interface which ultimately proved to be an immediate upgrade over my own system. Being a Python framework, embracing Django served to strengthen my skills in reading and writing Python code.
Further enabling my efforts to be more platform-agnostic I was able to migrate my backend data from SQL Server to PostgreSQL which could interface with the Django app via the Psycopg adapter. With Django allowing a degree of freedom to compose view templates I took this opportunity to update and modernize the frontend design language as part of my efforts to make the application more responsive. I utilized the Bootstrap library along with some of my own jQuery-based functionality to rebuild the interface from the ground up with consideration for various viewports and asynchronous data queries for presentation.
The database stores data on my books, games, figures (which often double as photography models), anime/movies/live TV shows and physical music library. The initial versions of both the ASP.NET MVC and Django applications of this project publicly featured every category but I’ve since removed the public view of the audio collection mostly because I don’t feel what’s there showcases much value.
As it exists today
The project continues to evolve and grow with my technical administration skills following suit. It is now hosted on my own AWS infrastructure with a TLS-secured endpoint and responsive design.
It also continues to serve the goal I originally set out to accomplish as my source of truth for what I have in my collection and where I have it while also showcasing it for the world to see. I plan to continue developing this project, building a REST API and a native mobile application.
Hobby Collection Django can be viewed at collectiondj.oneokami.com