Conservation of Momentum for Pulley System Consider a pulley system

Thank you to a user below for this clarification of what the question is:

Why is the momentum of a pully with two masses moving with velocity $v$ equal to $(m_1+m_2)v$ and not $m_1v−m_2v$ (as it would by vector addition of the momenta of independent/unconnected masses)?

Background
In a textbook I am looking at it says that

The Principle of Conservation of Momentum may be applied to bodies at the ends of a piece of string. We must regard the string-particle system as one body, like a long train going around the corner.

The text then goes on to use this principle to solve problems such as the following:


*

*Two particles of masses 4 kg and 3 kg hang from a pulley at the ends of a light inextensible string. The system is released from rest. After 2 seconds, the 3 kg pass picks up a particle of mass 2 kg. How much further will the 4 kg mass move downward before it stops?


*Two masses of 5 kg and 1 kg hang from a smooth pulley at the ends of a light inextensible string. The system is released from rest. After 2 seconds, the 5 kg mass hits a horizontal table: i. How much further will the 1 kg mass rise? ii. The 1 kg mass then falls and the 5 kg mass is jolted off the table. With what speed will the 5 kg mass begin to rise?

I cannot reconcile the vector nature of velocity and hence momentum with this "going around the corner" business. Perhaps someone can explain this better than the textbook... or perhaps is the textbook incorrect?
Edit: For example, consider problem 1 here. We can show that after two seconds the speed of each particle is $\frac27 g$ m s$^{-1}$. Now I quote:

At this point the 3 kg mass picks up a 2 kg mass, to become a new mass of 5 kg. The system will immediately be jolted to a slower speed. This speed can be found by applying the Principle of Conservation to the particle-string system. The mass of this whole system was 7 kg before the jolt and 9 kg after the jolt. Let $v$ be the new speed.

The textbook then uses:
$$m_1u=m_2v$$
$$\Rightarrow 7\left(\frac{2}{7}g\right)=9v$$
$$\Rightarrow v=\frac29 g\text{ m s}^{-1}.$$
I don't understand how this is a valid application of the conservation of momentum.
My understanding of momentum (it is a vector) would be that the equation is (choosing down as positive):
$$4\cdot \frac{2}{7}g-3\cdot \frac{2}{7}g=4\cdot v-5\cdot v.$$
 A: Let's look at the simple pulley system, i.e. no friction, inextensible string, no hitting of table, etc. Also, it is very important to realize that we only pull at the ends of the strings, i.e. we don't do any lifting of the masses. 
With these simplifications, the only purpose of the string is to make the masses move at the same velocity. For instance you could shorten the string and the system would work exactly in the same way. 
Also, you note that the only purpose of the wheel is to get two gravitational forces which allows you to play around with (more interesting than just dropping a mass in gravity).
Taking this into account, the pulley is (for the purpose of simple pulley movements) completely equivalent to a straight string connecting two masses (or even two masses connected directly to each other, or even a single mass equal to the sum of these two masses) and you pull at this system at either end with the respective gravitational weight/force of that mass. 

So if you write the momentum of this system it will be just the velocity times the total mass, $p=(m_1+m_2) v$. There is no question about adding two momenta, because essentially you have one body only. Adding momenta like you suggest would only make sense if the two masses could move independently, which they cannot because of the conditions.
In idealized physical systems like this one, you often run into apparent violations of conservation laws. Take for instance the perfect reflection  of a ball off a wall, i.e. a reflection where the speed is conserved, but the velocity direction reversed. Apparently in this process the momentum changes by $2mv$, i.e. is not conserved. However if you study this system on a microscopic level you see that momentum is transferred to the atoms in the wall, etc, so that momentum is conserved.
A: The term going around the corner here just means that there is conservation of momentum as this is a single, closed system.
Momentum is $mv$, mass multiplied by velocity.  Since the mass was added during the movement of the pulley, momentum is conserved.  This means that the initial momentum, $m_1u$ is equal to the final momentum, $m_2v$.  You have your answer.
As mentioned above, momentum is $mv$.  So the total mass is $m_1+m_2$, and velocity is $v$.  However, since this is a closed system, momentum is built up instead of subtracted.  The total mass, regardless of the ratio of masses on both sides, is still the sum of the mass of the whole system, so it is $(m_1+m_2)v$.
A: consider reading the answer (in the link below) as he has very well put all the concepts why we cannot apply conservation of linear momentum as your book says . even if we consider the string and mass as our system there is always net external force on the system by the earth which is nothing but the weight of the system. so approaching the problem with the concept of linear momentum might give correct result in some cases but in many case it will lead to wrong result as we are fundamentally applying the concept in wrong way . Such problems are better approached by impulse momentum principle. consider having a look at the solution as an example to your problem and first answer on post as the most correct explanation to your problem 
https://physics.stackexchange.com/a/203981
