Index: openacs-4/packages/search/tcl/search-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/search/tcl/search-procs.tcl,v diff -u -r1.21 -r1.22 --- openacs-4/packages/search/tcl/search-procs.tcl 10 Mar 2005 01:42:14 -0000 1.21 +++ openacs-4/packages/search/tcl/search-procs.tcl 17 Mar 2005 08:35:13 -0000 1.22 @@ -24,11 +24,16 @@ @author Jeff Davis (davis@xarg.net) } { - package_exec_plsql \ - -var_list [list \ - [list object_id $object_id] \ - [list event $event] ] \ - search_observer enqueue + if {![empty_string_p $object_id] + && ![empty_string_p $event]} { + package_exec_plsql \ + -var_list [list \ + [list object_id $object_id] \ + [list event $event] ] \ + search_observer enqueue + } else { + ns_log warning "search::queue: invalid: called with object_id=$object_id event=$event\n[ad_print_stack_trace]\n" + } } ad_proc -public search::dequeue { @@ -44,13 +49,20 @@ @author Jeff Davis (davis@xarg.net) } { - package_exec_plsql \ - -var_list [list [list object_id $object_id] \ - [list event_date $event_date] \ - [list event $event] ] \ - search_observer dequeue + if {![empty_string_p $object_id] + && ![empty_string_p $event_date] + && ![empty_string_p $event]} { + package_exec_plsql \ + -var_list [list [list object_id $object_id] \ + [list event_date $event_date] \ + [list event $event] ] \ + search_observer dequeue + } else { + ns_log warning "search::dequeue: invalid: called with object_id=$object_id event_date=$event_date event=$event\n[ad_print_stack_trace]\n" + } } + ad_proc -private search::indexer {} { Search indexer loops over the existing entries in the search_observer_queue table and calls the appropriate driver functions to index, update, or