Hello,
first of all, it is probably not a good idea to try and faithfully represent the large system that you are interested in TLA+ (but by and large, this advice also holds for other formal specification languages). You will likely find most benefit in using TLA+ for writing high-level specifications of well-chosen parts of your system: the ones that you suspect most likely to contain errors. In particular, verification with TLC suffers from the state explosion problem, and you will probably not be able to verify a system with 5 queues with reasonable effort.
If you are interested in verifying the behavior of queues in your system, take one queue and write an abstract, non-deterministic description of the processes that communicate over the queue. If you are instead interested in the interaction between processes, take two processes linked by one or two (in case of bidirectional communication) queues and strip down the queue protocol to its bare bones. Because TLC computes the full state graph, it has repeatedly found to be very effective for finding bugs in tiny instances of systems whose implementations would exhibit these bugs only in large configurations. In any case, it is best to start small and coarse, and to add components or refine the grain of atomicity only when TLC cannot find problems in the toy specification. Deciding which aspects of your system warrant writing a formal model is a non-trivial decision that requires engineering judgment. Chapter 7 of "Specifying Systems" has some advice.
Encapsulating parts of a specification in separate modules can make a specification more readable, but since specifications tend to be small, it is less of an issue than in programming. (With few exceptions, TLA+ specifications rarely exceed a couple of hundred lines.) And then, redeclaration of parameters is not a big deal.
Regards,
Stephan
> --
> You received this message because you are subscribed to the Google Groups "tlaplus" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
tlaplus+u...@googlegroups.com.
> To post to this group, send email to
tla...@googlegroups.com.
> Visit this group at
https://groups.google.com/group/tlaplus.
> For more options, visit
https://groups.google.com/d/optout.