another cool option that i saw on some youtube video from a dispo in Colorado was that they purge all atmospheric air from their containers with nitrogen before sealing. while it wouldn't be possible to do with store bought jars, for long term setting up a couple of one way valves in the lid of a mason jar might be viable. purge atmospheric air for t seconds/minutes and have essentially a hermetically sealed container of weed that'll be as fresh as the day it was sealed (so long other long term storage parameters are met).
back to the topic, store bought jars will be fine. make sure to rinse the pickle jar super well, unless you want pickle-flavor tainted weed.