Manufacturing flow control and preventing maintenance: a stochastic control approach | Synapse