VirtualBox

Changeset 26450 in vbox for trunk/src/VBox/Main


Ignore:
Timestamp:
Feb 11, 2010 6:19:11 PM (15 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
57597
Message:

Webservice: enable separate SOAP queue thread; fix logging

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/webservice/vboxweb.cpp

    r26447 r26450  
    6060// include generated namespaces table
    6161#include "vboxwebsrv.nsmap"
    62 
    63 // If this is defined, then thread 1 ONLY performs COM event queue processing
    64 // (using RT_INDEFINITE_WAIT to wait for events), and the SOAP queue is processed
    65 // on a separate thread. This appears to be broken
    66 // as soon as more than one client fires SOAP events at the webservices.
    67 // If this is NOT defined, then COM events are only serviced after SOAP event
    68 // processing has completed, and both occur on thread 1.
    69 
    70 // #define TEMP_USE_BROKEN_XPCOM_EVENTQUEUE_PROCESSING
    7162
    7263/****************************************************************************
     
    429420
    430421        WebLog("Processing connection from IP=%lu.%lu.%lu.%lu socket=%d (%d out of %d threads idle)\n",
    431                m_u,
    432422               (m_soap->ip >> 24) & 0xFF,
    433423               (m_soap->ip >> 16) & 0xFF,
     
    551541            size_t cItemsOnQ = g_pSoapQ->add(s);
    552542            WebLog("Request %llu on socket %d queued for processing (%d items on Q)\n", i, s, cItemsOnQ);
    553 
    554 #ifndef TEMP_USE_BROKEN_XPCOM_EVENTQUEUE_PROCESSING
    555             // process the COM event Q
    556             int vrc = com::EventQueue::getMainEventQueue()->processEventQueue(0);
    557 #endif
    558543        }
    559544    }
     
    561546}
    562547
    563 #ifdef TEMP_USE_BROKEN_XPCOM_EVENTQUEUE_PROCESSING
    564548/**
    565549 * Thread function for the "queue pumper" thread started from main(). This implements
     
    576560    return 0;
    577561}
    578 #endif
    579562
    580563/**
     
    731714    g_pSessionsLockHandle = new util::RWLockHandle(util::LOCKCLASS_OBJECTSTATE);
    732715
    733 #ifdef TEMP_USE_BROKEN_XPCOM_EVENTQUEUE_PROCESSING
    734716    // SOAP queue pumper thread
    735717    RTTHREAD  tQPumper;
     
    745727        exit(1);
    746728    }
    747 #endif
    748729
    749730    // watchdog thread
     
    765746    }
    766747
    767 #ifdef TEMP_USE_BROKEN_XPCOM_EVENTQUEUE_PROCESSING
    768748    com::EventQueue *pQ = com::EventQueue::getMainEventQueue();
    769749    while (1)
    770750    {
    771751        // we have to process main event queue
    772         WebLog("Pumping COM event queue\n");
     752        WEBDEBUG(("Pumping COM event queue\n"));
    773753        int vrc = pQ->processEventQueue(RT_INDEFINITE_WAIT);
    774754        if (FAILED(vrc))
    775755            com::GluePrintRCMessage(vrc);
    776756    }
    777 #else
    778     doQueuesLoop();
    779 #endif
    780757
    781758    com::Shutdown();
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette