3 * @author Michal Sojka <sojkam1@fel.cvut.cz>
4 * @date Sat Oct 25 21:57:56 2008
6 * @brief FORB interface of resource manager
13 #include "../contract/fres_contract_idl.idl"
16 /** Resource manager */
17 interface resource_manager {
19 * Executes admission test and if the contracts are
20 * accepted, they are put to "reserved" state.
22 * @todo If a contract is in the "reserved" state, and
23 * reserve_contracts() is called again with the same
24 * contract, the previously reserved contract should
25 * be replaced with the new one.
27 * @param contracts New contracts to be reserved.
30 * - Zero if reservation (admisson test) was successfull,
31 * - one if admission test was not successfull and
32 * - negative error code if an error occured.
34 long reserve_contracts(in contract::ptr_seq contracts);
37 * Puts contracts with given IDs to the "commited"
38 * state and sends back the changes to VRESes to reach
41 * @param[in] ids IDs of contracts to be commited.
43 * @param[out] schedulable_contracts Schedulable
44 * contracts, for new or changed VRESes. These
45 * contract may be extened by one or more data blocks
46 * for use by the scheduler. The scheduler receives
47 * the contracts in the same order as they are
50 void commit_contracts(in contract::id_seq ids,
51 out contract::ptr_seq schedulable_contracts);
52 void cancel_contracts(in contract::id_seq ids);