A predicted capacity issue could be a valid reason if the passenger was likely to still be using the lounge when it gets busy
CX's flight ORD-HKG departs at 15:30
BA's flights ORD-LHR depart at 17:15 and 20:35
Given that the OP would likely be leaving the lounge somewhere between 14:45 and 15:00 , I would doubt that the lounge would likely have capacity issues over 2 hours before BA's 1st departure
I think that this looks like a v poor action by the agent and that the person should have been allowed entry
If the passenger's departure had been close to , or after, the 1st BA service, then projected capacity issues could be a valid reason, but this would seem not to be the case