Ticket #1296 (closed defect: fixed)

Opened 1 year ago

Last modified 7 months ago

m.h.reflector tries to load a lot of non-existant classes

Reported by: flack Assigned to: bergie
Priority: major Milestone: 8.09.8 Ragnaroek
Component: MidCOM component Version: 8.09 Ragnaroek
Keywords: Cc:

Description

in tree.php line 1126, the following code

    if (class_exists("{$schema_type}_dba"))
    {
        $test_class_name= "{$schema_type}_dba";
        $test_class = new $test_class_name();

        if (   isset($test_class->noasgard)
            && $test_class->noasgard)
        {
            //debug_add("Type {$schema_type} has 'noagsard' property set, thus cannot be root class");
            continue;
        }
    }

causes a lot of noise from autoloader in the debug log:

Aug 13 2009 15:39:43 (00.531046152, 20.033.884,     212):       [debug] Autoloader got '/usr/local/lib/midcom/lib/midgard/style.php' and tried /usr/local/lib/midcom/lib/midgard/style/main.php but neither was not found, aborting                                                     
Aug 13 2009 15:39:43 (00.531286001, 20.034.108,     224):       [debug] Autoloader got '/usr/local/lib/midcom/lib/midgard/page.php' and tried /usr/local/lib/midcom/lib/midgard/page/main.php but neither was not found, aborting                                                       
Aug 13 2009 15:39:43 (00.531494141, 20.034.352,     244):       [debug] Autoloader got '/usr/local/lib/midcom/lib/org/openpsa/event.php' and tried /usr/local/lib/midcom/lib/org/openpsa/event/main.php but neither was not found, aborting                                             
Aug 13 2009 15:39:43 (00.531810045, 20.034.448,      96):       [debug] Autoloader got '/usr/local/lib/midcom/lib/org/openpsa/invoice.php' and tried /usr/local/lib/midcom/lib/org/openpsa/invoice/main.php but neither was not found, aborting                                         
Aug 13 2009 15:39:43 (00.532114029, 20.034.576,     128):       [debug] Autoloader got '/usr/local/lib/midcom/lib/org/openpsa/task.php' and tried /usr/local/lib/midcom/lib/org/openpsa/task/main.php but neither was not found, aborting

If I'm not mistaken, it would be better to do something like

$test_class_name = $_MIDCOM->dbclassloader->get_midcom_class_name_for_mgdschema_object($schema_type);

and then the class_exists test.

Change History

10/20/09 13:53:38 changed by piotras

  • milestone changed from 8.09.6 Ragnaroek to 8.09.7 Ragnaroek.

02/03/10 17:00:21 changed by bergie

  • status changed from new to closed.
  • resolution set to fixed.

This is already fixed.