Singapore flew non-stop Newark – Singapore as the longest flight in the world onboard an Airbus A340-500. They also flew Los Angeles – Singapore non-stop, and Thai Airways flew New York JFK – Bangkok using that plane type.
The Singapore Airlines ultra-long haul flights were originally operated in two cabin configuration, and changed to all business class service. The goal was selling fewer seats at a significant premium. The economics didn’t work.
The A340-500 was more or less a flying gas can. And carrying so much fuel for such a long distance means carrying more fuel to handle the weight of that fuel. As the price of avgas rose, operating costs of the plane became worse and worse. Eventually all three of those flights came to and end.