aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/docs/love.txt
diff options
context:
space:
mode:
Diffstat (limited to 'docs/love.txt')
-rw-r--r--docs/love.txt67
1 files changed, 67 insertions, 0 deletions
diff --git a/docs/love.txt b/docs/love.txt
new file mode 100644
index 0000000..c704aba
--- /dev/null
+++ b/docs/love.txt
@@ -0,0 +1,67 @@
1Love makes the world go around. Though in this case, it's the name of
2the world server, the module that directly controls what happens to the
3content of the virtual world.
4
5The love world server that deals with changing the world. It manages
6the on disk representation of the world, and lets others screw with it
7via nails pumps. Love also sends nails events on changes.
8
9World server vs local world.
10----------------------------
11
12Extantz defaults to running a local world at start up. Lspace serves
13the content for a networked world. They may be the same world if the
14local world is also networked. Nails pumps commands to and from the
15world.
16
17Lspace just serves the results as a web server. The love world server
18changes on disk content, Lspace checks on disk modified time stamps to
19deal with "do you have a newer version" HTTP requests. Standard web
20server stuff really, though a mod_nails might be useful to catch events
21in order to invalidate any internal web caches.
22
23For networked worlds, Extantz fetches new content from Lspace, and hooks
24up to the nails pump of the love server for changes. For local worlds,
25extantz would basically BE the world server? No, that duplicates
26things, it can just run a local love server, then connect to it like
27every one else. No need to connect to a local Lspace server, just deal
28with the file system direct.
29
30The local love server would be configured to listen on 127.0.0.1, and/or
31the outside IP address. Extantz checks to see if there's one running on
32127.0.0.1 first before starting one if needed.
33
34Separate vs combined.
35---------------------
36
37There's two ways of doing this. The world server could be part of
38Lspace, or they could be separate modules. What we really have is a web
39server, backing store, and command pump. The command pump is nails, and
40should be a library that is shared, since both ends of the protocol
41would be needed by most modules.
42
43Combined might be useful to conserve resources. They both need to deal
44with the contents of the world. Lspace just serves it to the outside
45world via HTTP, but needs to track changes. Love makes those changes,
46and also sends changes via nails to every one. Keeping the current
47working set in memory only once saves a lot of memory.
48
49The down sides of combined is that one might bog down the other, and it
50gets harder to use standard web servers.
51
52Separated is good coz Lspace might just be any ordinary web server.
53They already have mechanisms in place to serve dynamic data, and even
54deal with changes to the files.
55
56The down side of separated is that changes might be slower propogating
57to the web server, and there might be two copies of any given set of
58assets in memory at once.
59
60A third option is to be separated, but any given web server could have a
61mod_love type module written for it. This could share memory with the
62love server process. So tighter integration is an option, but they can
63work apart. Changes happen in this shared memory, driven by the command
64pump in the love server. Lspace just needs read access, and just
65serves the current state of the world. Love server persists to disk
66when it's ready to, though the shared memory can just be memory mapped
67files.