Computer-Aided Manufacturing using XML (CAMX) production systems are built on Message-Oriented Middleware Frameworks, offering standards-based communication among machines and control software applications. CAMX Frameworks implement Publish/ Subscribe of XML messages through an entity called the Message Broker (MSB), which provides the messaging service using a Simple Object Access Protocol (SOAP) interface. In order to create scalable frameworks, distributed MSB systems are deployed. However, the topology optimization problem arises, as clients need to be assigned to one of many MSB nodes. The problem is strictly NP-hard, and multiple optimization criteria are conflicting. A solution considering real-time systems was developed based on Evolutionary MultiObjective Optimization techniques. The Framework Optimization Algorithm (FOA) is designed to work with various topologies, including federated frameworks, locally distributed clusters, and mixed environments including embedded middleware nodes. The developed FOA was tested for a case scenario based on a flexible manufacturing system running on a distributed CAMX framework, and proved to robustly converge to the optimal topology. Convergence was achieved within few seconds, demonstrating the suitability of FOA for rapid topology reconfiguration in response to changes in the system. r 2006 Elsevier Ltd. All rights reserved.