Created
September 30, 2020 00:13
-
-
Save oguzhancagliyan/519a01149e34f4a22b0eb7f70932bbc0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class SqsSeeder | |
{ | |
public static void CreateQueue(AmazonSQSClient client) | |
{ | |
var installers = typeof(MovieLikeSeeder).Assembly.ExportedTypes | |
.Where(m => typeof(ISqsSeeder).IsAssignableFrom(m) && !m.IsInterface && !m.IsAbstract) | |
.Select(Activator.CreateInstance) | |
.Cast<ISqsSeeder>() | |
.ToList(); | |
installers.ForEach(m => m.CreateQueue(client)); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment