1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
3
<!-- $Id: 12-changes-archive.html,v 2.6 2004/05/08 21:27:22 irmen Exp $ -->
5
<TITLE>PYRO - Change Log (archive)</TITLE>
7
<BODY background="backdrop.jpg">
8
<table border="0" width="100%">
10
<td align="left"><a href="11-services.html"><previous</a> | <a href="PyroManual.html">contents</a></td>
11
<td align="right">Pyro Manual</td>
16
<H2><u>Pyro Change Log (archive)</u></H2>
17
<p>The recent Pyro versions can be found in the regular <a href="12-changes.html">change log</a>.
18
<p>Pyro 0.1 has been lost in the dust. It wasn't suited for publication anyway, I guess :-)
20
First working release. Only static proxies and very little configurability.
23
<LI>MAJOR: added Dynamic Proxies! Clients don't need to have a precompiled proxy file available any more! Check out <code>core.getProxyForURI/DynamicProxy</code>.
24
<LI>MAJOR: reworked the configuration possibilities. Check out <code>__init__.py</code>.
25
<LI>Moved config items to a class in <code>__init__.py</code>. They are accessed using '<code>Pyro.config.<item></code>'.
26
<LI>Made the port and broadcast port configurable independently. The command lines now accept options to specify either or both ports.
27
<LI>naming: added delay in broadcast loop (wait a little for replies to arrive), Naming Service now returns PyroErrors instead of regular exceptions.
28
<LI>core: Cleaned up the Pyro exception passing, added <code>DynamicProxy</code> and <code>getProxyForURI</code>
29
<LI>pyroc: fixed bug in method output code (could forget a comma)
30
<LI>nsc: fully rewrote the parsing code to use the <code>util.ArgVParser</code>
31
<LI>scripts: the Window <code>.bat</code> files now use <code>%$</code>
32
<LI>added <code>util.py</code>, which contains a basic <code>sys.argv</code> parser like <code>getopt()</code>.
36
<LI>naming: changed broadcast server to reflect changes in Python 1.5.2's <code>SocketServer</code> module. Pyro now requires this new <code>SocketServer</code> module (which works with previous Python versions, too, so you could only replace the <code>SocketServer</code> module and keep the rest of your Python installation intact).
37
<LI>naming: fixed bugs when reporting exceptions ('entry already exists' and 'not found').
38
<LI>util: added <code>getUUID</code> function, and a script <code>genuuid</code>.
39
<LI>core: Pyro objects are now identified by a full UUID, instead of a simple Python <code>id()</code>. This should prevent nasty object ID problems, especially later when persistent naming and object activation will be implemented.
43
<LI>MAJOR: the Pyro Naming Service now is a Pyro object itself, too. It can be accessed through its Pyro interface.
44
<LI>More specific exceptions (<code>ProtocolError, URIError, DaemonError, NamingError</code>...)
45
<LI>It is now possible to connect objects without the presence of a Naming Service.
46
<LI>core: the Daemon can now handle requests for others too, by a callback mechanism. Also removed up the server-side exception trace info when the exception is generated on purpose, and added a nice message when the daemon cannot be started.
47
<LI>naming: many changes to make the Name Server a Pyro object itself. Finding the NS is now done through the <code>NameServerLocator</code>, which returns a regular Pyro proxy for the NS. No <code>NameServerClient</code> is needed anymore.
48
<LI>util: tweaked the way the timestamp in URIs is generated.
49
<LI>config: more configurable items.
50
<LI>scripts: <code>Pyroc.bat</code> now uses <code>%$</code>, too (oops!)
54
<LI>Added <code>xnsc</code>, a naming service control tool with a GUI (uses <code>Tkinter</code>).
55
<LI>The naming service can be launched in 'persistent mode': it will keep the naming directory in a persistent database on disk. EXPERIMENTAL!
56
<LI>core: added 2 configuration variables in <code>Pyro.config</code>: <code>PYRO_PATH</code> and <code>PYRO_STORAGE</code>.
57
<LI>core: added method to <code>ObjBase</code> to set a fixed (persistent) object UUID.
58
<LI>core: slight change in the init code of <code>PyroURI</code>, it can now be created directly from a URI string, instead of using <code>initFromString</code>.
59
<LI>core: the <code>Daemon</code> now has preliminary support for persistent objects: <code>connectPersistent</code> and <code>disconnectPersistent</code> methods were added. LIKELY TO CHANGE!
60
<LI>naming: added a persistent name server class <code>PersistentNameServer</code>. Also added some code to deal with this when using the '<code>ns</code>' command line tool: a new option '<code>-db</code>' has been added to specify persistent mode.
61
<LI>naming: the broadcast server now binds on '' instead of the hostname. This appears to be more compatible (on some systems it was impossible to connect to the broadcast server).
62
<LI>naming: implemented graceful shutdown command. The server also uses a timeout loop for the requests (because otherwise ^C wouldn't break gracefully on WinNT - Duh).
63
<LI>scripts: <code>nsc</code> (and <code>xnsc</code>) now print a sorted list (and have the shutdown command).
64
<LI>scripts: the <code>.bat</code> files now won't echo the python command anymore.
65
<LI>utils: <code>ArgParser</code> changed to use <code>None</code> instead of <code>1</code> when no arguments are given to a certain option.
66
<LI>test: <code>testclient</code> will use dynamic proxy automatically if no static proxy is found. Also, it will try a direct connect if the NS lookup by broadcast fails.
70
<LI>bumped all versions to 0.7
71
<LI>NOTE: because of some changes you will have to generate your proxies again with <code>pyroc</code>!
72
<LI>core: separated the Exception types and the protocol adapters to <code>errors.py</code> and <code>protocol.py</code>.
73
<LI>util: added a <code>Logger</code> object, <code>Log</code>. It is used throughout Pyro to log messages, warnings and errors. You can configure the logfile and the trace level settings with some new configuration options. Ofcourse you can use it for your own logging purposes too.
74
<LI>init: changed the way configuration items are set up. If a corresponding environment variable exists, that value is used. Otherwise the default applies. This works for all configuration options except <code>PYRO_NS_NAME</code> because that is a registered name and should not be changed.
75
<LI>naming: the naming server now writes its URI to a special output file. This can be used to contact the naming server if you can't use the broadcast locator for some reason.
76
<LI>uuids: renamed UUID to GUID (Globally Unique ID). You can never be sure that your ID is Universally Unique, so I changed the name. Also, the <code>genuuid</code> scripts have been renamed to <code>genguid</code>.
77
<LI>changed default pickling mode to binary, to improve performance. A new configuration option lets you choose between ASCII or binary.
78
<LI>pyroc: fixed a problem where the '<code>self</code>' argument of a member function had a different name. Pyroc now uses '<code>S</code>' everywhere.
79
<LI>pyroc: added support for inherited classes. A module within a Python package is not yet supported as input!
80
<LI>pyroc: explicit checks against special Python methods <code>__xxx__</code>. They are not allowed in the proxy code.
81
<LI>MAJOR documentation update.
85
<LI>A few fixes in the source comments.
86
<LI>Added separate user logging facility and fixed small bug in logger code (it was too picky on the arguments).
87
<LI>Moved some protocol dependent code from <code>core.py</code> to <code>protocol.py</code>
88
<LI>New exception model! See documentation! Basically, every exception on the server side will be catched and raised on the client side.
89
<LI>Naming server and the <code>nsc</code> and <code>xnsc</code> tools are stricter with the names and URIs they allow.
90
<LI>GUIDs are now 128 bit (instead of 144) and Pyro can use Windows GUIDs on the Windows platform. This is configurable trough a new configuration item <code>PYRO_USE_WIN32GUID</code>. This is <em>not</em> the default and will work only on the Windows platform, because the Python COM extension is used for this.
91
<LI>New <code>genguid</code> script with '<code>-w</code>' argument to generate a Windows GUID if possible.
92
<LI>Fixed some things to allow for special 'localhost' optimization (the reduced overhead of some network implementations when using 'localhost' instead of the real hostname). The changes are:
94
<LI>Pyro daemon now binds on '' instead of hostname. Previously, URIs with the 'localhost' hostname couldn't be bound.
95
<LI>The <code>PyroURI</code> class has a new <code>optimizeLocalhost</code> method, which -if possible- optimizes the URI for localhost addressing.
97
This also paves the way for more optimizations might be added when Pyro detects a local URI. (for instance, using IPC instead of going trough the network)
98
<LI>Implemented Delegate pattern for remote object implementations. Instead of subclassing your object implementation from <code>Pyro.core.ObjBase</code>, you just create a <code>Pyro.core.ObjBase</code> object and tell it to use another object as a delegate.
99
<LI>New <code>ArgParser</code> in <code>util.py</code>, to support more convenient script arguments. A few scripts have slightly altered syntaxes now, which should be more convenient. The old syntax should still work however.
100
<LI>Documentation updates. Major addition is the new chapter with a practical guide about how to develop Pyro programs.
104
<LI>MAJOR: Reimplemented the PYRO protocol. It now uses a MUD-like system instead of a webserver-like system.
105
The protocol used to create a new socket connection for each method call. This is inefficient and resource hungry.
106
The new implementation uses a single socket for each Pyro object, and all method calls and replies are passed over this connection. The connection remains active until the object is no longer needed.
107
The new implementation no longer has the serious problem that the previous implementation had on most machines: when a lot of method calls were made,
108
the system would crash with some sort of 'resource unavailable' or 'out of memory' error. The new protocol is also faster than the previous one on all systems.
109
<LI>Because of the new protocol, I think Pyro now deserves the version 1 status: bumped all version numbers to 1.0
110
<LI>The Pyro <code>Daemon</code> inherits from the new <code>TCPServer</code> base class (in <code>protocol.py</code>). This server replaces the <code>SocketServer.TCPServer</code>.
111
The new server keeps a list of active connections, while the old one operated like a webserver: it created a new socket connection for each request.
112
<LI>Pyro Daemon has been adapted to the new protocol.
113
<LI><strong>NOTE:</strong> The new PYRO protocol is <em>incompatible</em> with the older versions. Communication is impossible between different Pyro versions. You should upgrade all Pyro installations to the new version.
114
However, user code does <em>not</em> have to be changed. Old code still runs on top of the new implementation (the API has not been changed).
115
<LI>The Windows .bat scripts now use <code>#*</code> instead of <code>#$</code> (which didn't work on the standard Windows95/NT command prompt).
116
<LI><code>xnsc</code> handles communication errors better.
117
<LI>Organized the tests in the <code>test</code> directory and added some readme files. Also added some more tests/examples.
118
<LI>Moved some socket code out of other modules to <code>protocol.py</code>. Now only <code>naming.py</code> and <code>protocol.py</code> have socket code.
119
<LI>Removed the <code>NULLAdapter</code>.
120
<LI>Removed the pickling of NS system commands. They're simple strings now.
121
<LI>Added socket send/receive helper functions in <code>protocol.py</code> for robust data transmission. The new protocol code uses them. Performance is lower but the new code should guarantee correct behaviour even at high network loads with many packet losses and fragmentations.
122
<LI>New exceptions <code>SocketClosedError</code> and <code>ServerFullError</code>.
123
<LI>Removed <code>RemotePyroException</code> (unused).
124
<LI>Small change in the <code>xnsc</code> GUI: better resizing
125
<LI>The new protocol enforces a limit on the number of simultaneous connections to each Pyro daemon. This is for protection of the server machine. There is a new configuration item <code>PYRO_MAXCONNECTIONS</code> that sets this limit. Currently the default is 200.
126
<LI>The <code>unregister</code> method of the naming service now raises a <code>NamingError</code> when the name is not known. I added this because usually this signals a typo in the calling code (it should never unregister an unknown name).
127
<LI>Documentation updates; manual is finished except for the implementation chapter.
131
<LI>MAJOR: Naming Service now has a hierarchical namespace. It has groups, which can contain other groups or names. By default, a dot ('.') in a name is the group separator, so that "group1.group2.name" is a hierarchical name.
132
Notice that this is much like DNS's host/domain name scheme, but <em>in reverse order</em>, rather like a directory structure in a disk file system.
133
The big gain from all this is that you can have different "domains" (namespaces) in your Pyro environment. With a simple change of the default namespace group your system uses a different "domain" and the object names will not interfere with other systems (provided your namespace group is unique).
134
For an application of this, see the new test programs, which now all use the ':test' namespace group. Also, it opens the gates for an even more sophisticated naming service: a distributed federated hierarchical nameservice (wow!! :-)
135
<LI>The default or de facto namespace group is ":Default". This means that Pyro code that does not (yet) use the new naming scheme will wind up registering all its object names in this namespace group. That's nice because this is a simple way to avoid name clashes with legacy Pyro code and new code.
136
<LI>Adapted the NS proxy to enforce the default group on all names that are not absolute from the root. It is now required that all names passed to the NS are absolute (fully expanded), the hand coded NS proxy takes care of this.
137
Note that a proxy obtained for the NS by other means <em>does not have this feature</em> and will likely break your code! Notably, the use of a dynamic proxy for the NS will no longer work correctly. Always use the <em>static proxy</em> from the <code>naming</code> module.
138
<LI>Added configuration item <code>PYRO_NS_GROUPSEP</code>, which is the character that separates groups in names. By default it is a dot ('.'), but if this proves incompatible with existing naming schemes (that use dots in the names), just change it to something else.
139
Notice that this item is only examined <em>once</em>: at startup time. You have to restart the Naming Service if you change this item.
140
<LI>Added configuration item <code>PYRO_NS_DEFAULTGROUP</code>, which is the default group name in which names are located. This simplifies partitioning your name space greatly.
141
Notice that the Name Server proxy code is hand crafted to enforce this name.
142
<LI>Added configuration item <code>PYRO_NS_ROOTCHAR</code>, which is the default escape character at the beginning of names, which indicates the name is absolute from the root.
143
<LI>Changed the config item for the name server name to include a root character. Existing code should not break (if it does, you probably didn't use <code>PYRO_NS_NAME</code>...
144
<LI>Extended the name server object with three new remote methods for hierarchical naming support: <code>createGroup</code>, <code>deleteGroup</code> and <code>list</code>. Furthermore, <code>status</code> has been renamed to <code>flatlist</code>. This suggests better what it does: return a flat dump of the namespace.
145
<LI>Extended <code>nsc</code> and <code>xnsc</code> with the new naming service features: <em>list</em>, <em>creategroup</em> and <em>deletegroup</em> commands. (The old <em>list</em> command was renamed to <em>listall</em>).
146
<LI>Simplified dynamic proxy. It used to create a invocation object with each method call, this is no longer so.
147
<LI>Fixed bug in <code>protocol.py</code> where a <code>KeyError</code> in a method invocation was always treated as if a method call on an unknown object was tried, even when the object was correct (but raised a <code>KeyError</code>)
148
<LI>Naming service will no longer crash when an unexpected exception occurs while it is running. It will log and print the error and resume operations. A ctrl-c (<code>KeyboardInterrupt</code>) will still abort it, however, as will sending a <em>shutdown</em> command.
149
<LI>Small change in the Daemon in <code>core.py</code>. If a ProtocolError is detected (for instance, an invalid header), the connection is dropped and operations are resumed. Pyro used to block or crash when a non-Pyro client connected, such as a plain telnet or a web browser pointed at Pyro's socket.
150
<LI>Test servers and clients are now using common code bases. They're registering their names in a new "<code>:test</code>" group (namespace) too, to help avoid conflicts with your own names. Servers will no longer crash if their name is already registered (they just register again).
151
<LI>Fixed a few small errors in some of the test programs, and created an electronic banking example to be a nice starting point for Pyro applications.
152
<LI>Fixed bug in some default arguments to functions, where config items were used. Now they are parsed at use instead of at module import time.
153
<LI>Added '<code>-k</code>' switch to <code>ns</code> that will start the NS in a mode in which it ignores shutdown requests sent by <code>nsc</code>. This is a crude form of security, to protect the NS for malicious shutdowns.
154
<LI>Documentation updates about the new naming scheme.
155
<LI>New example added that uses the new naming functions.
156
<LI>Configuration files! You can now use a configuration file that contains all required Pyro config options. It's no longer necessary to use a big list of environment variables.
157
<LI>New configuration item <code>PYRO_CONFIG_FILE</code>. Only useful as environment variable, it points to the configuration file Pyro has to use.
162
<LI>Fixed bug in TCPserver code (could skip connections). Please update all Pyro installations because this was a rather nasty bug.
163
<LI><code>Daemon.connect</code> now returns the URI it connects the object as. This is convenient for servers that want to use the URI immediately without having to consult the nameserver.
164
<LI>It's now possible to get/set attributes on Pyro objects with normal Python syntax! (changes to <code>ObjBase</code> and new <code>DynamicProxyWithAttr</code>) <em>You have to update all Pyro installations if you want to use this new feature.</em> If you don't use it, Pyro 1.2 should work together with version 1.1.
165
Notice that there is a performance hit of a few percent when you use <code>DynamicProxyWithAttr</code> instead of the regular <code>DynamicProxy</code> to support the attribute feature.
166
<LI>Server objects can now create new Pyro objects and marshal Proxy objects to the clients! (changes to <code>DynamicProxy</code>: it delays binding until actually needed, and they can now be safely pickled).
167
<LI>Added two new examples to show the use of the new attribute getting/setting, and the creation of new Pyro objects on the server.
168
<LI>Fixed bug in proxy code: nested method calls didn't work. For instance, <code>obj.setCount(obj.getCount()+1)</code> now works correctly.
169
<LI>Daemons (servers) now have a <em>port range</em>. This means that they try to obtain a network port within a range, instead of a single configured port as it was before.
170
The port range allows you to start multiple daemons/servers on a single machine, they now automatically select the next available network port.
171
<LI>New configuration item for the port range: <code>PYRO_PORT_RANGE</code>.
172
<LI>Upgraded <code>pyroc</code> to 1.2; static proxies now also support direct attribute access.
173
<li>Documentation updates for new features.
177
<LI>Removed the <code>DaemonSlave</code> class. Moved it into the <code>Daemon</code> class. Also required small change to <code>TCPServer</code>.
178
<LI>GUID format changed: internally, GUIDs are now treated as a 128 bit binary number (represented as a string of 16 8-bit characters). This saves memory and network bandwidth. Visually, the number is printed as 4 chunks of unsigned 32 bit hex, separated by a dash.
179
<LI>Because of the previous change, the PYRO protocol is no longer compatible with the previous versions. It identifies itself with version 1 rev 3 and raises "incompatible version" exceptions if you try to connect with other protocol versions. Please update all Pyro installations to version 1.3
180
<LI>To handle versioning things better, a few changes in <code>protocol.PYROAdapter</code> were also necessary.
181
<LI>Added optional hostname argument to <code>TCPServer</code> and <code>Pyro.core.Daemon</code>. The <code>ns</code> command has a new option "-n" to specify a specific hostname to bind the server on.
182
<LI>Removed <code>optimizeLocalhost</code> method from <code>PyroURI</code>
183
<LI>URIs no longer use hostnames, they now encode the IP addresses directly. This solves some problems when a DNS service is not available. <code>PyroURI</code> consequently has an <code>address</code> member instead of the previous <code>host</code> member. There are some small changes throughout the code to support this.
184
<LI>Removed 1.5.2 dependency on <code>os.path.abspath</code>.
185
<LI>Fixed bug in Daemon <code>handleRequest</code> loop: in contrast to what the documentation says, it didn't return after a request had been processed. It now does.
186
<LI>WIN32 GUIDs have been removed, and the corresponding configuration item too (<code>PYRO_USE_WIN32GUID</code>).
190
<LI>One word: <em>multithreaded</em>. A few changes in the <code>TCPServer</code> allows it to run in multithreaded mode on systems that have Python threads. Please read the <em>Rules and Limitations</em> chapter for more information. <em>Note that the multithreaded capabilities have not yet been tested very much and probably aren't very stable.</em>
191
<LI>Added <code>PYRO_MULTITHREADED</code> config item to specify whether a Pyro server should be multithreaded or single threaded. It defaults to 1 (multithreaded) on systems that support this.
192
<LI>Fixed a socket bind() error in the NS; it now correctly pays attention to a supplied specific hostname to bind the server on (the BroadcastServer still used to bind on <code>''</code> - fixed).
193
<LI>Removed a socket bind() call from the <code>NameServerLocator</code>.
194
<LI>Fixed small typo in <code>xnsc</code>: the port number of the NS is now correctly displayed.
195
<LI>Added "quickstart" example that uses John Wiegley's <code>remote.py</code> module. It makes using Pyro extremely easy: look at the client and server code!
196
<LI>Added "multithread" example that shows the need of a multithreaded server (as supported since this release).
197
<LI>Added <code>__copy__</code> method to the proxy code, which creates a local copy of a proxy object (with a new connection to the remote object).
198
<LI>Fixed bind() and connect() calls in <code>protocol.py</code> to be compatible with Python 1.6.
199
<LI>Fixed possible socket binding error in Pyro servers by setting socket option to reuse local address.
200
<LI>Fixed problem with binary GUID: <code>int2binstr</code> could return a string with less bytes than expected which creates an invalid binary GUID. The code now passes a required string size and the GUID is now always 4*4 bytes.
201
<LI>Fixed bugs that prevented the use of AttrProxies with delegated objects. You can now use direct attribute access with objects subclassed from ObjBase or delegated objects.
205
<LI>Fixed multithreading issues, most notably the protocol errors ("invalid header"). (An incoming request is now fully read from the socket before a thread is dispatched to process the method call).
206
<LI>Protocol update. You must update all Pyro installations because the new PYRO protocol is incompatible with the previous one.
207
<LI>PYRO protocol can now compress the messages to save bandwidth, for instance over low-speed connections such as modem. You can control this with the new configuration item <code>PYRO_COMPRESSION</code>. However, the current solution is temporary and is likely to be replaced with a more general implementation. The <code>zlib</code> module is used for compression. If you don't have <code>zlib</code>, Pyro still works, but without compression.
208
<LI>Fixed a reference cycle in ObjBase when not using delegate.
209
<LI>Small change to examples/quickstart: existing name is silently overwritten in Name Server.
210
<LI>Small change in <code>Pyro_dyncall</code> method of <code>ObjBase</code> that makes it a little more generic when checking for 'local' attributes.
211
<LI>Small change in error message for INVALID HEADER in protocol.py, now prints socket address.
212
<LI>Xnsc tool is now a bit wider so more text fit in the window without wrapping.
213
<LI>Removed <code>__call__</code> method from <code>DynamicProxy</code>. I assume nobody ever used the only benefit it provided (that <code>proxy('method')</code> was slightly faster than <code>proxy.method()</code>).
214
<LI>Configuration files are handled a little different at startup. If you don't specify a specific config file with the environment setting, Pyro checks for a <code>Pyro.conf</code> file in the current directory.
215
If it exists, Pyro uses it as a configuration file. If it doesn't exist, Pyro uses the default built-in config.
216
Furthermore, Pyro now raises a PyroError if somehow a config file can't be read.
217
<LI>Daemon prints a more verbose error message if it can't start.
218
<LI>Pyro server now raises a PyroError if it can't load the Python module that is needed for the code of objects that were passed in a remote call.
219
<LI>"quickstart" example has been extended. New version of <code>remote.py</code> and a very convenient <code>pyrorun</code> script. (John Wiegley)
220
<LI>Mobile agent example added; "agent" (it comes close but it is not yet a real mobile agent - the code doesn't yet travel across the network)
221
<LI>Small documentation updates and fixes.
226
<LI>NEW MAJOR VERSION. Because of all new features mentioned below.
227
<LI>True mobile agent support! Pyro can now automatically push Python code
228
across the network to make mobile agents possible. See the "agent2" example.
229
<LI>Persistent Naming Service. See relevant documentation! (the new name server chapter)
230
<LI>Added <code>rns</code> script; this script restarts the NS automatically after a shutdown or crash.
231
<LI>Documentation updates (examples + new name server chapter + feature chapter contains much more info).
232
<LI>Changed old persistence code in <code>core.py</code>.
233
<LI>Added <code>PersistentNameServer</code> class in <code>naming.py</code>, which implements a NameServer that uses the hierarchical file system on your disk to store its database in a persistent way.
234
<LI>NameServer now always returns <code>PyroURI</code> instances from <code>resolve</code>. In the past it could also return URIs as strings.
235
<LI>It's no longer possible to delete the root group from the NS.
236
<LI>Removed Python 1.5.1 workarounds ('extra' dir with socketserver module, abspath workaround in config module). Please upgrade to at least Python 1.5.2.
237
<LI>Socket code no longer throws <code>socket.error</code> but <code>Pyro.errors.SocketClosedError</code> exceptions.
238
<LI><code>PYROAdapter</code> has new <code>rebindURI</code> method to support the new auto reconnect/rebind feature when a network problem occurs.
239
<LI><code>PYROAdapter</code> now raises a <code>ProtocolError</code> when it receives a request for an unknown object ID.
240
<LI><code>ServerFullError</code> exception has been removed!!! You must change your code that used it. It has been replaced by a more general <code>ConnectionDeniedError</code> exception.
241
<LI>Generalized new connections check: the daemon now has a <em>new connections validator</em>, which can be replaced by a custom version. The default version implements the old behaviour; checking if the number of connections is less than the maximum amount configured in PYRO_MAXCONNECTIONS. See relevant documentation about the validator.
242
<LI>Added "denyhosts" example to show custom connection validator feature.
243
<LI>Added "autoreconnect" example to show auto reconnect feature.
244
<LI>Name Server now has security plugins; one for validating broadcast requests, and one new connection validator as described above. See relevant docs.
245
<LI>Added "NS_sec_plugins" example to show the NS security plugin feature.
246
<LI>Added "agent2" example with true mobile agent code.
247
<LI>Added <code>PYRO_MOBILE_CODE</code> config item to enable mobile code.
248
<LI>Added <code>PYRO_DNS_URI</code> config item to use symbolic DNS hostnames
249
in URIs instead of fixed IP addresses
250
<LI>Added support for mobile code in <code>Pyro.core.ObjBase</code>.
251
<LI>Performance tuning in <code>core.py</code>; PROTOCOL IS INCOMPATIBLE with previous version.
252
<LI>Slight addition to <code>Pyro.core.Daemon</code>: extra <code>publishhost</code> argument to use in case of firewall situation. See Features chapter.
258
<LI>Pyro is now under the GNU LGPL. See "LICENSE".
259
<LI>Fixed spelling errors in the documentation.
260
<LI>Removed some config items to make things less complex. You have to
261
remove them from your Pyro.conf files too:
262
<LI>Removed config item <code>PYRO_NS_NAME</code>; it is now hardcoded and available (if needed) as <code>Pyro.naming.NS_NAME</code>.
263
<LI>Removed config item <code>PYRO_NS_GROUPSEP</code>; it's now hardcoded as '.'.
264
<LI>Removed config item <code>PYRO_NS_ROOTCHAR</code>; it's now hardcoded as ':'.
265
<LI>Added the Event Service (<code>Pyro.EventService.*</code>). See the chapter on Pyro Services. There is an example too: "stockquotes".
266
<LI>Fixed the "naming" example.
267
<LI>Translated the TODO list from Dutch to English, so everybody can read it now.
268
<LI>Enhanced <code>DynamicProxy</code>; it can now be used as a key in a dictionary. This was needed for the Event Servive.
272
<LI>GUIDs are now constructed using the Python process ID (PID) too. This gives extra safety
273
against double GUIDs possibly generated by multiple python processes on the same machine.
274
<LI>Renamed <code>SocketClosedException</code> to <code>ConnectionClosedException</code>. The new name
275
is more independent of the actual implementation.
276
<LI>Removed some references to the <code>socket</code> module and <code>socket.error</code>.
277
This makes the rest of the code more independent of the actual protocol implementation.
278
A future Pyro release may contain even more changes to fully support multiple protocol implementations (not only sockets).
279
<LI>Documented the <code>pickle</code> trojan vulnerability in the 'Features and Guidelines' chapter.
280
<LI>Included setup script by Alexandre Fayolle.
284
<LI>Pyro now requires at least Python 2.0.1, but Python 2.1.1 or later is recommended. Anything older than Python 2.0.1 is no longer supported.
285
<LI>Added <code>PYRO_NS_HOSTNAME</code> config item, for direct hostname lookup when the NS can't be found using broadcast.
286
<LI>Documentation and examples changed to reflect the above enhancement.
287
<LI>Grand renaming: Naming Service is now called Name Server everywhere. Event Service stays.
288
<LI>Logger now uses YYYY-MM-DD hh:mm:ss date/time format.
289
<LI>Event Service improved, but it now requires threads to work. Major problems
290
have been fixed regarding re-subscribing and unsubscribing while processing events.
291
<LI>Improved rich comparison and hashing of proxies. They can now be a key in a dictionary,
292
and proxies that refer to the same object GUID, compare the same.
293
Sadly, this largely breaks the hashing and rich comparison possibility of the remote Pyro objects. You're not
294
comparing those objects, you're comparing the proxies... The hashing and rich comparison didn't work for remote objects in
295
Pyro 2.2 too (same reasons) so this is not too bad.
296
<LI>Dramatically improved the speed when sending <strong>large</strong> messages: the sock_recv code now uses
297
a list of chunks and joins them at the end, instead of string concatenation.
298
You will see the difference in the hugetransfer example: the message size has been
299
increased tenfold, but the time it takes is almost unchanged :-)
303
<LI>Preliminary Jython support, workarounds/hacks to fill in for missing features such as
304
<code>select</code>, <code>errno</code> and <code>getpid</code>.
305
<em>Only PYRO clients in Jython currently, because servers need <code>select</code>!</em>
306
<LI>Fixed docs about removed config items in Pyro 2.1
307
<LI>Fixed time format string in logger, now the loggings includes the time again on Windows
308
<LI>Fixed indentation errors in quickstart example's <code>remote.py</code> and it
309
should work again on Windows (signals).
310
<LI>Fixed the log file configuration options, they now work as documented. When changing
311
<code>PYRO_LOGFILE</code> or <code>PYRO_USER_LOGFILE</code>, all following log messages
312
are written to the new location. If the filename isn't an absolute path, it will be made
313
relative to the current <code>PYRO_STORAGE</code> location.
314
<LI>Slightly clearified the docs on the <code>PYRO_STORAGE</code> config item.
315
<LI>Updated the example chapter to use Pyro 2.4.
316
<LI>One additional small change to the proxy code: <code>__nonzero__</code> has been defined in the proxy.
317
<LI>Pyroc now also generates proxy code with the various comparison and hashing functions.
318
<LI>Oneway invocations support added. See the chapter on features and guidelines.
319
<LI>New event service example "countingcars" that shows a client that changes its topic subscriptions.
320
<LI>New "callback" example that shows callback invocations to clients and the new Oneway call.
321
<LI>Event service now sets correct (publish) timestamps on events, also with slow clients.
322
<LI>Event service uses oneway invocations to publish the events and to decouple from slow or buggy clients.
323
They no longer stall the publication thread in the ES.
324
<LI>Documentation updates on the new features.
328
<LI>Slight change in names in the example chapter to avoid ambiguity between 'test' object and 'test' module.
329
<LI>Rewrote PYRO_STORAGE directory checking to something much simpler. Should work on all platforms now.
330
<LI>Navbar also at bottom of documentation pages for easier navigation.
331
<LI>New config option <code>PYRO_CHECKSUM</code> to enable a quick Adler32 checksum on the messages.
332
(Why Adler32 and not CRC32? Adler is faster, and we need speed).
333
<LI>Now using regular expression to parse Pyro URI strings.
334
<LI>New URI <code>PYRONAME://nshostname:port/objectname</code> for
335
<em>very</em> easy automatic object lookup. nshostname and port are optional.
336
<LI>New URI <code>PYROLOC://hostname:port/objectname</code> for
337
<em>very</em> easy object binding without using a Name Server. port is optional.
338
<LI>The Pyro Daemon itself is now a Pyro object too. This was needed for the PYROLOC: resolving, but
339
it might prove valuable too in a later version when you might want to access it to get information
340
on server objects, for instance. The Daemon has a fixed builtin GUID,
341
<code>Pyro.core.INTERNAL_DAEMON_GUID</code>. I'm not sure if this feature stays,
342
because it might also be a huge security/stability hole. (please advise?)
343
<LI>Improved documentation here and there.
344
<LI>The setup.py script no longer overwrites system tools blindly, it warns you of this issue and
345
it asks you to specify the path were the Pyro scripts have to be installed.
349
<LI>Fixed mobile code (agents). Internal exception caused socket to shutdown, causing connection lost error.
350
<LI>Minor changes to the docs, documented the mobile code module restriction, a bit more details on auto rebind.
351
<LI>Fixes to some small and a few nasty bugs that had crept in. Some bugs detected by pychecker, yay
352
<LI>Moved constants to new module <code>Pyro.constants</code> to avoid import conflicts.
353
<LI>Renamed and moved the internal Pyro names: <code>Pyro.constants.NAMESERVER_NAME</code> and <code>Pyro.constants.EVENTSERVER_NAME</code>.
354
(previously <code>NS_NAME</code> and <code>EVENTSERVICE_NAME</code>)
355
<LI>Fixed <code>StringTypes</code> that was a Python 2.2 dependency.
356
<LI>Event Server clients will now correctly terminate (the request loop no longer hangs)
360
<LI>Pyro is close to a major new release (3.0). It appears that 2.x has no more big issues.
361
<LI>Mobile code improved: can now transmit modules from packages! Agent2 example changed to reflect this.
362
<LI>Added two more examples: chatbox with and without using the Event Server.
363
<LI>Finally documented the Name Server Pyro object methods.
364
<LI>Minor other changes and additions to the docs.
365
<LI>Fixed some leaks when handling exception tracebacks.
366
<LI>Added logic to transfer remote exception tracebacks to clients and to print them on the client.
367
See <code>Pyro.util.getPyroTraceback</code>.
368
<LI>The <code>NameServerLocator</code> no longer performs a broadcast lookup
369
if the hostname is specified in the <code>getNS</code> call,
370
or if the <code>PYRO_NS_HOSTNAME</code> config item is specified.
371
<LI>Added host and port options to Event Server start script.
372
<LI>Event Server now has nice error handling and cleanup, like the Name Server.
373
<LI>No longer does SO_REUSEADDR on sockets when running under Windows, because
374
Windows has a quirk with this that allows multiple processes to listen on the same socket.
378
<LI>Fixed import Pyro.protocol error by moving RIF_* flags to constants module.
379
<LI>Completed chapter 6 - implementation. Not as much info as I would like, but
380
it's enough to get a quick idea of how Pyro's implemented.
381
<LI>Compressed the example chapter to make it easier to understand.
382
<LI>Changed preferred way of dealing with the daemon's request loop to <code>requestLoop</code>,
383
instead of <code>handleRequests</code> (Don't worry, the latter still exists!).
384
Updated most examples.
385
<LI>Fixed ^C handling of chatbox examples.
386
<LI>Fixed bug when both compression and checksumming were enabled.
387
<LI>Setup script should work again under Win98, also, entering no path for the location
388
for the script files takes the distutils default path.
389
<LI>Fixed old bug in pyroc generated proxy code (method names for remote attribute access were wrong)
390
<LI>Added agent docs on module dependencies: imports of other unknown modules don't work in agents.
392
2.8 was the latest Pyro version in the 2.X series. Development continued with Pyro 3.0.
395
<table border="0" width="100%">
397
<td align="left"><a href="11-services.html"><previous</a> | <a href="PyroManual.html">contents</a></td>
398
<td align="right">Pyro Manual</td>
1
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
3
<!-- $Id: 12-changes-archive.html,v 2.8 2007/02/11 13:56:41 irmen Exp $ -->
5
<title>PYRO - Change Log (archive)</title>
6
<link rel="stylesheet" type="text/css" href="pyromanual_print.css" media="print">
7
<link rel="stylesheet" type="text/css" href="pyromanual.css" media="screen">
14
<td align="left"><a href="11-services.html"><previous</a> | <a href="PyroManual.html">contents</a></td>
16
<td align="right">Pyro Manual</td>
21
<h2><u>Pyro Change Log (archive)</u></h2>
23
<p>The recent Pyro versions can be found in the regular <a href="12-changes.html">change log</a>.</p>
25
<p>Pyro 0.1 has been lost in the dust. It wasn't suited for publication anyway, I guess :-)</p>
27
<h3>Pyro 0.2</h3>First working release. Only static proxies and very little configurability.
32
<li>MAJOR: added Dynamic Proxies! Clients don't need to have a precompiled proxy file available any more! Check out
33
<code>core.getProxyForURI/DynamicProxy</code>.</li>
35
<li>MAJOR: reworked the configuration possibilities. Check out <code>__init__.py</code>.</li>
37
<li>Moved config items to a class in <code>__init__.py</code>. They are accessed using
38
'<code>Pyro.config.<item></code>'.</li>
40
<li>Made the port and broadcast port configurable independently. The command lines now accept options to specify
41
either or both ports.</li>
43
<li>naming: added delay in broadcast loop (wait a little for replies to arrive), Naming Service now returns
44
PyroErrors instead of regular exceptions.</li>
46
<li>core: Cleaned up the Pyro exception passing, added <code>DynamicProxy</code> and
47
<code>getProxyForURI</code></li>
49
<li>pyroc: fixed bug in method output code (could forget a comma)</li>
51
<li>nsc: fully rewrote the parsing code to use the <code>util.ArgVParser</code></li>
53
<li>scripts: the Window <code>.bat</code> files now use <code>%$</code></li>
55
<li>added <code>util.py</code>, which contains a basic <code>sys.argv</code> parser like
56
<code>getopt()</code>.</li>
62
<li>naming: changed broadcast server to reflect changes in Python 1.5.2's <code>SocketServer</code> module. Pyro
63
now requires this new <code>SocketServer</code> module (which works with previous Python versions, too, so you
64
could only replace the <code>SocketServer</code> module and keep the rest of your Python installation intact).</li>
66
<li>naming: fixed bugs when reporting exceptions ('entry already exists' and 'not found').</li>
68
<li>util: added <code>getUUID</code> function, and a script <code>genuuid</code>.</li>
70
<li>core: Pyro objects are now identified by a full UUID, instead of a simple Python <code>id()</code>. This should
71
prevent nasty object ID problems, especially later when persistent naming and object activation will be
78
<li>MAJOR: the Pyro Naming Service now is a Pyro object itself, too. It can be accessed through its Pyro
81
<li>More specific exceptions (<code>ProtocolError, URIError, DaemonError, NamingError</code>...)</li>
83
<li>It is now possible to connect objects without the presence of a Naming Service.</li>
85
<li>core: the Daemon can now handle requests for others too, by a callback mechanism. Also removed up the
86
server-side exception trace info when the exception is generated on purpose, and added a nice message when the
87
daemon cannot be started.</li>
89
<li>naming: many changes to make the Name Server a Pyro object itself. Finding the NS is now done through the
90
<code>NameServerLocator</code>, which returns a regular Pyro proxy for the NS. No <code>NameServerClient</code> is
93
<li>util: tweaked the way the timestamp in URIs is generated.</li>
95
<li>config: more configurable items.</li>
97
<li>scripts: <code>Pyroc.bat</code> now uses <code>%$</code>, too (oops!)</li>
103
<li>Added <code>xnsc</code>, a naming service control tool with a GUI (uses <code>Tkinter</code>).</li>
105
<li>The naming service can be launched in 'persistent mode': it will keep the naming directory in a persistent
106
database on disk. EXPERIMENTAL!</li>
108
<li>core: added 2 configuration variables in <code>Pyro.config</code>: <code>PYRO_PATH</code> and
109
<code>PYRO_STORAGE</code>.</li>
111
<li>core: added method to <code>ObjBase</code> to set a fixed (persistent) object UUID.</li>
113
<li>core: slight change in the init code of <code>PyroURI</code>, it can now be created directly from a URI string,
114
instead of using <code>initFromString</code>.</li>
116
<li>core: the <code>Daemon</code> now has preliminary support for persistent objects:
117
<code>connectPersistent</code> and <code>disconnectPersistent</code> methods were added. LIKELY TO CHANGE!</li>
119
<li>naming: added a persistent name server class <code>PersistentNameServer</code>. Also added some code to deal
120
with this when using the '<code>ns</code>' command line tool: a new option '<code>-db</code>' has been added to
121
specify persistent mode.</li>
123
<li>naming: the broadcast server now binds on '' instead of the hostname. This appears to be more compatible (on
124
some systems it was impossible to connect to the broadcast server).</li>
126
<li>naming: implemented graceful shutdown command. The server also uses a timeout loop for the requests (because
127
otherwise ^C wouldn't break gracefully on WinNT - Duh).</li>
129
<li>scripts: <code>nsc</code> (and <code>xnsc</code>) now print a sorted list (and have the shutdown command).</li>
131
<li>scripts: the <code>.bat</code> files now won't echo the python command anymore.</li>
133
<li>utils: <code>ArgParser</code> changed to use <code>None</code> instead of <code>1</code> when no arguments are
134
given to a certain option.</li>
136
<li>test: <code>testclient</code> will use dynamic proxy automatically if no static proxy is found. Also, it will
137
try a direct connect if the NS lookup by broadcast fails.</li>
143
<li>bumped all versions to 0.7</li>
145
<li>NOTE: because of some changes you will have to generate your proxies again with <code>pyroc</code>!</li>
147
<li>core: separated the Exception types and the protocol adapters to <code>errors.py</code> and
148
<code>protocol.py</code>.</li>
150
<li>util: added a <code>Logger</code> object, <code>Log</code>. It is used throughout Pyro to log messages,
151
warnings and errors. You can configure the logfile and the trace level settings with some new configuration
152
options. Ofcourse you can use it for your own logging purposes too.</li>
154
<li>init: changed the way configuration items are set up. If a corresponding environment variable exists, that
155
value is used. Otherwise the default applies. This works for all configuration options except
156
<code>PYRO_NS_NAME</code> because that is a registered name and should not be changed.</li>
158
<li>naming: the naming server now writes its URI to a special output file. This can be used to contact the naming
159
server if you can't use the broadcast locator for some reason.</li>
161
<li>uuids: renamed UUID to GUID (Globally Unique ID). You can never be sure that your ID is Universally Unique, so
162
I changed the name. Also, the <code>genuuid</code> scripts have been renamed to <code>genguid</code>.</li>
164
<li>changed default pickling mode to binary, to improve performance. A new configuration option lets you choose
165
between ASCII or binary.</li>
167
<li>pyroc: fixed a problem where the '<code>self</code>' argument of a member function had a different name. Pyroc
168
now uses '<code>S</code>' everywhere.</li>
170
<li>pyroc: added support for inherited classes. A module within a Python package is not yet supported as
173
<li>pyroc: explicit checks against special Python methods <code>__xxx__</code>. They are not allowed in the proxy
176
<li>MAJOR documentation update.</li>
182
<li>A few fixes in the source comments.</li>
184
<li>Added separate user logging facility and fixed small bug in logger code (it was too picky on the
187
<li>Moved some protocol dependent code from <code>core.py</code> to <code>protocol.py</code></li>
189
<li>New exception model! See documentation! Basically, every exception on the server side will be catched and
190
raised on the client side.</li>
192
<li>Naming server and the <code>nsc</code> and <code>xnsc</code> tools are stricter with the names and URIs they
195
<li>GUIDs are now 128 bit (instead of 144) and Pyro can use Windows GUIDs on the Windows platform. This is
196
configurable trough a new configuration item <code>PYRO_USE_WIN32GUID</code>. This is <em>not</em> the default and
197
will work only on the Windows platform, because the Python COM extension is used for this.</li>
199
<li>New <code>genguid</code> script with '<code>-w</code>' argument to generate a Windows GUID if possible.</li>
201
<li>Fixed some things to allow for special 'localhost' optimization (the reduced overhead of some network
202
implementations when using 'localhost' instead of the real hostname). The changes are:
205
<li>Pyro daemon now binds on '' instead of hostname. Previously, URIs with the 'localhost' hostname couldn't be
208
<li>The <code>PyroURI</code> class has a new <code>optimizeLocalhost</code> method, which -if possible-
209
optimizes the URI for localhost addressing.</li>
210
</ul>This also paves the way for more optimizations might be added when Pyro detects a local URI. (for instance,
211
using IPC instead of going trough the network)
214
<li>Implemented Delegate pattern for remote object implementations. Instead of subclassing your object
215
implementation from <code>Pyro.core.ObjBase</code>, you just create a <code>Pyro.core.ObjBase</code> object and
216
tell it to use another object as a delegate.</li>
218
<li>New <code>ArgParser</code> in <code>util.py</code>, to support more convenient script arguments. A few scripts
219
have slightly altered syntaxes now, which should be more convenient. The old syntax should still work however.</li>
221
<li>Documentation updates. Major addition is the new chapter with a practical guide about how to develop Pyro
228
<li>MAJOR: Reimplemented the PYRO protocol. It now uses a MUD-like system instead of a webserver-like system. The
229
protocol used to create a new socket connection for each method call. This is inefficient and resource hungry. The
230
new implementation uses a single socket for each Pyro object, and all method calls and replies are passed over this
231
connection. The connection remains active until the object is no longer needed. The new implementation no longer
232
has the serious problem that the previous implementation had on most machines: when a lot of method calls were
233
made, the system would crash with some sort of 'resource unavailable' or 'out of memory' error. The new protocol is
234
also faster than the previous one on all systems.</li>
236
<li>Because of the new protocol, I think Pyro now deserves the version 1 status: bumped all version numbers to
239
<li>The Pyro <code>Daemon</code> inherits from the new <code>TCPServer</code> base class (in
240
<code>protocol.py</code>). This server replaces the <code>SocketServer.TCPServer</code>. The new server keeps a
241
list of active connections, while the old one operated like a webserver: it created a new socket connection for
244
<li>Pyro Daemon has been adapted to the new protocol.</li>
246
<li><strong>NOTE:</strong> The new PYRO protocol is <em>incompatible</em> with the older versions. Communication is
247
impossible between different Pyro versions. You should upgrade all Pyro installations to the new version. However,
248
user code does <em>not</em> have to be changed. Old code still runs on top of the new implementation (the API has
249
not been changed).</li>
251
<li>The Windows .bat scripts now use <code>#*</code> instead of <code>#$</code> (which didn't work on the standard
252
Windows95/NT command prompt).</li>
254
<li><code>xnsc</code> handles communication errors better.</li>
256
<li>Organized the tests in the <code>test</code> directory and added some readme files. Also added some more
259
<li>Moved some socket code out of other modules to <code>protocol.py</code>. Now only <code>naming.py</code> and
260
<code>protocol.py</code> have socket code.</li>
262
<li>Removed the <code>NULLAdapter</code>.</li>
264
<li>Removed the pickling of NS system commands. They're simple strings now.</li>
266
<li>Added socket send/receive helper functions in <code>protocol.py</code> for robust data transmission. The new
267
protocol code uses them. Performance is lower but the new code should guarantee correct behaviour even at high
268
network loads with many packet losses and fragmentations.</li>
270
<li>New exceptions <code>SocketClosedError</code> and <code>ServerFullError</code>.</li>
272
<li>Removed <code>RemotePyroException</code> (unused).</li>
274
<li>Small change in the <code>xnsc</code> GUI: better resizing</li>
276
<li>The new protocol enforces a limit on the number of simultaneous connections to each Pyro daemon. This is for
277
protection of the server machine. There is a new configuration item <code>PYRO_MAXCONNECTIONS</code> that sets this
278
limit. Currently the default is 200.</li>
280
<li>The <code>unregister</code> method of the naming service now raises a <code>NamingError</code> when the name is
281
not known. I added this because usually this signals a typo in the calling code (it should never unregister an
284
<li>Documentation updates; manual is finished except for the implementation chapter.</li>
290
<li>MAJOR: Naming Service now has a hierarchical namespace. It has groups, which can contain other
291
groups or names. By default, a dot ('.') in a name is the group separator, so that "group1.group2.name"
292
is a hierarchical name. Notice that this is much like DNS's host/domain name scheme, but <em>in
293
reverse order</em>, rather like a directory
294
structure in a disk file system. The big gain from all this is that you can have different "domains"
295
(namespaces) in your Pyro environment. With a simple change of the default namespace group your
296
system uses a different "domain"
297
and the object names will not interfere with other systems (provided your namespace group is unique).
298
For an application of this, see the new test programs, which now all use the ':test' namespace group.
299
Also, it opens the gates for an even more sophisticated naming service: a distributed federated hierarchical
300
nameservice (wow!! :-)</li>
302
<li>The default or de facto namespace group is ":Default". This means that Pyro code that does
303
not (yet) use the new naming scheme will wind up registering all its object names in this namespace
304
group. That's nice because this is a simple way to avoid name clashes with legacy Pyro code and
307
<li>Adapted the NS proxy to enforce the default group on all names that are not absolute from the root. It is now
308
required that all names passed to the NS are absolute (fully expanded), the hand coded NS proxy takes care of this.
309
Note that a proxy obtained for the NS by other means <em>does not have this feature</em> and will likely break your
310
code! Notably, the use of a dynamic proxy for the NS will no longer work correctly. Always use the <em>static
311
proxy</em> from the <code>naming</code> module.</li>
313
<li>Added configuration item <code>PYRO_NS_GROUPSEP</code>, which is the character that separates groups in names.
314
By default it is a dot ('.'), but if this proves incompatible with existing naming schemes (that use dots in the
315
names), just change it to something else. Notice that this item is only examined <em>once</em>: at startup time.
316
You have to restart the Naming Service if you change this item.</li>
318
<li>Added configuration item <code>PYRO_NS_DEFAULTGROUP</code>, which is the default group name in which names are
319
located. This simplifies partitioning your name space greatly. Notice that the Name Server proxy code is hand
320
crafted to enforce this name.</li>
322
<li>Added configuration item <code>PYRO_NS_ROOTCHAR</code>, which is the default escape character at the beginning
323
of names, which indicates the name is absolute from the root.</li>
325
<li>Changed the config item for the name server name to include a root character. Existing code should not break
326
(if it does, you probably didn't use <code>PYRO_NS_NAME</code>...</li>
328
<li>Extended the name server object with three new remote methods for hierarchical naming support:
329
<code>createGroup</code>, <code>deleteGroup</code> and <code>list</code>. Furthermore, <code>status</code> has been
330
renamed to <code>flatlist</code>. This suggests better what it does: return a flat dump of the namespace.</li>
332
<li>Extended <code>nsc</code> and <code>xnsc</code> with the new naming service features: <em>list</em>,
333
<em>creategroup</em> and <em>deletegroup</em> commands. (The old <em>list</em> command was renamed to
334
<em>listall</em>).</li>
336
<li>Simplified dynamic proxy. It used to create a invocation object with each method call, this is no longer
339
<li>Fixed bug in <code>protocol.py</code> where a <code>KeyError</code> in a method invocation was always treated
340
as if a method call on an unknown object was tried, even when the object was correct (but raised a
341
<code>KeyError</code>)</li>
343
<li>Naming service will no longer crash when an unexpected exception occurs while it is running. It will log and
344
print the error and resume operations. A ctrl-c (<code>KeyboardInterrupt</code>) will still abort it, however, as
345
will sending a <em>shutdown</em> command.</li>
347
<li>Small change in the Daemon in <code>core.py</code>. If a ProtocolError is detected (for instance, an invalid
348
header), the connection is dropped and operations are resumed. Pyro used to block or crash when a non-Pyro client
349
connected, such as a plain telnet or a web browser pointed at Pyro's socket.</li>
351
<li>Test servers and clients are now using common code bases. They're registering their names in
352
a new "<code>:test</code>" group (namespace) too, to help avoid conflicts with your
353
own names. Servers will no longer crash if their name is already registered (they just register
356
<li>Fixed a few small errors in some of the test programs, and created an electronic banking example to be a nice
357
starting point for Pyro applications.</li>
359
<li>Fixed bug in some default arguments to functions, where config items were used. Now they are parsed at use
360
instead of at module import time.</li>
362
<li>Added '<code>-k</code>' switch to <code>ns</code> that will start the NS in a mode in which it ignores shutdown
363
requests sent by <code>nsc</code>. This is a crude form of security, to protect the NS for malicious
366
<li>Documentation updates about the new naming scheme.</li>
368
<li>New example added that uses the new naming functions.</li>
370
<li>Configuration files! You can now use a configuration file that contains all required Pyro config options. It's
371
no longer necessary to use a big list of environment variables.</li>
373
<li>New configuration item <code>PYRO_CONFIG_FILE</code>. Only useful as environment variable, it points to the
374
configuration file Pyro has to use.</li>
380
<li>Fixed bug in TCPserver code (could skip connections). Please update all Pyro installations because this was a
381
rather nasty bug.</li>
383
<li><code>Daemon.connect</code> now returns the URI it connects the object as. This is convenient for servers that
384
want to use the URI immediately without having to consult the nameserver.</li>
386
<li>It's now possible to get/set attributes on Pyro objects with normal Python syntax! (changes to
387
<code>ObjBase</code> and new <code>DynamicProxyWithAttr</code>) <em>You have to update all Pyro installations if
388
you want to use this new feature.</em> If you don't use it, Pyro 1.2 should work together with version 1.1. Notice
389
that there is a performance hit of a few percent when you use <code>DynamicProxyWithAttr</code> instead of the
390
regular <code>DynamicProxy</code> to support the attribute feature.</li>
392
<li>Server objects can now create new Pyro objects and marshal Proxy objects to the clients! (changes to
393
<code>DynamicProxy</code>: it delays binding until actually needed, and they can now be safely pickled).</li>
395
<li>Added two new examples to show the use of the new attribute getting/setting, and the creation of new Pyro
396
objects on the server.</li>
398
<li>Fixed bug in proxy code: nested method calls didn't work. For instance,
399
<code>obj.setCount(obj.getCount()+1)</code> now works correctly.</li>
401
<li>Daemons (servers) now have a <em>port range</em>. This means that they try to obtain a network port within a
402
range, instead of a single configured port as it was before. The port range allows you to start multiple
403
daemons/servers on a single machine, they now automatically select the next available network port.</li>
405
<li>New configuration item for the port range: <code>PYRO_PORT_RANGE</code>.</li>
407
<li>Upgraded <code>pyroc</code> to 1.2; static proxies now also support direct attribute access.</li>
409
<li>Documentation updates for new features.</li>
415
<li>Removed the <code>DaemonSlave</code> class. Moved it into the <code>Daemon</code> class. Also required small
416
change to <code>TCPServer</code>.</li>
418
<li>GUID format changed: internally, GUIDs are now treated as a 128 bit binary number (represented as a string of
419
16 8-bit characters). This saves memory and network bandwidth. Visually, the number is printed as 4 chunks of
420
unsigned 32 bit hex, separated by a dash.</li>
422
<li>Because of the previous change, the PYRO protocol is no longer compatible with the previous versions.
423
It identifies itself with version 1 rev 3 and raises "incompatible version" exceptions if
424
you try to connect with other protocol versions. Please update all Pyro installations to version
427
<li>To handle versioning things better, a few changes in <code>protocol.PYROAdapter</code> were also
430
<li>Added optional hostname argument to <code>TCPServer</code> and <code>Pyro.core.Daemon</code>.
432
<code>ns</code> command has a new option "-n" to specify a specific hostname to bind the server
435
<li>Removed <code>optimizeLocalhost</code> method from <code>PyroURI</code></li>
437
<li>URIs no longer use hostnames, they now encode the IP addresses directly. This solves some problems when a DNS
438
service is not available. <code>PyroURI</code> consequently has an <code>address</code> member instead of the
439
previous <code>host</code> member. There are some small changes throughout the code to support this.</li>
441
<li>Removed 1.5.2 dependency on <code>os.path.abspath</code>.</li>
443
<li>Fixed bug in Daemon <code>handleRequest</code> loop: in contrast to what the documentation says, it didn't
444
return after a request had been processed. It now does.</li>
446
<li>WIN32 GUIDs have been removed, and the corresponding configuration item too
447
(<code>PYRO_USE_WIN32GUID</code>).</li>
453
<li>One word: <em>multithreaded</em>. A few changes in the <code>TCPServer</code> allows it to run in multithreaded
454
mode on systems that have Python threads. Please read the <em>Rules and Limitations</em> chapter for more
455
information. <em>Note that the multithreaded capabilities have not yet been tested very much and probably aren't
456
very stable.</em></li>
458
<li>Added <code>PYRO_MULTITHREADED</code> config item to specify whether a Pyro server should be multithreaded or
459
single threaded. It defaults to 1 (multithreaded) on systems that support this.</li>
461
<li>Fixed a socket bind() error in the NS; it now correctly pays attention to a supplied specific hostname to bind
462
the server on (the BroadcastServer still used to bind on <code>''</code> - fixed).</li>
464
<li>Removed a socket bind() call from the <code>NameServerLocator</code>.</li>
466
<li>Fixed small typo in <code>xnsc</code>: the port number of the NS is now correctly displayed.</li>
468
<li>Added "quickstart" example that uses John Wiegley's <code>remote.py</code> module.
469
It makes using Pyro extremely easy: look at the client and server code!</li>
471
<li>Added "multithread" example that shows the need of a multithreaded server (as supported
472
since this release).</li>
474
<li>Added <code>__copy__</code> method to the proxy code, which creates a local copy of a proxy object (with a new
475
connection to the remote object).</li>
477
<li>Fixed bind() and connect() calls in <code>protocol.py</code> to be compatible with Python 1.6.</li>
479
<li>Fixed possible socket binding error in Pyro servers by setting socket option to reuse local address.</li>
481
<li>Fixed problem with binary GUID: <code>int2binstr</code> could return a string with less bytes than expected
482
which creates an invalid binary GUID. The code now passes a required string size and the GUID is now always 4*4
485
<li>Fixed bugs that prevented the use of AttrProxies with delegated objects. You can now use direct attribute
486
access with objects subclassed from ObjBase or delegated objects.</li>
492
<li>Fixed multithreading issues, most notably the protocol errors ("invalid header"). (An incoming
493
request is now fully read from the socket before a thread is dispatched to process the method
496
<li>Protocol update. You must update all Pyro installations because the new PYRO protocol is incompatible with the
499
<li>PYRO protocol can now compress the messages to save bandwidth, for instance over low-speed connections such as
500
modem. You can control this with the new configuration item <code>PYRO_COMPRESSION</code>. However, the current
501
solution is temporary and is likely to be replaced with a more general implementation. The <code>zlib</code> module
502
is used for compression. If you don't have <code>zlib</code>, Pyro still works, but without compression.</li>
504
<li>Fixed a reference cycle in ObjBase when not using delegate.</li>
506
<li>Small change to examples/quickstart: existing name is silently overwritten in Name Server.</li>
508
<li>Small change in <code>Pyro_dyncall</code> method of <code>ObjBase</code> that makes it a little more generic
509
when checking for 'local' attributes.</li>
511
<li>Small change in error message for INVALID HEADER in protocol.py, now prints socket address.</li>
513
<li>Xnsc tool is now a bit wider so more text fit in the window without wrapping.</li>
515
<li>Removed <code>__call__</code> method from <code>DynamicProxy</code>. I assume nobody ever used the only benefit
516
it provided (that <code>proxy('method')</code> was slightly faster than <code>proxy.method()</code>).</li>
518
<li>Configuration files are handled a little different at startup. If you don't specify a specific config file with
519
the environment setting, Pyro checks for a <code>Pyro.conf</code> file in the current directory. If it exists, Pyro
520
uses it as a configuration file. If it doesn't exist, Pyro uses the default built-in config. Furthermore, Pyro now
521
raises a PyroError if somehow a config file can't be read.</li>
523
<li>Daemon prints a more verbose error message if it can't start.</li>
525
<li>Pyro server now raises a PyroError if it can't load the Python module that is needed for the code of objects
526
that were passed in a remote call.</li>
528
<li>"quickstart" example has been extended. New version of <code>remote.py</code> and a
530
<code>pyrorun</code> script. (John Wiegley)</li>
532
<li>Mobile agent example added; "agent" (it comes close but it is not yet a real mobile agent
533
- the code doesn't yet travel across the network)</li>
535
<li>Small documentation updates and fixes.</li>
541
<li>NEW MAJOR VERSION. Because of all new features mentioned below.</li>
543
<li>True mobile agent support! Pyro can now automatically push Python code across the network to
544
make mobile agents possible. See the "agent2" example.</li>
546
<li>Persistent Naming Service. See relevant documentation! (the new name server chapter)</li>
548
<li>Added <code>rns</code> script; this script restarts the NS automatically after a shutdown or crash.</li>
550
<li>Documentation updates (examples + new name server chapter + feature chapter contains much more info).</li>
552
<li>Changed old persistence code in <code>core.py</code>.</li>
554
<li>Added <code>PersistentNameServer</code> class in <code>naming.py</code>, which implements a NameServer that
555
uses the hierarchical file system on your disk to store its database in a persistent way.</li>
557
<li>NameServer now always returns <code>PyroURI</code> instances from <code>resolve</code>. In the past it could
558
also return URIs as strings.</li>
560
<li>It's no longer possible to delete the root group from the NS.</li>
562
<li>Removed Python 1.5.1 workarounds ('extra' dir with socketserver module, abspath workaround in config module).
563
Please upgrade to at least Python 1.5.2.</li>
565
<li>Socket code no longer throws <code>socket.error</code> but <code>Pyro.errors.SocketClosedError</code>
568
<li><code>PYROAdapter</code> has new <code>rebindURI</code> method to support the new auto reconnect/rebind feature
569
when a network problem occurs.</li>
571
<li><code>PYROAdapter</code> now raises a <code>ProtocolError</code> when it receives a request for an unknown
574
<li><code>ServerFullError</code> exception has been removed!!! You must change your code that used it. It has been
575
replaced by a more general <code>ConnectionDeniedError</code> exception.</li>
577
<li>Generalized new connections check: the daemon now has a <em>new connections validator</em>, which can be
578
replaced by a custom version. The default version implements the old behaviour; checking if the number of
579
connections is less than the maximum amount configured in PYRO_MAXCONNECTIONS. See relevant documentation about the
582
<li>Added "denyhosts" example to show custom connection validator feature.</li>
584
<li>Added "autoreconnect" example to show auto reconnect feature.</li>
586
<li>Name Server now has security plugins; one for validating broadcast requests, and one new connection validator
587
as described above. See relevant docs.</li>
589
<li>Added "NS_sec_plugins" example to show the NS security plugin feature.</li>
591
<li>Added "agent2" example with true mobile agent code.</li>
593
<li>Added <code>PYRO_MOBILE_CODE</code> config item to enable mobile code.</li>
595
<li>Added <code>PYRO_DNS_URI</code> config item to use symbolic DNS hostnames in URIs instead of fixed IP
598
<li>Added support for mobile code in <code>Pyro.core.ObjBase</code>.</li>
600
<li>Performance tuning in <code>core.py</code>; PROTOCOL IS INCOMPATIBLE with previous version.</li>
602
<li>Slight addition to <code>Pyro.core.Daemon</code>: extra <code>publishhost</code> argument to use in case of
603
firewall situation. See Features chapter.</li>
609
<li>Pyro is now under the GNU LGPL. See "LICENSE".</li>
611
<li>Fixed spelling errors in the documentation.</li>
613
<li>Removed some config items to make things less complex. You have to remove them from your Pyro.conf files
616
<li>Removed config item <code>PYRO_NS_NAME</code>; it is now hardcoded and available (if needed) as
617
<code>Pyro.naming.NS_NAME</code>.</li>
619
<li>Removed config item <code>PYRO_NS_GROUPSEP</code>; it's now hardcoded as '.'.</li>
621
<li>Removed config item <code>PYRO_NS_ROOTCHAR</code>; it's now hardcoded as ':'.</li>
623
<li>Added the Event Service (<code>Pyro.EventService.*</code>). See the chapter on Pyro Services.
624
There is an example too: "stockquotes".</li>
626
<li>Fixed the "naming" example.</li>
628
<li>Translated the TODO list from Dutch to English, so everybody can read it now.</li>
630
<li>Enhanced <code>DynamicProxy</code>; it can now be used as a key in a dictionary. This was needed for the Event
637
<li>GUIDs are now constructed using the Python process ID (PID) too. This gives extra safety against double GUIDs
638
possibly generated by multiple python processes on the same machine.</li>
640
<li>Renamed <code>SocketClosedException</code> to <code>ConnectionClosedException</code>. The new name is more
641
independent of the actual implementation.</li>
643
<li>Removed some references to the <code>socket</code> module and <code>socket.error</code>. This makes the rest of
644
the code more independent of the actual protocol implementation. A future Pyro release may contain even more
645
changes to fully support multiple protocol implementations (not only sockets).</li>
647
<li>Documented the <code>pickle</code> trojan vulnerability in the 'Features and Guidelines' chapter.</li>
649
<li>Included setup script by Alexandre Fayolle.</li>
655
<li>Pyro now requires at least Python 2.0.1, but Python 2.1.1 or later is recommended. Anything older than Python
656
2.0.1 is no longer supported.</li>
658
<li>Added <code>PYRO_NS_HOSTNAME</code> config item, for direct hostname lookup when the NS can't be found using
661
<li>Documentation and examples changed to reflect the above enhancement.</li>
663
<li>Grand renaming: Naming Service is now called Name Server everywhere. Event Service stays.</li>
665
<li>Logger now uses YYYY-MM-DD hh:mm:ss date/time format.</li>
667
<li>Event Service improved, but it now requires threads to work. Major problems have been fixed regarding
668
re-subscribing and unsubscribing while processing events.</li>
670
<li>Improved rich comparison and hashing of proxies. They can now be a key in a dictionary, and proxies that refer
671
to the same object GUID, compare the same. Sadly, this largely breaks the hashing and rich comparison possibility
672
of the remote Pyro objects. You're not comparing those objects, you're comparing the proxies... The hashing and
673
rich comparison didn't work for remote objects in Pyro 2.2 too (same reasons) so this is not too bad.</li>
675
<li>Dramatically improved the speed when sending <strong>large</strong> messages: the sock_recv code now uses a
676
list of chunks and joins them at the end, instead of string concatenation. You will see the difference in the
677
hugetransfer example: the message size has been increased tenfold, but the time it takes is almost unchanged
684
<li>Preliminary Jython support, workarounds/hacks to fill in for missing features such as <code>select</code>,
685
<code>errno</code> and <code>getpid</code>. <em>Only PYRO clients in Jython currently, because servers need
686
<code>select</code>!</em></li>
688
<li>Fixed docs about removed config items in Pyro 2.1</li>
690
<li>Fixed time format string in logger, now the loggings includes the time again on Windows</li>
692
<li>Fixed indentation errors in quickstart example's <code>remote.py</code> and it should work again on Windows
695
<li>Fixed the log file configuration options, they now work as documented. When changing <code>PYRO_LOGFILE</code>
696
or <code>PYRO_USER_LOGFILE</code>, all following log messages are written to the new location. If the filename
697
isn't an absolute path, it will be made relative to the current <code>PYRO_STORAGE</code> location.</li>
699
<li>Slightly clearified the docs on the <code>PYRO_STORAGE</code> config item.</li>
701
<li>Updated the example chapter to use Pyro 2.4.</li>
703
<li>One additional small change to the proxy code: <code>__nonzero__</code> has been defined in the proxy.</li>
705
<li>Pyroc now also generates proxy code with the various comparison and hashing functions.</li>
707
<li>Oneway invocations support added. See the chapter on features and guidelines.</li>
709
<li>New event service example "countingcars" that shows a client that changes its topic subscriptions.</li>
711
<li>New "callback" example that shows callback invocations to clients and the new Oneway call.</li>
713
<li>Event service now sets correct (publish) timestamps on events, also with slow clients.</li>
715
<li>Event service uses oneway invocations to publish the events and to decouple from slow or buggy clients. They no
716
longer stall the publication thread in the ES.</li>
718
<li>Documentation updates on the new features.</li>
724
<li>Slight change in names in the example chapter to avoid ambiguity between 'test' object and 'test' module.</li>
726
<li>Rewrote PYRO_STORAGE directory checking to something much simpler. Should work on all platforms now.</li>
728
<li>Navbar also at bottom of documentation pages for easier navigation.</li>
730
<li>New config option <code>PYRO_CHECKSUM</code> to enable a quick Adler32 checksum on the messages. (Why Adler32
731
and not CRC32? Adler is faster, and we need speed).</li>
733
<li>Now using regular expression to parse Pyro URI strings.</li>
735
<li>New URI <code>PYRONAME://nshostname:port/objectname</code> for <em>very</em> easy automatic object lookup.
736
nshostname and port are optional.</li>
738
<li>New URI <code>PYROLOC://hostname:port/objectname</code> for <em>very</em> easy object binding without using a
739
Name Server. port is optional.</li>
741
<li>The Pyro Daemon itself is now a Pyro object too. This was needed for the PYROLOC: resolving, but it might prove
742
valuable too in a later version when you might want to access it to get information on server objects, for
743
instance. The Daemon has a fixed builtin GUID, <code>Pyro.core.INTERNAL_DAEMON_GUID</code>. I'm not sure if this
744
feature stays, because it might also be a huge security/stability hole. (please advise?)</li>
746
<li>Improved documentation here and there.</li>
748
<li>The setup.py script no longer overwrites system tools blindly, it warns you of this issue and it asks you to
749
specify the path were the Pyro scripts have to be installed.</li>
755
<li>Fixed mobile code (agents). Internal exception caused socket to shutdown, causing connection lost error.</li>
757
<li>Minor changes to the docs, documented the mobile code module restriction, a bit more details on auto
760
<li>Fixes to some small and a few nasty bugs that had crept in. Some bugs detected by pychecker, yay</li>
762
<li>Moved constants to new module <code>Pyro.constants</code> to avoid import conflicts.</li>
764
<li>Renamed and moved the internal Pyro names: <code>Pyro.constants.NAMESERVER_NAME</code> and
765
<code>Pyro.constants.EVENTSERVER_NAME</code>. (previously <code>NS_NAME</code> and
766
<code>EVENTSERVICE_NAME</code>)</li>
768
<li>Fixed <code>StringTypes</code> that was a Python 2.2 dependency.</li>
770
<li>Event Server clients will now correctly terminate (the request loop no longer hangs)</li>
776
<li>Pyro is close to a major new release (3.0). It appears that 2.x has no more big issues.</li>
778
<li>Mobile code improved: can now transmit modules from packages! Agent2 example changed to reflect this.</li>
780
<li>Added two more examples: chatbox with and without using the Event Server.</li>
782
<li>Finally documented the Name Server Pyro object methods.</li>
784
<li>Minor other changes and additions to the docs.</li>
786
<li>Fixed some leaks when handling exception tracebacks.</li>
788
<li>Added logic to transfer remote exception tracebacks to clients and to print them on the client. See
789
<code>Pyro.util.getPyroTraceback</code>.</li>
791
<li>The <code>NameServerLocator</code> no longer performs a broadcast lookup if the hostname is specified in the
792
<code>getNS</code> call, or if the <code>PYRO_NS_HOSTNAME</code> config item is specified.</li>
794
<li>Added host and port options to Event Server start script.</li>
796
<li>Event Server now has nice error handling and cleanup, like the Name Server.</li>
798
<li>No longer does SO_REUSEADDR on sockets when running under Windows, because Windows has a quirk with this that
799
allows multiple processes to listen on the same socket.</li>
805
<li>Fixed import Pyro.protocol error by moving RIF_* flags to constants module.</li>
807
<li>Completed chapter 6 - implementation. Not as much info as I would like, but it's enough to get a quick idea of
808
how Pyro's implemented.</li>
810
<li>Compressed the example chapter to make it easier to understand.</li>
812
<li>Changed preferred way of dealing with the daemon's request loop to <code>requestLoop</code>, instead of
813
<code>handleRequests</code> (Don't worry, the latter still exists!). Updated most examples.</li>
815
<li>Fixed ^C handling of chatbox examples.</li>
817
<li>Fixed bug when both compression and checksumming were enabled.</li>
819
<li>Setup script should work again under Win98, also, entering no path for the location for the script files takes
820
the distutils default path.</li>
822
<li>Fixed old bug in pyroc generated proxy code (method names for remote attribute access were wrong)</li>
824
<li>Added agent docs on module dependencies: imports of other unknown modules don't work in agents.</li>
825
</ul>2.8 was the latest Pyro version in the 2.X series. Development continued with Pyro 3.0.
830
<td align="left"><a href="11-services.html"><previous</a> | <a href="PyroManual.html">contents</a></td>
832
<td align="right">Pyro Manual</td>