Modify a bunch of INSERTs to avoid using empty fields
[moodle.git] / search / README.txt
791a4cec 12006/08/21
3Fixed index document count, and created new config variable to store
4the size. (Search now has 3 global vars in $CFG, date, size and complete,
5see indexer.php for var names). Index size is cached to provide an always
6current value for the index - this is to take into account the fact that
7deleted documents are in fact not removed from the index, but instead just
8marked as deleted and not returned in search results. The actual document
9still features in the index, and skews sizes. When the index optimiser is
10completed in ZFS, then these deleted documents will be pruned, thus
11correctly modifying the index size.
13Additional commenting added.
15Query page logic very slightly modified to clean up GET string a bit (removed
16'p' variable).
18Add/delete functions added to other document types.
20A few TODO fields added to source, indicating changes still to come (or at
21least to be considered).
6f1b1da1 232006/08/16
25Add/delete/update cron functions finished - can be called seperately
26or all at once via cron.php.
28Document date field added to index and database summary.
30Some index db functionality abstracted out to indexlib.php - can
31use IndexDBControl class to add/del documents from database, and
32to make sure the db table is functioning.
34DB sql files changed to add some extra fields.
36Default 'simple' query modified to search title and author, as well
37as contents of document, to provide better results for users.
6e780562 392006/08/14
41First revision of the advanced search page completed. Functional,
42but needs a date search field still.
46Added resource search type, and the ability to specify custom 'virtual'
47models to search - allowing for non-module specific information to be
48indexed. Specify the extra search types to use in lib.php.
52Added delete logic to documents; the moodle database log is checked
53and any found delete events are used to remove the referenced documents
54from the database table and search index.
56Added database table name constant to lib.php, must change files using
57the static table name.
59Changed documents to use 'docid' instead of 'id' to reference the moodle
60instance id, since Zend Search adds it's own internal 'id' field. Noticed
61this whilst working on deletions.
63Added some additional fields to the permissions checking method, must still
64implement it though.
b585dc5f 662006/07/25
68Query logic moved into the SearchQuery class in querylib.php. Should be able
69to include this file in any page and run a query against the index (PHP 5
70checks must be added to those pages then, though).
72Index info can be retrieved using IndexInfo class in indexlib.php.
74Abstracted some stuff away, to reduce rendundancy and decrease the
75likelihood of errors. Improved the stats.php page to include some
76diagnostics for adminstrators.
78delete.php skeleton created for removing deleted documents from the
79index. cron.php will contain the logic for running delete.php,
80update.php and eventually add.php.
a25a3912 822006/07/11
84(Warning: It took me 1900 seconds to index the forum, go make coffee
b585dc5f 85whilst you wait.) [ forum data]
a25a3912 86
87Forum search functions changed to use 'get_recordset' instead of
88'get_records', for speed reasons. This provides a significant improvement,
89but indexing is still slow - getting data from the database and Zend's
90tokenising _seem_ to be the prime suspects at the moment.
92/search/tests/ added - index.php can be used to see which modules are
93ready to be included in the search index, and it informs you of any
94errors - should be a prerequisite for indexing.
96Search result pagination added to query.php, will default to 20 until
97an admin page for the search module is written.
101Search-enabling functions moved out've the mod's lib.php files and into
102/search/documents/mod_document.php - this requires the search module to
103operate without requiring modification of lib files.
105SearchDocument base class improved, and the way module documents extend
106it. A custom-data field has been added to allow modules to add any custom
107data they wish to be stored in the index - this field is serialised into
108the index as a binary field.
110Database field 'type' renamed to 'doctype' to match the renaming in the
111index, 'type' seems to be a reserved word in Lucene. Several index field
112names change to be more descriptive (cid -> course_id). URLs are now
113stored in the index, and don't have to be generated on the fly during
114display of query results.
abb4ea20 117------
118Started cleaning and standardising things.
120cvs v1.1
682d4032 122This is the initial release (prototype) of Moodle's new search module -
123so basically watch out for sharp edges.
125The structure has not been finalised, but this is what is working at the
126moment, when I start looking at other content to index, it will most likely
127change. I don't recommend trying to make your own content modules indexable,
128at least not until the whole flow is finalised. I will be implementing the
129functions needed to index all of the default content modules on Moodle, so
130expect that around mid-August.
132Wiki pages were my goal for this release, they can be indexed and searched,
133but not updated or deleted at this stage (was waiting for ZF 0.14 actually).
135I need to check the PostgreSQL sql file, I don't have a PG7 install lying
136around to test on, so the script is untested.
138To index for the first time, login as an admin user and browse to /search/index.php
139or /search/stats.php - there will be a message and a link telling you to go index.
141-- Michael Champanis (mchampan)
6f1b1da1 142 email:
143 skype: mchampan
682d4032 144 Summer of Code 2006