Software Architecture

Domain Driven Design For Python - Episode 219

Summary

When your software projects start to scale it becomes a greater challenge to understand and maintain all of the pieces. In this episode Henry Percival shares his experiences working with domain driven design in large Python projects. He explains how it is helpful, and how you can start using it for your own applications. This was an informative conversation about software architecture patterns for large organizations and how they can be used by Python developers.

Announcements

  • Hello and welcome to Podcast.__init__, the podcast about Python and the people who make it great.
  • When you’re ready to launch your next app or want to try a project you hear about on the show, you’ll need somewhere to deploy it, so take a look at our friends over at Linode. With 200 Gbit/s private networking, scalable shared block storage, node balancers, and a 40 Gbit/s public network, all controlled by a brand new API you’ve got everything you need to scale up. And for your tasks that need fast computation, such as training machine learning models, they just launched dedicated CPU instances. Go to pythonpodcast.com/linode to get a $20 credit and launch a new server in under a minute. And don’t forget to thank them for their continued support of this show!
  • And to keep track of how your team is progressing on building new features and squashing bugs, you need a project management system designed by software engineers, for software engineers. Clubhouse lets you craft a workflow that fits your style, including per-team tasks, cross-project epics, a large suite of pre-built integrations, and a simple API for crafting your own. With such an intuitive tool it’s easy to make sure that everyone in the business is on the same page. Podcast.init listeners get 2 months free on any plan by going to pythonpodcast.com/clubhouse today and signing up for a trial.
  • You listen to this show to learn and stay up to date with the ways that Python is being used, including the latest in machine learning and data analysis. For even more opportunities to meet, listen, and learn from your peers you don’t want to miss out on this year’s conference season. We have partnered with organizations such as O’Reilly Media, Dataversity, and the Open Data Science Conference. Coming up this fall is the combined events of Graphorum and the Data Architecture Summit. The agendas have been announced and super early bird registration for up to $300 off is available until July 26th, with early bird pricing for up to $200 off through August 30th. Use the code BNLLC to get an additional 10% off any pass when you register. Go to pythonpodcast.com/conferences to learn more and take advantage of our partner discounts when you register.
  • Visit the site to subscribe to the show, sign up for the newsletter, and read the show notes. And if you have any questions, comments, or suggestions I would love to hear them. You can reach me on Twitter at @Podcast__init__ or email [email protected])
  • To help other people find the show please leave a review on iTunes and tell your friends and co-workers
  • Join the community in the new Zulip chat workspace at pythonpodcast.com/chat
  • Your host as usual is Tobias Macey and today I’m interviewing Harry Percival about domain driven design and enterprise application architecture in Python

Interview

  • Introductions
  • How did you get introduced to Python?
  • Can you start by explaining what "application architecture" is and how it compares to the types of application designs that Python developers and teams typically rely on? how does it contrast with "enterprise architecture"?
    • What are the influences that tend to lead engineers into sub-optimal architectures and how can they guard against them?
  • One of the core concepts in this problem space is that of "domain driven design". Can you unpack that term and explain the benefits that it provides to software architecture?
  • What are some of the other concepts that are common among application architecture patterns?
  • What are some of the common points of confusion among engineers who are first working with DDD?
  • Is there any particular size or scope of project and organization that merits the approach of domain driven design or is it applicable even at small scales of complexity and team size?
  • Now that we’ve convinced everyone that they should be using DDD can you talk through the steps involved in identifying and encapsulating the various implementation details that they will need to work through?
    • How does that process change when dealing with an existing application as opposed to a "greenfield" project?
  • How do Python language constructs and libraries impact the approach to implementation of application architecture patterns as compared to more traditional "enterprise" languages such as Java and C#?
  • What are some of the architectural anti-patterns to watch out for when implementing DDD?
  • On any given team, who is responsible for identifying and ensuring adherence to proper architectural principles?
  • Are there any publicly visible projects that implement DDD which listeners can look at and learn from?
  • To help Python developers in their efforts to learn and implement DDD and other aspects of enterprise architecture you have been working on a book. Can you talk about your motivation for that undertaking, what listeners can expect to learn when the read it, and any challenges that you have encountered in the process?
  • What are some trends in terms of system design and architecture, or technology influences, that you are keeping an eye on?

Keep In Touch

Picks

Links

The intro and outro music is from Requiem for a Fish The Freak Fandango Orchestra / CC BY-SA

Building A Business On Serverless Technology - Episode 214

Summary

Serverless computing is a recent category of cloud service that provides new options for how we build and deploy applications. In this episode Raghu Murthy, founder of DataCoral, explains how he has built his entire business on these platforms. He explains how he approaches system architecture in a serverless world, the challenges that it introduces for local development and continuous integration, and how the landscape has grown and matured in recent years. If you are wondering how to incorporate serverless platforms in your projects then this is definitely worth your time to listen to.

Announcements

  • Hello and welcome to Podcast.__init__, the podcast about Python and the people who make it great.
  • When you’re ready to launch your next app or want to try a project you hear about on the show, you’ll need somewhere to deploy it, so take a look at our friends over at Linode. With 200 Gbit/s private networking, scalable shared block storage, node balancers, and a 40 Gbit/s public network, all controlled by a brand new API you’ve got everything you need to scale up. And for your tasks that need fast computation, such as training machine learning models, they just launched dedicated CPU instances. Go to pythonpodcast.com/linode to get a $20 credit and launch a new server in under a minute. And don’t forget to thank them for their continued support of this show!
  • And to keep track of how your team is progressing on building new features and squashing bugs, you need a project management system designed by software engineers, for software engineers. Clubhouse lets you craft a workflow that fits your style, including per-team tasks, cross-project epics, a large suite of pre-built integrations, and a simple API for crafting your own. With such an intuitive tool it’s easy to make sure that everyone in the business is on the same page. Podcast.init listeners get 2 months free on any plan by going to pythonpodcast.com/clubhouse today and signing up for a trial.
  • Bots and automation are taking over whole categories of online interaction. Discover.bot is an online community designed to serve as a platform-agnostic digital space for bot developers and enthusiasts of all skill levels to learn from one another, share their stories, and move the conversation forward together. They regularly publish guides and resources to help you learn about topics such as bot development, using them for business, and the latest in chatbot news. For newcomers to the space they have the Beginners Guide To Bots that will teach you the basics of how bots work, what they can do, and where they are developed and published. To help you choose the right framework and avoid the confusion about which NLU features and platform APIs you will need they have compiled a list of the major options and how they compare. Go to pythonpodcast.com/discoverbot today to get started and thank them for their support of the show.
  • You listen to this show to learn and stay up to date with the ways that Python is being used, including the latest in machine learning and data analysis. For even more opportunities to meet, listen, and learn from your peers you don’t want to miss out on this year’s conference season. We have partnered with organizations such as O’Reilly Media, Dataversity, and the Open Data Science Conference. Coming up this fall is the combined events of Graphorum and the Data Architecture Summit. The agendas have been announced and super early bird registration for up to $300 off is available until July 26th, with early bird pricing for up to $200 off through August 30th. Use the code BNLLC to get an additional 10% off any pass when you register. Go to pythonpodcast.com/conferences to learn more and take advantage of our partner discounts when you register.
  • The Python Software Foundation is the lifeblood of the community, supporting all of us who want to run workshops and conferences, run development sprints or meetups, and ensuring that PyCon is a success every year. They have extended the deadline for their 2019 fundraiser until June 30th and they need help to make sure they reach their goal. Go to pythonpodcast.com/psf2019 today to make a donation. If you’re listening to this after June 30th of 2019 then consider making a donation anyway!
  • Visit the site to subscribe to the show, sign up for the newsletter, and read the show notes. And if you have any questions, comments, or suggestions I would love to hear them. You can reach me on Twitter at @Podcast__init__ or email [email protected])
  • To help other people find the show please leave a review on iTunes and tell your friends and co-workers
  • Join the community in the new Zulip chat workspace at pythonpodcast.com/chat
  • Your host as usual is Tobias Macey and today I’m interviewing Raghu Murthy from DataCoral about his experience building and deploying a personalized SaaS platform on top of serverless technologies

Interview

  • Introductions
  • How did you get introduced to Python?
  • Can you start by giving a brief overview of DataCoral?
  • Before we get too deep can you share your definition of what types of technologies fall under the umbrella of "serverless"?
  • How are you using serverless technologies at DataCoral?
    • How has your usage evolved as your business and the underlying technologies have evolved?
  • How do serverless technologies impact your approach to application architecture?
  • What are some of the main benefits for someone to target services such as Lambda?
    • What is your litmus test for determining whether a given project would be a good fit for a Function as a Service platform?
  • What are the most challenging aspects of running code on Lambda?
    • What are some of the major design differences between running on Lambda vs the more familiar server-oriented paradigms?
    • What are some of the other services that are most commonly used alongside Function as as Service (e.g. Lambda) to build full featured applications?
  • With serverless function platforms there is the cold start problem, can you explain what that means and some application design patterns that can help mitigate it?
  • When building on cloud-based technologies, especially proprietary ones, local development can be a challenge. How are you handling that issue at DataCoral?
  • In addition to development this new deployment paradigm upends some of the traditional approaches to CI/CD. How are you approaching testing and deployment of your services?
    • How do you identify and maintain dependency graphs between your various microservices?
  • In addition to deployment, it is also necessary to track performance characteristics and error events across service boundaries. How are you managing observability and alerting in your product?
  • What are you most excited for in the serverless space that listeners should know about?

Keep In Touch

Picks

Links

The intro and outro music is from Requiem for a Fish The Freak Fandango Orchestra / CC BY-SA

Hacking The Government With The USDS - Episode 210

Summary

The U.S. government has a vast quantity of software projects across the various agencies, and many of them would benefit from a modern approach to development and deployment. The U.S. Digital Services Agency has been tasked with making that happen. In this episode the current director of engineering for the USDS, David Holmes, explains how the agency operates, how they are using Python in their efforts to provide the greatest good to the largest number of people, and why you might want to get involved. Even if you don’t live in the U.S.A. this conversation is worth listening to so you can see an interesting model of how to improve government services for everyone.

Announcements

  • Hello and welcome to Podcast.__init__, the podcast about Python and the people who make it great.
  • When you’re ready to launch your next app or want to try a project you hear about on the show, you’ll need somewhere to deploy it, so take a look at our friends over at Linode. With 200 Gbit/s private networking, scalable shared block storage, node balancers, and a 40 Gbit/s public network, all controlled by a brand new API you’ve got everything you need to scale up. And for your tasks that need fast computation, such as training machine learning models, they just launched dedicated CPU instances. Go to pythonpodcast.com/linode to get a $20 credit and launch a new server in under a minute. And don’t forget to thank them for their continued support of this show!
  • Bots and automation are taking over whole categories of online interaction. Discover.bot is an online community designed to serve as a platform-agnostic digital space for bot developers and enthusiasts of all skill levels to learn from one another, share their stories, and move the conversation forward together. They regularly publish guides and resources to help you learn about topics such as bot development, using them for business, and the latest in chatbot news. For newcomers to the space they have the Beginners Guide To Bots that will teach you the basics of how bots work, what they can do, and where they are developed and published. To help you choose the right framework and avoid the confusion about which NLU features and platform APIs you will need they have compiled a list of the major options and how they compare. Go to pythonpodcast.com/discoverbot today to get started and thank them for their support of the show.
  • You listen to this show to learn and stay up to date with the ways that Python is being used, including the latest in machine learning and data analysis. For even more opportunities to meet, listen, and learn from your peers you don’t want to miss out on this year’s conference season. We have partnered with organizations such as O’Reilly Media, Dataversity, and the Open Data Science Conference. Go to pythonpodcast.com/conferences to learn more and take advantage of our partner discounts when you register.
  • Visit the site to subscribe to the show, sign up for the newsletter, and read the show notes. And if you have any questions, comments, or suggestions I would love to hear them. You can reach me on Twitter at @Podcast__init__ or email [email protected])
  • To help other people find the show please leave a review on iTunes and tell your friends and co-workers
  • Join the community in the new Zulip chat workspace at pythonpodcast.com/chat
  • Your host as usual is Tobias Macey and today I’m interviewing David Holmes about his work at the US Digital Services organization

Interview

  • Introductions
  • How did you get introduced to Python?
  • Can you start by explaining what the USDS is and how you got involved with it?
  • The terminology that is used around "Tours of Service" is interesting. Can you explain what that entails?
    • relocation
    • what if you have a house and career?
  • Can you explain the model of how the USDS works?
    • What is involved in staffing a new project?
    • What is your typical toolkit, and how does that vary with the specific departments that you are working with?
  • What are some of the most interesting projects that you and the team at USDS have worked on?
  • What are some of the most challenging projects that you have been involved with?
  • What are some projects that you hope to be asked to work on?

Keep In Touch

Picks

Links

The intro and outro music is from Requiem for a Fish The Freak Fandango Orchestra / CC BY-SA

How To Include Redis In Your Application Architecture - Episode 201

Summary

The Redis database recently celebrated its 10th birthday. In that time it has earned a well-earned reputation for speed, reliability, and ease of use. Python developers are fortunate to have a well-built client in the form of redis-py to leverage it in their projects. In this episode Andy McCurdy and Dr. Christoph Zimmerman explain the ways that Redis can be used in your application architecture, how the Python client is built and maintained, and how to use it in your projects.

Announcements

  • Hello and welcome to Podcast.__init__, the podcast about Python and the people who make it great.
  • When you’re ready to launch your next app or want to try a project you hear about on the show, you’ll need somewhere to deploy it, so take a look at our friends over at Linode. With 200 Gbit/s private networking, scalable shared block storage, node balancers, and a 40 Gbit/s public network, all controlled by a brand new API you’ve got everything you need to scale up. Go to pythonpodcast.com/linode to get a $20 credit and launch a new server in under a minute. And don’t forget to thank them for their continued support of this show!
  • And to keep track of how your team is progressing on building new features and squashing bugs, you need a project management system designed by software engineers, for software engineers. Clubhouse lets you craft a workflow that fits your style, including per-team tasks, cross-project epics, a large suite of pre-built integrations, and a simple API for crafting your own. Podcast.__init__ listeners get 2 months free on any plan by going to pythonpodcast.com/clubhouse today and signing up for a trial.
  • Visit the site to subscribe to the show, sign up for the newsletter, and read the show notes. And if you have any questions, comments, or suggestions I would love to hear them. You can reach me on Twitter at @Podcast__init__ or email [email protected])
  • To help other people find the show please leave a review on iTunes and tell your friends and co-workers
  • Join the community in the new Zulip chat workspace at pythonpodcast.com/chat
  • You listen to this show to learn and stay up to date with the ways that Python is being used, including the latest in machine learning and data analysis. For even more opportunities to meet, listen, and learn from your peers you don’t want to miss out on this year’s conference season. We have partnered with O’Reilly Media for the Strata conference in San Francisco on March 25th and the Artificial Intelligence conference in NYC on April 15th. Here in Boston, starting on May 17th, you still have time to grab a ticket to the Enterprise Data World, and from April 30th to May 3rd is the Open Data Science Conference. Go to pythonpodcast.com/conferences to learn more and take advantage of our partner discounts when you register.
  • Your host as usual is Tobias Macey and today I’m interviewing Andy McCurdy and Christoph Zimmerman about the Redis database, and some of the various ways that it is used by Python developers

Interview

  • Introductions
  • How did you get introduced to Python?
  • Can you start by explaining what Redis is and how you got involved in the project?
  • How does the redis-py project relate to the Redis database and what motivated you to create the Python client?
  • What are some of the main use cases that Redis enables?
  • Can you describe how Redis-py is implemented and some of the primitives that it provides for building applications on top of?
    • How do the release cycles of redis-py and the Redis database relate to each other?
    • How closely does redis-py match the features of the Redis database?
    • What are some of the convenience methods or features that you have added to make the client more Pythonic?
  • Redis is often used as a key/value cache for web applications, in some cases replacing Memcached. What are the characteristics of Redis that lend themselves well to this purpose?
    • What are some edge cases or gotchas that users should be aware of?
  • What are some of the common points of confusion or difficulties when storing and retrieving values in Redis?
  • What have been some of the most challenging aspects of building and maintaining the Redis Python client?
  • What are some of the anti-patterns that you have seen around how developers build on top of Redis?
  • What are some of the most interesting or unexpected ways that you have seen Redis used?
  • What are some of the least used or most misunderstood features of Redis that you think developers should know about?
  • What are some of the recent and near-future improvements or features in Redis that you are most excited by?

Keep In Touch

Picks

Links

The intro and outro music is from Requiem for a Fish The Freak Fandango Orchestra / CC BY-SA

Event Sourcing with John Bywater - Episode 131

Summary

The way that your application handles data and the way that it is represented in your database don’t always match, leading to a lot of brittle abstractions to reconcile the two. In order to reduce that friction, instead of overwriting the state of your application on every change you can log all of the events that take place and then render the current state from that sequence of events. John Bywater joins me this week to discuss his work on the Event Sourcing library, why you might want to use it in your applications, and how it can change the way that you think about your data.

Preface

  • Hello and welcome to Podcast.__init__, the podcast about Python and the people who make it great.
  • I would like to thank everyone who supports the show on Patreon. Your contributions help to make the show sustainable.
  • When you’re ready to launch your next project you’ll need somewhere to deploy it. Check out Linode at podastinit.com/linode and get a $20 credit to try out their fast and reliable Linux virtual servers for running your awesome app. And now you can deliver your work to your users even faster with the newly upgraded 200 GBit network in all of their datacenters.
  • If you’re tired of cobbling together your deployment pipeline then it’s time to try out GoCD, the open source continuous delivery platform built by the people at ThoughtWorks who wrote the book about it. With GoCD you get complete visibility into the life-cycle of your software from one location. To download it now go to podcatinit.com/gocd. Professional support and enterprise plugins are available for added piece of mind.
  • Visit the site to subscribe to the show, sign up for the newsletter, and read the show notes. And if you have any questions, comments, or suggestions I would love to hear them. You can reach me on Twitter at @Podcast__init__ or email [email protected]
  • To help other people find the show please leave a review on iTunes, or Google Play Music, tell your friends and co-workers, and share it on social media.
  • Your host as usual is Tobias Macey and today I’m interviewing John Bywater about event sourcing, an architectural approach to make your data layer easier to scale and maintain.

Interview

  • Introductions
  • How did you get introduced to Python?
  • Can you start by describing the concept of event sourcing and the benefits that it provides?
  • What is the event sourcing library and what was your reason for starting it?
  • What are some of the reasons that someone might not want to implement an event sourcing approach in their persistence layer?
  • Given that you are storing a record for each event that occurs on a domain object, how does that affect the amount of storage necessary to support an event sourced application?
  • What is the impact on performance and latency from an end user perspective when the application is using event sourcing to render the current state of the system?
  • What does the internal architecture and design of your library look like and how has that evolved over time?
  • In the case where events are delivered out of order, how can you ensure that the present view of an object is reflected accurately?
  • For someone who wants to incorporate an event sourcing design into an existing application, how would they do that?
  • How do you manage schema changes in your domain model when you need to reconstruct present state from the beginning of an objects event sequence?
  • What are some of the most interesting uses of event sourcing that you have seen?
  • What are some of the features or improvements that you have planned for the future of you event sourcing library?

Keep In Touch

Picks

Links

The intro and outro music is from Requiem for a Fish The Freak Fandango Orchestra / CC BY-SA

Automat State Machines with Glyph Lefkowitz - Episode 116

Summary

The venerable ‘if’ statement is a cornerstone of program flow and busines logic, but sometimes it can grow unwieldy and lead to unmaintainable software. One alternative that can result in cleaner and easier to understand code is a state machine. This week Glyph explains how Automat was created and how it has been used to upgrade portions of the Twisted project.

Preface

  • Hello and welcome to Podcast.__init__, the podcast about Python and the people who make it great.
  • I would like to thank everyone who supports us on Patreon. Your contributions help to make the show sustainable.
  • When you’re ready to launch your next project you’ll need somewhere to deploy it. Check out Linode at www.podastinit.com/linode and get a $20 credit to try out their fast and reliable Linux virtual servers for running your awesome app.
  • Visit the site to subscribe to the show, sign up for the newsletter, read the show notes, and get in touch.
  • To help other people find the show please leave a review on iTunes, or Google Play Music, tell your friends and co-workers, and share it on social media.
  • Your host as usual is Tobias Macey and today I’m interviewing Glyph about Automat, a library that provides self-service finite-state machines for the programmer on the go.

Interview

  • Introductions
  • How did you get introduced to Python?
  • What is a state machine and when might you want to use one?
  • There are a number of libraries available on PyPI that facilitate the creation of state machines. Why did you feel the need to build a new option and how does it differ from what was already available?
  • Why do you think developers fall into the trap of complicated conditional structures rather than reaching for a state machine?
  • For someone who wants to integrate Automat into their project how would they go about that and what are some of the gotchas that they should keep in mind?
  • What do the internals of Automat look like and how did you approach the overall design of the project?
  • What are some of the more difficult aspects of designing and implementing state machines properly?
  • What are some of the technical hurdles that you have been faced with in the process of building a library for implementing state machines?
  • What do you have planned for the future of Automat?
  • What are some of the most interesting use cases of Automat that you have seen?

Keep In Touch

Picks

Links

The intro and outro music is from Requiem for a Fish The Freak Fandango Orchestra / CC BY-SA