The way you phrase it sure makes Keynesian economics seem like socialism...yet Keynes is on record of hating socialists.
Keynes lived in a time when socialism and communism were dirty words, yet, socialism by other means is still socialism.
Keynes was a socialist. He believed government was the answer to a healthy economy and that all markets must be controlled by government. THAT is socialism.