Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 40 lines (34 sloc) 1.284 kB
3349d37 Notes on things I think should become services
Simon Willison authored
1 What should be a service?
2 =========================
3
4 As a general rule, services should be things that get configured in some way.
5 Not everything in Django should be converted in to a service. If a component
6 doesn't require any per-site configuration (e.g. forms, syndication feeds) it
7 should probably be left as a regular library.
8
9 Stuff in Django that should be a service
10 ----------------------------------------
11 * Caching
12 * Templating
13 * Sending e-mail
14 * "Current user" authentication
15 * Sessions
16 * Database connection - django.db.connection
17 * Higher level ORM
18 * File storage
19 * Sites - or at least the concept of the "current site"
20
21 Stuff that isn't yet in Django but should be a service
22 ------------------------------------------------------
23 * HTTP client
24 * Logging
25 * Message queue
26 * Cryptography (in particular signing things)
27
28 Stuff that shouldn't be a service
29 ---------------------------------
30 * The admin: it's just an application
31 * Signals: they are part of core Django itself
32 * Forms: they are a library, they don't need configuring at all
33 * Testing: core Django, lives above services as has tools for mocking them
34 * Sitemaps / syndication: again, these are libraries
35
36 Stuff I'm not sure about
37 ------------------------
38 * i18n / translation
39 * Content Types / generic relations
Something went wrong with that request. Please try again.