Should I use WHICH or BY WHICH?

Solution 1:

Photosynthesis is the process by which plants generate glucose

is correct. The reason why is that it's equivalent to

Photosynthesis is the process which plants generate glucose by

Which is in turn incorrect if you drop the "by" at the end because

Plants generate glucose by a process

is correct, and

Plants generate glucose a process

is not.