Optimal resource allocation in networks of general single-server finite queues (Journal of the Brazilian Computer Society, 2026)