// // Copyright (C) 2007 Institut fuer Telematik, Universitaet Karlsruhe (TH) // // This program is free software; you can redistribute it and/or // modify it under the terms of the GNU General Public License // as published by the Free Software Foundation; either version 2 // of the License, or (at your option) any later version. // // This program is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with this program; if not, write to the Free Software // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // // // The main module of the Broose implementation // // @author Jochen Schenk // simple Broose parameters: keyLength : numeric, // overlay key length localPort: numeric, // port on which the node is listening debugOutput: bool, // write debug information? collectPerHopDelay : bool, // delay statistics for single hops joinOnApplicationRequest : bool, // only join the overlay on application request useCommonAPIforward : bool, // enable CommonAPI forward() calls routeMsgAcks : bool, // use RPCs for route messages recNumRedundantNodes : numeric, // numRedundantNodes for recursive routing routingType : string, // default routing mode (iterative, semi-recursive,...) lookupRedundantNodes : numeric, // number of next hops in each step lookupParallelPaths : numeric, // number of parallel paths lookupParallelRpcs : numeric, // number of nodes to ask in parallel lookupSecure : bool, // true, if all nodes should be identified with a ping lookupMerge : bool, // true, if parallel Rpc results should be merged lookupStrictParallelRpcs: bool, // limited the number of concurrent rpcs to parameter parallelRpcs lookupUseAllParallelResponses: bool, // merge all parallel responses from earlier steps lookupNewRpcOnEveryTimeout: bool, // send a new RPC immediately after an RPC timeouts lookupNewRpcOnEveryResponse: bool, // send a new RPC after every response, even if there was no progress lookupFinishOnFirstUnchanged: bool, // finish lookup, if the last pending RPC returned without progress lookupFailedNodeRpcs : bool, // communicate failed Nodes hopCountMax: numeric, // maximum hops for a lookup drawOverlayTopology: bool, // draw arrow to successor node? bucketSize: numeric, // number of nodes a bucket contains rBucketSize: numeric, // number of nodes a right-bucket contains joinDelay: numeric, // time to wait to join the overlay after simulation start brooseShiftingBits: numeric, // number of bits shifted in/out each step userDist: numeric, // number of hops that are added to the estimated hop count refreshTime: numeric, // time interval between two pings pingDelay: numeric, // time interval between bucket refreshs numberRetries: numeric, // number of retries in case of timeout parallelRequests: numeric; // number ob parallel requests gates: in: from_udp[]; // gate from the UDP layer out: to_udp[]; // gate to the UDP layer in: from_app; // gate from the application out: to_app; // gate to the application in: direct_in; // gate for sendDirect endsimple // // This modul contains the buckets of the Broose implementation. // // @author Jochen Schenk // simple BrooseBucket endsimple // // Implementation of the Broose overlay as described in // "Broose: A Practical Distributed Hashtable based on the // De-Bruijn Topology" by A. Gai and L. Viennot, published in // "Technical report, INRIA, june 2004" // // @author Jochen Schenk // module BrooseModules parameters: brooseShiftingBits : numeric; // number of bits shifted in/out each step gates: in: from_udp; // gate from the UDP layer out: to_udp; // gate to the UDP layer in: from_app; // gate from the application out: to_app; // gate to the application submodules: rBucket : BrooseBucket[2^brooseShiftingBits]; display: "i=block/table"; lBucket : BrooseBucket; display: "p=360,60;i=block/table"; bBucket : BrooseBucket; display: "p=420,60;i=block/table"; broose: Broose; parameters: brooseShiftingBits = brooseShiftingBits; display: "p=60,60;i=block/circle"; connections nocheck: from_udp --> broose.from_udp++; to_udp <-- broose.to_udp++; from_app --> broose.from_app; to_app <-- broose.to_app; endmodule