"A" is the correct indefinite article to use before "long time" because "long" starts with a consonant sound and "a" is used with singular, countable nouns that are not specific.
"The" - Definite article used for something specific
"An" - Used before words that start with a vowel sound
"Such" - This is not an article