A 302 redirect tells search engines that a URL has moved temporarily. With a 302 redirect, you’re relying on the search engines to figure out whether to continue to index the old URL and disregard the new one as a duplicate or replace it completely with the new URL.
If they make the wrong choice this can result in a loss of both ranking and traffic. There aren’t many instances when a 302 redirect is a better option than a 301, so unless absolutely necessary, this is not a great route to go down. The exception to this is when content is really only being moved temporarily, such as during maintenance.