Return to CIMExportRequestDispatcher.cpp CVS log | Up to [Pegasus] / pegasus / src / Pegasus / ExportServer |
File: [Pegasus] / pegasus / src / Pegasus / ExportServer / CIMExportRequestDispatcher.cpp
(download)
Revision: 1.43, Wed Oct 11 20:03:44 2006 UTC (17 years, 8 months ago) by carolann.graves Branch: MAIN CVS Tags: TASK-TASK-BUG4011_WinLocalConnect-branch-New-root, TASK-TASK-BUG4011_WinLocalConnect-branch-New-merged_out_to_branch, TASK-TASK-BUG4011_WinLocalConnect-branch-New-merged_out_from_trunk, TASK-TASK-BUG4011_WinLocalConnect-branch-New-merged_in_to_trunk, TASK-TASK-BUG4011_WinLocalConnect-branch-New-merged_in_from_branch, TASK-TASK-BUG4011_WinLocalConnect-branch-New-branch, TASK-PEP268_SSLClientCertificatePropagation-root, TASK-PEP268_SSLClientCertificatePropagation-merged_out_to_branch, TASK-PEP268_SSLClientCertificatePropagation-merged_out_from_trunk, TASK-PEP268_SSLClientCertificatePropagation-merged_in_to_trunk, TASK-PEP268_SSLClientCertificatePropagation-merged_in_from_branch, TASK-PEP268_SSLClientCertificatePropagation-branch, TASK-PEP267_SLPReregistrationSupport-merging_out_from_trunk, TASK-Bugs5690_3913_RemoteCMPI-root, TASK-Bugs5690_3913_RemoteCMPI-merged_out_to_branch, TASK-Bugs5690_3913_RemoteCMPI-merged_out_from_trunk, TASK-Bugs5690_3913_RemoteCMPI-merged_in_to_trunk, TASK-Bugs5690_3913_RemoteCMPI-merged_in_from_branch, TASK-Bugs5690_3913_RemoteCMPI-branch, TASK-Bug2102_RCMPIWindows-root, TASK-Bug2102_RCMPIWindows-merged_out_to_branch, TASK-Bug2102_RCMPIWindows-merged_out_from_trunk, TASK-Bug2102_RCMPIWindows-merged_in_to_trunk, TASK-Bug2102_RCMPIWindows-merged_in_from_branch, TASK-Bug2102_RCMPIWindows-branch, TASK-Bug2021_RemoteCMPIonWindows-root, TASK-Bug2021_RemoteCMPIonWindows-merged_out_to_branch, TASK-Bug2021_RemoteCMPIonWindows-merged_out_from_trunk, TASK-Bug2021_RemoteCMPIonWindows-merged_in_to_trunk, TASK-Bug2021_RemoteCMPIonWindows-merged_in_from_branch, TASK-Bug2021_RemoteCMPIonWindows-branch, TASK-Bug2021_RCMPIonWindows-root, TASK-Bug2021_RCMPIonWindows-merged_out_to_branch, TASK-Bug2021_RCMPIonWindows-merged_out_from_trunk, TASK-Bug2021_RCMPIonWindows-merged_in_to_trunk, TASK-Bug2021_RCMPIonWindows-merged_in_from_branch, TASK-Bug2021_RCMPIonWindows-branch, TASK-BUG4011_WinLocalConnect-branch-New, RELEASE_2_6_0-RC1, RELEASE_2_6_0-FC, RELEASE_2_6_0, RELEASE_2_6-root, PEP286_PRIVILEGE_SEPARATION_ROOT, PEP286_PRIVILEGE_SEPARATION_CODE_FREEZE, PEP286_PRIVILEGE_SEPARATION_BRANCH, PEP286_PRIVILEGE_SEPARATION_1 Branch point for: RELEASE_2_6-branch Changes since 1.42: +1 -19 lines BUG#: 5677 TITLE: Unused CIMExportRequestDispatcher(Boolean, Boolean, Boolean) constructor should be removed DESCRIPTION: Removed unused constructor and private members. |
//%2006//////////////////////////////////////////////////////////////////////// // // Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development // Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems. // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.; // IBM Corp.; EMC Corporation, The Open Group. // Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.; // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group. // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.; // EMC Corporation; VERITAS Software Corporation; The Open Group. // Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.; // EMC Corporation; Symantec Corporation; The Open Group. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to // deal in the Software without restriction, including without limitation the // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or // sell copies of the Software, and to permit persons to whom the Software is // furnished to do so, subject to the following conditions: // // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // //============================================================================== // //%///////////////////////////////////////////////////////////////////////////// #include <Pegasus/Common/Config.h> #include <Pegasus/Common/PegasusVersion.h> #include <Pegasus/Common/Tracer.h> #include <Pegasus/Server/CIMOperationRequestDispatcher.h> #include "CIMExportRequestDispatcher.h" PEGASUS_USING_STD; PEGASUS_NAMESPACE_BEGIN CIMExportRequestDispatcher::CIMExportRequestDispatcher() : Base(PEGASUS_QUEUENAME_EXPORTREQDISPATCHER) { PEG_METHOD_ENTER(TRC_EXP_REQUEST_DISP, "CIMExportRequestDispatcher::CIMExportRequestDispatcher"); PEG_METHOD_EXIT(); } CIMExportRequestDispatcher::~CIMExportRequestDispatcher() { PEG_METHOD_ENTER(TRC_EXP_REQUEST_DISP, "CIMExportRequestDispatcher::~CIMExportRequestDispatcher"); PEG_METHOD_EXIT(); } void CIMExportRequestDispatcher::_handle_async_request(AsyncRequest *req) { PEG_METHOD_ENTER(TRC_EXP_REQUEST_DISP, "CIMExportRequestDispatcher::_handle_async_request"); PEGASUS_ASSERT(req != 0 && req->op != 0 ); if ( req->getType() == async_messages::CIMSERVICE_STOP ) { req->op->processing(); handle_CimServiceStop(static_cast<CimServiceStop *>(req)); } else if ( req->getType() == async_messages::ASYNC_LEGACY_OP_START ) { req->op->processing(); Message *legacy = (static_cast<AsyncLegacyOperationStart *>(req)->get_action()); if (legacy->getType() == CIM_EXPORT_INDICATION_REQUEST_MESSAGE) { Message* legacy_response = _handleExportIndicationRequest( (CIMExportIndicationRequestMessage*) legacy); AsyncLegacyOperationResult *async_result = new AsyncLegacyOperationResult( req->op, legacy_response); _complete_op_node(req->op, ASYNC_OPSTATE_COMPLETE, 0, 0); delete legacy; } else { Tracer::trace(TRC_DISCARDED_DATA, Tracer::LEVEL2, "CIMExportRequestDispatcher::_handle_async_request got " "unexpected legacy message type '%u'", legacy->getType()); _make_response(req, async_results::CIM_NAK); delete legacy; } } else { Base::_handle_async_request(req); } PEG_METHOD_EXIT(); } void CIMExportRequestDispatcher::handleEnqueue(Message* message) { PEG_METHOD_ENTER(TRC_EXP_REQUEST_DISP, "CIMExportRequestDispatcher::handleEnqueue"); PEGASUS_ASSERT(message != 0); switch (message->getType()) { case CIM_EXPORT_INDICATION_REQUEST_MESSAGE: { CIMExportIndicationResponseMessage* response = _handleExportIndicationRequest( (CIMExportIndicationRequestMessage*) message); Tracer::trace( TRC_HTTP, Tracer::LEVEL3, "_CIMExportRequestDispatcher::handleEnqueue(message) - message->getCloseConnect() returned %d", message->getCloseConnect()); response->setCloseConnect(message->getCloseConnect()); SendForget(response); break; } default: PEGASUS_ASSERT(0); break; } delete message; PEG_METHOD_EXIT(); } void CIMExportRequestDispatcher::handleEnqueue() { PEG_METHOD_ENTER(TRC_EXP_REQUEST_DISP, "CIMExportRequestDispatcher::handleEnqueue"); Message *message = dequeue(); if(message) handleEnqueue(message); PEG_METHOD_EXIT(); } CIMExportIndicationResponseMessage* CIMExportRequestDispatcher::_handleExportIndicationRequest( CIMExportIndicationRequestMessage* request) { PEG_METHOD_ENTER(TRC_EXP_REQUEST_DISP, "CIMExportRequestDispatcher::_handleExportIndicationRequest"); OperationContext context; CIMException cimException; Array<Uint32> serviceIds; find_services(PEGASUS_QUEUENAME_PROVIDERMANAGER_CPP, 0, 0, &serviceIds); PEGASUS_ASSERT(serviceIds.size() != 0); AsyncOpNode * op = this->get_op(); AsyncLegacyOperationStart * asyncRequest = new AsyncLegacyOperationStart( op, serviceIds[0], new CIMExportIndicationRequestMessage(*request), this->getQueueId()); asyncRequest->dest = serviceIds[0]; //SendAsync(op, // serviceIds[0], // CIMExportRequestDispatcher::_forwardRequestCallback, // this, // (void *)request->queueIds.top()); AsyncReply *asyncReply = SendWait(asyncRequest); CIMExportIndicationResponseMessage* response = reinterpret_cast<CIMExportIndicationResponseMessage *>( (static_cast<AsyncLegacyOperationResult *>( asyncReply))->get_result()); response->dest = request->queueIds.top(); delete asyncReply; // Recipient deletes request op->release(); this->return_op(op); PEG_METHOD_EXIT(); return response; } PEGASUS_NAMESPACE_END
No CVS admin address has been configured |
Powered by ViewCVS 0.9.2 |