Skip to content

Commit 2a6389e

Browse files
author
Kevin Yang
committed
Removed some experimentation code
1 parent 8928d7d commit 2a6389e

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

clocks.py

+5-8
Original file line numberDiff line numberDiff line change
@@ -155,14 +155,11 @@ def machine_operate(server, port_nums, clock_rate, m_id, upper_random_num, tot_t
155155
server2 = MessageServer('localhost', port_nums[1], Queue(), threading.Lock())
156156
server3 = MessageServer('localhost', port_nums[2], Queue(), threading.Lock())
157157

158-
# # Get all the machines to process queues
159-
# Process(target=machine_operate, args=(server1, port_nums, random.randint(1, 6), 1)).start()
160-
# Process(target=machine_operate, args=(server2, port_nums, random.randint(1, 6), 2)).start()
161-
# Process(target=machine_operate, args=(server3, port_nums, random.randint(1, 6), 3)).start()
162-
Process(target=machine_operate, args=(server1, port_nums, 1, 1, upper_random_num)).start()
163-
Process(target=machine_operate, args=(server2, port_nums, 3, 2, upper_random_num)).start()
164-
Process(target=machine_operate, args=(server3, port_nums, 6, 3, upper_random_num)).start()
165-
158+
# Get all the machines to process queues
159+
Process(target=machine_operate, args=(server1, port_nums, random.randint(1, 6), 1, upper_random_num)).start()
160+
Process(target=machine_operate, args=(server2, port_nums, random.randint(1, 6), 2, upper_random_num)).start()
161+
Process(target=machine_operate, args=(server3, port_nums, random.randint(1, 6), 3, upper_random_num)).start()
162+
166163
time.sleep(60)
167164

168165
server1.close()

0 commit comments

Comments
 (0)