160 likes | 266 Views
Lessons in Messaging. Steven P. Reiss Brown University. Our Experiences. FIELD Tool integration using messaging Information pipelines Desert Cooperative programming ToolTalk integration Tango Interesting events Other. Lessons Learned. Performance Multiple Servers Server Integration
E N D
Lessons in Messaging Steven P. Reiss Brown University
Our Experiences • FIELD • Tool integration using messaging • Information pipelines • Desert • Cooperative programming • ToolTalk integration • Tango • Interesting events • Other Lessons In Messaging
Lessons Learned • Performance • Multiple Servers • Server Integration • References • Message Processing • Message Mapping • Message Services • Message Formats Lessons In Messaging
Performance • Volume of Messages • Depends on application • TCP/IP locally > 1000 / second • Some apps require more bandwidth • Normal communication much less • Size of Messages • Large messages are problematic • Message size not predictable • Pass file handle • Server/client option • Removing the file is a problem Lessons In Messaging
Multiple Servers • Causes • Multiple programming sessions • Might want to switch in the middle • Might want a common server • Group versus Local Communication • Multiple applications (debugging) • Effects • Need to identify server Lessons In Messaging
Multiple Servers • Message groups (DEC) • Single physical, multiple logical servers • Good for local operations • Multiple Physical Servers • Separate local and global messages • Separate unrelated applications • Notes • How does tool find the proper server • Current working directory Lessons In Messaging
Server Integration • Multiple servers in one application • Different message busses • Global/local communication • Servers need to communicate • Translate messages (between busses) • Filter messages (global local) • Best done with separate tools • TINT in Desert • GroupTool in FIELD Lessons In Messaging
References • Object References • Files, functions, locations, variables, … • Problems • Filenames: relative names, links • Functions: mangling, overloading • Locations: lines|functions; editing • Variables: scope for lookup • Solutions • Develop and adhere to standards • Worry about this early on Lessons In Messaging
Message Processing • Issues • Messages needing replies • Calls versus callbacks • Synchronous versus asynchronous • When to respond w/ broadcasting • Nested message processing • Actually is required • Debugger -> Editor (new file) -> Debugger • Debugger (update) -> DSView -> Debugger • But is generally not desirable Lessons In Messaging
Message Processing • Synchronous versus asynchronous • FIELD/Desert provide both • Use synchronous for convenience • Use asynchronous for complex msgs • Message queuing • Implicitly queue messages while processing others • Allow explicit release of queued messages Lessons In Messaging
Message Mapping • Message conventions are difficult • Tools should be independent • Separate message accepted and sent • Message mapping works well • Each tool defines its own I/O messages • File specifies input->output mappings • Forest/Mediators/FIELD Policy • Desert MSGMAP tool heavily used • Outside or inside message server Lessons In Messaging
Message Services • Some tools act as servers • Only one instance running • Should start automatically • Should exit automatically • Best done through message server • Can keep track of users • Create at first request for service • Send message when all users exit • Used extensively in FIELD/DESERT Lessons In Messaging
Message Formats • Structured versus unstructured • Strings versus records • Strings offer more flexibility • Decoding formats do checking • Same strings used for selectivity • Easy to add new information to • Easy to send and debug • No byte-order problems • Easy to trace, compose messages, etc. • Easier to add new tools Lessons In Messaging
Wide Area Messaging • Performance • Utility depends on number of messages • (100000,1000,10,1)/second • Handle all size messages • Multiple Servers • Allow multiple servers (logical or physical) • Server Integration • Provide interconnections to local servers Lessons In Messaging
Wide Area Messaging • References • Develop vocabulary for applications • Standards are part of the specifications • Message Processing • Develop scheme for nested processing • Make it easy to use • Message Mapping • Provide hooks/facilities for mapping Lessons In Messaging
Wide Area Messaging • Message Services • Provide service facilities • Provide server/client frameworks • Message Formats • Choose extensible and flexible formats • Make them easy to change Lessons In Messaging