Index: TODO =================================================================== diff -u -rccb2c99f6fb6f381dfc7e300584ac08e3d2809d3 -r6ad766595b0095a72fb7b3a1d6d34960a013b464 --- TODO (.../TODO) (revision ccb2c99f6fb6f381dfc7e300584ac08e3d2809d3) +++ TODO (.../TODO) (revision 6ad766595b0095a72fb7b3a1d6d34960a013b464) @@ -4809,12 +4809,318 @@ - make use of nsf::object::alloc (1 command instead of 1 create + 2 evals) - these changes imprived laading time of blueprint by about 25% for OpenACS+xowiki +- don't rely on the existence of a "trace" method +nsf.c: +- when ::nsf::object::alloc is passed an empty name (2nd argument), + behave like "new" method + +nx: +- allow copy of objects with required arguments +- use ::nsf::object::alloc in "copy" method +- don't depend on method "trace", use directdispatch instead +- remove method "-noinit" (nsf::object::alloc makes it obsolete) +- extend regression test + +serializer: +- restore traces after object-serialize + +nsf.c: +- fix stub provisioning for Tcl 8.6 +- reduce verbosity for FreeUnsetTraceVariable +- return TCL_OK, even when FreeUnsetTraceVariable() fails (warning stays) + +nx-mongo: +- implement simple persistent handle management based on per-thread objects + +-nsf.c: +- fix bug in interaction between uplevel method and interceptor transparency +- fix bug in interaction between uplevel method from tcl procs +- extend regression test + +build-system: +- provide datarootdir to get rid of warning during configure + +nx-mongo: +- updated documentation (switch back to mongo-c-driver, but comment usage + of tagged version v0.8.1) +- added support for rep types (allow for mappings between certain instance + variables such as arrays or dicts to customizable representations in + MongoDB) +- added nx-serialize to test cases (simple state persistance for nx objects) +- added nx-rep to test cases (rep types for "array" and "dict") +- improve performance of mongo->tcl conversion by using predefined global strings + +nx-monogo: +- Updated the mongo-c-driver and libbson to the actual tip version from github + (this is a significant change, since 10gen essentially changed the + officially supported c-driver of MongoDB) +- mongo-c-driver was more or less new-implementation, since strucure and + names changed in the mongo-c-driver substantially, serveral functions + were added, several were dropped. The new interface supports now + e.g. mongo URIs, and should be faster (by using collection objects + instead of connection handles) +- Although the low-level nsf interface changed significantly, the high level + (nx level) interface remained unaffected. +- Configure has now --with-mongoc=... and --with-bson instead of --with-mongodb +- New commands: + mongo::collection::open /mongoConn/ /dbName/ /collectionName/ + mongo::collection::close /collection/ + mongo::gridfs::store_string /content/ /name/ /contentType/ +- Make use of the new collection handle + mongo::count /mongoConn/ /ns/ ... -> mongo::collection::count /collection/ ... + mongo::index /mongoConn/ /ns/ ... -> mongo::collection::index /collection/ ... + mongo::insert /mongoConn/ /ns/ ... -> mongo::collection::insert /collection/ ... + mongo::query /mongoConn/ /ns/ ... -> mongo::collection::query /collection/ ... + mongo::remove /mongoConn/ /ns/ ... -> mongo::collection::delete /collection/ ... + mongo::update /mongoConn/ /ns/ ... -> mongo::collection::update /collection/ ... + mongo::cursor::find /mongoConn/ /ns/ ... -> mongo::cursor::find /collection/ ... +- nsf::mongo::connect receives now a mongoc_uri + https://github.com/mongodb/mongo-c-driver/blob/master/doc/mongoc_uri.txt +- The gridfs interface allows now to store multiple revisions of a file +- The gridfs interface allows now upload files from a string +- The gridfs interface allows to refer to files by other attributes than + just the filename (e.g. the mongo id). +- Modified/new gridfile functions + mongo::gridfile::create ?-source file|string? /gridfs/ /value/ /name/ /contentType/ + mongo::gridfile::delete /gridfs/ /query/ + mongo::gridfile::open /gridfs/ /query/ +- Updated README +- Updated regression test +- Added editor hints for a more uniform appearance + +nsf.c: +- change name of enumeratorConverterEntry to Nsf_EnumeratorConverterEntry, + move it with NSF_ARG_* flags to tcl.h to make it available in derived + modules using the converter +- Added editor hints for a more uniform appearance + +nx.tcl: +- raise an error, when an ensemble methods redefined a plain method + +nsf.c: +- fix small memory leak in multiple inheritance code. +- all regression tests reun cleanly with --enable-memcount=yes +- let [current methodpath] return full path (similar to -path option + in "info methods" +- handle collateral damage in regression test due to changed result + of "current methodpath" + +nx::traits: +- handle ensemble methods correctly (use full method path for resolution) +- add new regression tests for traits + +nx-mongo: +- optional support for mongodb connection pools (compile time macro + USE_CLIENT_POOL controls this, per default, this is on) +- allow to pass "-metadata" to gridfile::create to ease metadata attachment + to gridfiles +- some conveniance improvements in nx-mongo.tcl (ability to ignore + attributes in "bson encode", ability to unset attributes in gridfs, ...) +- bump version numbers of nsfmongo to 0.3 and nx-monogo to 0.5 +- represent BSON_TYPE_REGEX as pairs (regex + options) in the Tcl + representation to preserve regular expression options +- update to newest version of mongo-c-driver and libbson from github +- tested with mongodb-c-driver 0.93.0 + +nx-mongo: +- fixed suprising compiler message + "alignment of array elements is greater than element size" + when using e.g. "bson_iter_t i[1]" +- some c-code cleanup +- tested with mongodb-c-driver 0.92.3 +- added mongo::collection::stats +- added mongo::cursor::aggregate +- extended regression test + +nsf.c: +- fix case, where NsfDStringPrintf() failed (when print llength including + \0 was 1 byte longer than print buffer) +- make sure, that the list kept for the cached parameter is just built + from unshared objects; otherwise Tcl append will abort + +nx.tcl: +- new package "nx::volatile" +- don't define configure parameter "-volatile" per default; + use "package req nx::volatile" instead +- don't define per method "volatile" per default; + use "::nsf::method::require ::nx::Object volatile" instead +- get rid of -volatile in nx.tcl and serializer +- updated/extened regression test + +nx-mongo: +- added command "::mongo::status /mongoConn/" +- extended regression test + +nsf.c: +- invalidate paramter caches of subclasses on + NsfParameterInvalidateClassCacheCmd unless during + shutdown. Otherwise some classes might not become aware of + properties added later to superclasses. +- extend regression test + +nsf.c: +- remove redundant NULL tests +- improve safety mof macro ObjStr() + +build-process: +- replace make.tcl by the much simpler mkIndex.tcl: + * Does not use pkg_mkIndex + * Does not load binary files (problem for cross compiling) + * Requires package provide with constant in one line. + +small introspection reform: +- Introspection for commands and arguments did not work for + cmds defined in subpackages (such as mongodb). We keep + now this information in hashtables and maintain a slim + interface for this. +- fix generation of pkgIndex.tcl for mongodb + +Configuration: +- stick closer to TEA conventions (keep tclconfig-sh in tclconfig directory) +- remove obsolete version of install-sh, copy manifested version to + mongodb library +- fix configure.ac quoting + +forwarders: +- RFE "provide %method" as keyword like %proc" + was already implemented. Dropping %proc would break XOTcl2 + compatibility. +- adding a test case +- use for output of forward ... -verbose NsfLog(...NSF_LOG_NOTICE...) + instead of fprintf() to make it redirect-able +- use in forwarders "-frame object" instead of "-objframe" in nx + for consistency with other calls (e.g. dispatch). Other values for + "-frame" are not allowed. (btw, XOTcl has "-objscope") +- deactivated "-onerror", since its semantics are expressible via + try/catch, and there are no regression tests for xotcl and nx, + and we could not find any script that uses this +- renamed "-methodprefix" to "-prefix" in nx, since the prefix + can be applied as well applied to a cmd. +- use nx rather than xotcl2 terminology in nsf::method::forward + +nsf.c: +- de-spaghetti precedence computations for multiple inheritance and + improve documentation +- get rid of // comments +- use nonnull variable attributes for prototpyes (nsf.h, nsfInt.h, nsf.c) +- add returns_nonnull assertion +- simplify few inner code pieces based on assertions +- add serveral more assertions based on nonnull sepcifications. +- made nsf::is using the "-strict" option when tcl's "string is" is called. +- let the c-code generator produce as well nonnull assertions +- simplify FilterInvalidateObjOrders() and FilterRemoveDependentFilterCmds() +- simplify SuperclassAdd() +- improve code documentation + +nx.tcl: +- Define method "value" as a slot forwarder to allow for calling + value-less slot methods like e.g. "get" dispite of the arity-based + forward dispatcher. +- extend regression test +- added more test cases for multiplicity and incremental +- preserve lower bound of multiplicity when incemental is added +- added log-level Info which prints always, e.g. for "-verbose" flag + of forwarder + + +nsf.c: + - add flag "-onerror" to nsf::forward::method to handle errors during + dispatch of a forwarder (not all error messags of forwarder are + already transformed) + - added log-level Info which prints always, e.g. for "-verbose" flag + of forwarder + - drop setter-rule from properties (use always forwarder) + - drop "/obj/ /prop/" and "/obj/ /prop/ /value/" in favor of + "/obj/ /prop/ get" and "/obj/ /prop/ set /value/" + to achieve better orthogonality with e.g. incremental properties + - allow parameter option "method=" for slotassign as well. rationale: + this allows to use the parameter "forwardername" to specify a + different forwarder target method (e.g. in case of object-mixins). + The method is used both in "configure" and "cget". + - allow methodname to consist of max two words in relation slots + (e.g. "-methodname {mixin set}"} + - allow configuration of internally called "slot.get" and + "slot.assign" methods via objectsystem::create + - rename default slot methods add/get to value=add/value=get + - provide an error message, when refering to a non-existing slot object + - added likely/unlikely to result == TCL_OK etc. + - fix one more subtle case of an error being swallowed: for xotcl, the + constructor returns the list of residual arguments. In case there + was an error, it was possible that the returned residual arguments + overwrote the error message in the interp result + - finish implementation of NsfForwardPrintError() + - use NsfForwardPrintError() in ForwardArg() for all error messages + + +nx.tcl: + - replace empty-named arrays by dicts + - remove setter methods from BootstrapVariableSlots + - reducing interface of BootstrapVariableSlots by setting methods protected + - use value=* as names for interally called and forwarder-called + accessor methods + - enforce using "set" for filter/object-filter in slot operations + (same as for mixins) + - add "set" as a method name for relation slots + - implemented relation slot "mixin" and "object-mixin" via "slotassign" to disallow + "/obj/ mixin /value/" and "/obj/ object mixin /value/" to use instead + "/obj/ mixin set /value/" and "/obj/ object mixin set /value/" + while keeping "configure" and "cget" working. + This has the advantage that "/obj/ mixin set" does not try + to replace the mixin chain by "set" + - disallow "assign" for nx::variableSlots + - use set/get/add as slot methods for get/configure/incremental + operations + - demangle slots for nx/xotcl2 further + - enforce usage of "get" for all slots in nx + - put test cases for all kind of mix setter / getter together in one test case + +xotcl2.tcl: + - use object system configuration for -slot.get and -slot.set + - use value=set instead of value=assign + - simplify "-parameter" implementation + - add setters for "name", "domain", and "default" to xotcl::Attribute + for backward compatibility + +mongodb + - by directing calls to the setter, it is now more complex to + determine the true calling object for an converter, since the + set operation might be routed though the slot object. + It would be nice to have framework support for this. + - fix 2 error messages + - provide shorter tracebacks by using "return -code error ..." rather + than "error ..." + +nx::test: + - don't delete system slot ::xotcl::Attribute on cleanup + +nx.tcl: +- add slot method value=unset to nx::RelationSlot and nx::VariableSlot +- extended regression test +- reworked error message generation of slot-forwarder + (list all available slot methods with prefix value=) +- cleaned up relation slot mixin variants + +xotcl2: +- use xotcl::RelationSlot instead of nx::Relationslot in xotcl2 + (we can more value=assign here). + +Makefile: +- fix load paths for sublibs (e.g. mongodb) in regression test + +nsf.c: +- added nsf::var::get and "::nx::var get" to provide selector + based interface for variable reading (used in slotmethod get + of nx::VariableSlot) ======================================================================== TODO: +- TODO: rename "slotassign" to "slotset"? +- TODO: update tutorial and migration guide -- remove / rephrase "//"-comments +- why is there no pos/index arg for mixin|filter delete? +- finish nx-property reform (merge into master) + - check deactivated tests in tests/serialize.test C(One), C(IgnoreAll), C(None2) and xlloc fix @@ -4980,6 +5286,7 @@ - nicht gewartete/nicht getestete library aus distro entfernen? - migration von einzelnen paketen nach next? von welchen? + Ein paar Punkte im folgenden könnten obsolet sein: TODO "Kleinigkeiten" @@ -5052,8 +5359,51 @@ residual args). We should provide a warning when a user defines arguments for init (or provide some other syntactic sugar) - * extend traits (object-specific traits, test cases, etc.) + * extend traits (object-specific traits, test cases, etc.) + * RFE: forwarders/aliases: -checkalways is missing. + Issues: + 1) limit to -returns only? + + checkalways affects only input-parameters, not return. + (purpose: make it possible to rely on parameter checking + from external sources, no matter whether checking is turned + on/off). furthermore, it effects only checking for procs. + For C-implemented commands, there is no way to avoid e.g. + checking if something is an integer, since the binary + representation of the integer is passed. + + so i don't understand "limit to -returns". + + 2) cover value checkers of method parameters also, + effectively overruling -checkalways settings of the + aliased/forwarded nsf::proc or method? + + i guess that this is based on the assumption, + there would be value-checkers for forwarders + or aliases. Then one would have to handle the + conflicts. However, forwarders and aliases + pass arguments around without having any knowledge + about parameter definitions. They don't check + anything by design. + + * RFE Revisit nsf::*::assertion interface? Why does nsf::method::assertion + allow for setting invariants. One would rather expect a + ::nsf::object|class::assertion or the like? + + The reason for the current naming is simply that assertions + are only implemented for scripted methods. + * pre/post conditions are just checked for scripted methods, + since only these have stack frames, which are necessary + to access self or the resolver variables. + * invariants are only checkable during scripted methods, + there is no way to intercept c-based functions. + Checking these before/after c-implemented functions + should be possible though. + + * REF: feature request 'remove "-guard" from mixin and filter specs, just have two-element lists' + would require to have different sets of converters for slots depending on object system + * add maybe "::nsf::object::property /obj/ volatile 0|1" to alter volatile state.