Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1085941
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T22:45:06+00:00 2026-05-16T22:45:06+00:00

Other posters have previously said in this forum that when your Django app starts

  • 0

Other posters have previously said in this forum that when your Django app starts getting big and unmanageable, you should split it up into several apps. I’m at that point now. What are the best practices for allowing communication between these apps?

One of my apps (let’s call it Processor) processes very large data sets. Once an hour it produces a small amount of new data for the other app. This other app (let’s call it Presenter) displays the data to users.

How should Processor hand new data to Presenter? Should it simply import parts of Presenter’s model, so it can create and save records in Presenter’s database? That seems like tight coupling to me. Or should it pass the data by calling a function in Presenter? Or put the data in some sort of data store that both Processor and Presenter know about?

How do you all usually solve this problem?

/Martin

  • 1 1 Answer
  • 3 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T22:45:07+00:00Added an answer on May 16, 2026 at 10:45 pm

    I would definitely go for the importing Processor’s models in the Presenter app. That’s how, for instance, you can add extra user info: you have a UserPreferences model with a ForeignKeyField to django.contrib.auth.models.User. Your might have less of a bad feeling doing that that between your two apps because django.contrib is the “standard library”, but nevertheless, it is direct coupling.

    If your applications are coupled, then your code should be coupled to reflect this. This follows the idea that explicit is better than implicit, right?

    If, however, your’re designing something a tad more generic (i.e. you’re going to use multiple Presenter app instances for Processors of different kinds), you can store the specific models as a setting:

    import processor_x.models
    PRESENTER_PROCESSOR_MODELS = presenter_x.models
    

    Then, in your Presenter models:

    from django.conf import settings
    class Presenter:
        processor = models.ForeignKey(settings.PRESENTER_PROCESSOR_MODELS)
    

    Caveat: I have never attempted this, but I don’t recall a limitation on settings to be only strings, tuples or lists!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

So I have this function that gets data from database and echoes it. The
I run across this problem frequently suppose I have a text file that I
I have a fabfile.py for my django project that I'm using for auto-deploy. I
Other questions dealing with use of match_parent pre 2.2 have answers stating one should
other than not encrypting, i have no choice but to have the RSA private
Other than that I don't know if I can reproduce it now that it's
Other than the fact that PNG is a more common image format, is there
My 'about' page uses a div content switch method (by Bill Posters ) that
first time poster. Please be gentle. This topic may be similar to several other
I have a page that has a couple of jqGrids on it, along with

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.