JAL contracts the Marhaba Lounge for their MEL flight. While JAL pax can use the QF lounges based on oneworld rules, the QF lounges aren't the JAL lounges for that flight.
The QF F lounge closes at 2315. The J lounge closes at 0015. JL774 departs at 0005.
These times are already longer then the last QF T2 departure at 2055 with just QF codeshares on EK, FJ and MU departing later. The FJ flight is the last one at 2335.
Prior to the 787 QF9 changes, the lounge closed shortly after QF9 (A380 to DXB/LHR) was called for boarding around 2300.
The CX lounge opens around 3 hours before their first flight (0730 departure), closes at 1400 when their 2nd flight closes (1420 departure) and reopens at 2030 for their last flight (2345 departure), closing shortly after that flight is called.
Provided the JL flight isn't delayed and the QF F lounge closes at the time listed on their website, there would only be about 10 minutes between the lounge closing and the flight boarding.