mirror of
https://github.com/evennia/evennia.git
synced 2026-03-16 21:06:30 +01:00
Settings and server configs updated. The caches between server and website threads are still not properly addressed - a change in the admin interface does not immediately translate to a change in-game.
This commit is contained in:
parent
c083fe6266
commit
20e093aa26
4 changed files with 6 additions and 7 deletions
|
|
@ -403,6 +403,7 @@ def error_check_python_modules():
|
|||
deprstring = "settings.%s should be renamed to %s. If defaults are used, their path/classname must be updated (see src/settings_default.py)."
|
||||
if hasattr(settings, "CMDSET_DEFAULT"): raise DeprecationWarning(deprstring % ("CMDSET_DEFAULT", "CMDSET_CHARACTER"))
|
||||
if hasattr(settings, "CMDSET_OOC"): raise DeprecationWarning(deprstring % ("CMDSET_OOC", "CMDSET_PLAYER"))
|
||||
if settings.WEBSERVER_ENABLED and not isinstance(settings.WEBSERVER_PORTS[0], tuple): raise DeprecationWarning("settings.WEBSERVER_PORTS must be on the form [(proxyport, serverport), ...]")
|
||||
|
||||
from src.commands import cmdsethandler
|
||||
if not cmdsethandler.import_cmdset(settings.CMDSET_UNLOGGEDIN, None): print "Warning: CMDSET_UNLOGGED failed to load!"
|
||||
|
|
|
|||
|
|
@ -157,10 +157,7 @@ if AMP_ENABLED:
|
|||
|
||||
from src.server import amp
|
||||
|
||||
ifacestr = ""
|
||||
if AMP_HOST != '127.0.0.1':
|
||||
ifacestr = "-%s" % AMP_HOST
|
||||
print ' amp (to Server)%s: %s' % (ifacestr, AMP_PORT)
|
||||
print ' amp (to Server): %s' % AMP_PORT
|
||||
|
||||
factory = amp.AmpClientFactory(PORTAL)
|
||||
amp_client = internet.TCPClient(AMP_HOST, AMP_PORT, factory)
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ ENCODINGS = ["utf-8", "latin-1", "ISO-8859-1"]
|
|||
# communicate with it. This is an internal functionality of Evennia, usually
|
||||
# operating between two processes on the same machine. You usually don't need to
|
||||
# change this unless you cannot use the default AMP port/host for whatever reason.
|
||||
AMP_HOST = '127.0.0.1'
|
||||
AMP_HOST = 'localhost'
|
||||
AMP_PORT = 5000
|
||||
AMP_INTERFACE = '127.0.0.1'
|
||||
# Caching speeds up all forms of database access, often considerably. There
|
||||
|
|
|
|||
|
|
@ -180,10 +180,11 @@ class SharedMemoryModel(Model):
|
|||
super(SharedMemoryModel, cls).save(*args, **kwargs)
|
||||
else:
|
||||
# in another thread; make sure to save in reactor thread
|
||||
print "saving in another thread!"
|
||||
def _save_callback(cls, *args, **kwargs):
|
||||
super(SharedMemoryModel, cls).save(*args, **kwargs)
|
||||
blockingCallFromThread(reactor, _save_callback, cls, *args, **kwargs)
|
||||
#callFromThread(_save_callback, cls, *args, **kwargs)
|
||||
#blockingCallFromThread(reactor, _save_callback, cls, *args, **kwargs)
|
||||
callFromThread(_save_callback, cls, *args, **kwargs)
|
||||
|
||||
# Use a signal so we make sure to catch cascades.
|
||||
def flush_cache(**kwargs):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue