First of all, you already know it is illegal and, yes you can get it most anywhere and, yes you can be arrested for using, possessing and trying to purchase it. The police sometimes look at a tourist as a "shakedown" target as you mentioned about Mexico.
I happen to live in a town (Accompong Town) where there is no law against ganja. Not to say that the Government of Jamaica does not have the ability to enforce one there but there are no police there to enforce it if they wanted to. The police do occasionally drive through town but they don't get out of their vehicles unless they have business there.
I am going on 30 years this year of traveling to and living in Jamaica and I rarely if ever smoke it, I would NEVER transport it on my person or in a vehicle and I have witnessed several times people being busted for smoking and or transporting it.
It is you own personal decision as to how you would approach this while in Jamaica but be careful as things are not as open as they sometimes appear to be.
Peace and Guidance