Commit 508ba138 authored by Jim Fulton's avatar Jim Fulton

Extension methods aren't supported sny more

parent 3c525909
...@@ -76,10 +76,6 @@ registered_methods = set(( 'get_info', 'lastTransaction', ...@@ -76,10 +76,6 @@ registered_methods = set(( 'get_info', 'lastTransaction',
class ZEOStorage: class ZEOStorage:
"""Proxy to underlying storage for a single remote client.""" """Proxy to underlying storage for a single remote client."""
# A list of extension methods. A subclass with extra methods
# should override.
extensions = []
connected = connection = stats = storage = storage_id = transaction = None connected = connection = stats = storage = storage_id = transaction = None
blob_tempfile = None blob_tempfile = None
log_label = 'unconnected' log_label = 'unconnected'
...@@ -91,10 +87,6 @@ class ZEOStorage: ...@@ -91,10 +87,6 @@ class ZEOStorage:
self.client_conflict_resolution = server.client_conflict_resolution self.client_conflict_resolution = server.client_conflict_resolution
# timeout and stats will be initialized in register() # timeout and stats will be initialized in register()
self.read_only = read_only self.read_only = read_only
# The authentication protocol may define extra methods.
self._extensions = {}
for func in self.extensions:
self._extensions[func.__name__] = None
self._iterators = {} self._iterators = {}
self._iterator_ids = itertools.count() self._iterator_ids = itertools.count()
# Stores the last item that was handed out for a # Stores the last item that was handed out for a
...@@ -154,17 +146,6 @@ class ZEOStorage: ...@@ -154,17 +146,6 @@ class ZEOStorage:
record_iternext = getattr(storage, 'record_iternext', None) record_iternext = getattr(storage, 'record_iternext', None)
if record_iternext is not None: if record_iternext is not None:
self.record_iternext = record_iternext self.record_iternext = record_iternext
try:
fn = storage.getExtensionMethods
except AttributeError:
pass # no extension methods
else:
d = fn()
self._extensions.update(d)
for name in d:
assert not hasattr(self, name)
setattr(self, name, getattr(storage, name))
self.lastTransaction = storage.lastTransaction self.lastTransaction = storage.lastTransaction
try: try:
...@@ -250,7 +231,6 @@ class ZEOStorage: ...@@ -250,7 +231,6 @@ class ZEOStorage:
'size': storage.getSize(), 'size': storage.getSize(),
'name': storage.getName(), 'name': storage.getName(),
'supportsUndo': supportsUndo, 'supportsUndo': supportsUndo,
'extensionMethods': self.getExtensionMethods(),
'supports_record_iternext': hasattr(self, 'record_iternext'), 'supports_record_iternext': hasattr(self, 'record_iternext'),
'interfaces': tuple(interfaces), 'interfaces': tuple(interfaces),
} }
...@@ -260,9 +240,6 @@ class ZEOStorage: ...@@ -260,9 +240,6 @@ class ZEOStorage:
'size': self.storage.getSize(), 'size': self.storage.getSize(),
} }
def getExtensionMethods(self):
return self._extensions
def loadEx(self, oid): def loadEx(self, oid):
self.stats.loads += 1 self.stats.loads += 1
return self.storage.load(oid, '') return self.storage.load(oid, '')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment