The city of Brockton has been trying to figure out for more than a decade how best to meet the need for drinking water. And that debate is now playing out in the city's mayoral election, with the candidates disagreeing over whether the city should purchase a nearby desalination plant.

“This is the first stage. Then the water goes to the second stage,” said Linda Correia, the plant manager for the Aquaria Water desalination plant in North Dighton as she gave a tour recently. The plant pulls brackish water from the Taunton River, which is pumped through a series of white tubes here, stacked six across and six high, that have a spiral membrane inside them.

“The water gets pushed under high pressure through the membrane,” she said. That membrane separates out water molecules from everything else, including salt. The newly fresh water can then be pumped through 16 miles of pipes to the city of Brockton – the desalination plant’s only customer.

Brockton’s current mayor, Bill Carpenter, said the plant was built because Brockton was facing a water crisis. “There was a time in this city back in the eighties and nineties where the city actually had a moratorium on building permits and you could not get a water connection," he said. "And it absolutely was prohibiting development, new development in the city.”

So Brockton contracted with the company Aquaria to build a desalination plant — committing the city to pay $6 million a year, just for the right to the water. But by the time the plant opened in 2008, the city’s water use had gone down enough that for the past decade, they never actually used much water from the plant.

Which brings us to the present day, and how the city’s water supply has become an issue in the upcoming mayoral election.

Brockton is currently finalizing a water management plan with the state that Carpenter said will require Brockton to start using the desalinated water to lessen the impact on Silver Lake, which is the city’s main water source. So Carpenter had an idea. The city, he said, should buy the desalination plant.

“It's either option A, remain in the current contract and get absolutely nothing in return for it, or go forward with the purchase of the plant for $78 million, control our own destiny, draw as much water as we want to draw from the plant, and at the end of 20 years we own an asset,” he said.

Carpenter pitched the idea to the city council, which tabled the issue until after the mayoral election.

“I think at its current price it's not feasible not at all,” said Jimmy Pereira, the 26-year-old community planner who’s challenging Carpenter for the mayor’s job. “Water in the next 50 years is going to be the next blue gold. So we want to make sure that we plan ahead, we plan effectively.”

Pereira said Brockton should look at other options, like tying into the Massachusetts Water Resource Authority, or MWRA, a system that 61 other communities use to get water from the Quabbin and Wachusett Reservoirs.

Or, Pereira says, given the big price tag, Brockton shouldn’t go it alone. “I'd like to look at a conglomeration of communities coming to the table looking at purchasing this desalinization plant together.”

“Clearly, you know, Jimmy does not understand the transaction, he does not fully understand the current contract,” Carpenter said.

He said it's too late in the game for other towns to get in on the deal.

“This is going to be the last best proposal to purchase Aquaria," he said.

Carpenter said getting in on the MWRA system would be way too costly. And as for the price of the desalination plant, Carpenter says if they try to get it any lower, Aquaria will walk away from the deal.

“So once the price reaches a certain point the owner of the plant looks at us and says ‘well why would we consider that? We can just sit here and continue to collect your checks for the next 11 and a half years,’” he added.

Once Brockton owns the plant, Carpenter said, the city could sell the desalinated water to the surrounding communities at a competitive price, offsetting the expense of buying the plant.

In a city that’s facing questions of economic development, crime, education, and plenty of other issues, where the water comes from when they turn on the tap may not be top of mind when they go into the voting booth a week from Tuesday. But the choice they make could help shape Brockton’s water system for generations to come.