[Improvement] Avoid initialising new SnowflakeConnector multiple times

Describe the feature

Currently in SnowflakeGrantsGenerator and SnowflakeSpecLoader, when querying Snowflake, SnowflakeConnector will be initialised multiple times. It would be better if we could try to pass SnowflakeConnector object as a variable in those functions or make SnowflakeConnector as a singleton. This will be helpful especially when applying permifrost via SSO login.

Describe alternatives you've considered

  1. We can consider passing SnowflakeConnector as a variable into those functions
  2. We can consider using class attribute so that it can be directly referred
  3. We can consider making SnowflakeConnector a singleton

Additional context

N.A.

Who will this benefit?

For people who are using SSO login method will be hugely benefitted. Otherwise every time when a new SnowflakeConnector is initialised, a new login window will be popped up for authentication.

Are you interested in contributing this feature?

Yes