Article
· Jan 31 3m read

Implemented Ideas: Examples to work with IRIS from Django

Django, a high-level web framework written in Python, has become a staple for developers seeking a robust, efficient, and easy-to-learn solution for building web applications. Its popularity stems from its versatility, offering developers an efficient toolkit for building web applications. Integrating Django with InterSystems IRIS introduces a dynamic synergy, providing developers with a comprehensive web development and database management solution. That's why on the Ideas Portal, @Evgeny Shvarov suggested that having Examples to work with IRIS from Django would be beneficial. In this article, we'll explore two projects created to answer the posted idea — Django-iris by @Dmitry Maslennikov and Iris-size-django by @Heloisa Paiva.

        

In his application Django-iris@Dmitry Maslennikov introduced a new driver for Django for IRIS based on Python DB-API. This driver was a game changer because it set the foundation for complex projects based on Python and IRIS. The application's author followed the initial release with a series of articles showing an example of the usage of the developed driver: Introduction to Django part 1Introduction to Django part 2 and Introduction to Django part 3. Different articles use different approaches and nuances of working with IRIS using Django.

The other example provided by @Heloisa Paiva in her Iris-size-django gives a bit more practical example of usage. It is a portal for visualizing and keeping track of memory usage of an InterSystems IRIS instance. It shows a table with a database path, global, allocated size and size in use for each global, and aggregation sums at the end. 

This app offers an easy interface to analyze memory:

  • Filter by database (namespace), global name, used size, or allocated size;
  • View a sum of the used and allocated sizes for the filters applied;
  • Export the table to JSON, CSV, or XML.

image

You can read more about this application in the series of articles posted by @Heloisa PaivaA portal to manage memory made with Django - Part 1 and A portal to manage memory made with Django - Part 2.

When asked to tell a bit about why and how she created this application, @Heloisa Paiva shared her thoughts.

1. Why was the implementation of this idea interesting for you?

Paiva highlights the common challenge faced by developers—limited time and a preference for in-demand solutions. She aimed to provide a quick, real-life solution that showcased the power of Django and InterSystems. Inspired by the need for a user-friendly portal to analyze memory, she merged the requirements of her developer friends with the broader community's demand for specific examples, creating a solution that addresses both needs efficiently.

2. What impressed you the most during the implementation?

Paiva expresses her admiration for Python's simplicity and Django's robustness as a web framework. She emphasizes the ease of learning Python and the rapid development capabilities offered by Django. Combining these strengths with InterSystems IRIS amplifies the value and sparks creativity. The seamless integration allows developers to focus on complex solutions rather than spending excessive time on basic aspects.

3. What would you like to change in your solution based on your latest experience?

Reflecting on her latest experience, Paiva expresses a desire to enhance user-friendliness. She aims to make the solution available through a container and enable user-friendly installation and configuration. Additionally, she envisions adding flexibility by allowing database connections to be edited directly on the webpage, modifying file paths for data export, and introducing filters for table names. While these improvements are on her wishlist, Paiva acknowledges the dynamic nature of development demands.

Solutions developed by Dmitry and Heloisa were downloaded 66 and 19 times respectively. It means that a lot of Developer Community members used or at least tested these applications. The solution developed by Heloisa has a review from user @Sergey Mikhailenko entitled: “A great example of using Django for IRIS”.


Feel free to share your feedback about the highlighted idea and its implementations in the comments.

Don’t forget to vote and comment on ideas, promote your ideas to other Community Members for voting!

Discussion (0)1
Log in or sign up to continue