Regarding join in pyspark
I got the answer by taking reverse of the above list and then using inner join of rdd to get all corresponding transitive pairs. After removing duplicates i.e. (b,a) and same edges (a,a) or (b,b) got the resulting rdd.

Thanks for the help.