protected void DependencySetup(ContainerBuilder builder)
        {
            // Cloud Storage Account
            builder.RegisterInstance<CloudStorageAccount>(CloudStorageAccount.FromConfigurationSetting("DataConnectionString"));

            // Queues
            builder.RegisterQueue<InviteMessage>(ConfigurationConstants.InvitesQueue)
                .AsImplementedInterfaces();

            // Blobs
            builder.RegisterBlob<UserProfile>(ConfigurationConstants.UsersContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<UserSession>(ConfigurationConstants.UserSessionsContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<Friends>(ConfigurationConstants.FriendsContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<NotificationStatus>(ConfigurationConstants.NotificationsContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<Game>(ConfigurationConstants.GamesContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<GameQueue>(ConfigurationConstants.GamesQueuesContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<UserProfile>(ConfigurationConstants.GamesContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();

            // Tables
            builder.RegisterTable<UserStats>(ConfigurationConstants.UserStatsTableName, true /* jsonpSupport */)
                .AsImplementedInterfaces();

            // Repositories
            builder.RegisterType<GameRepository>().AsImplementedInterfaces();
            builder.RegisterType<IdentityProviderRepository>().AsImplementedInterfaces();
            builder.RegisterType<NotificationRepository>().AsImplementedInterfaces();
            builder.RegisterType<UserRepository>().AsImplementedInterfaces();

            // Commands
            builder.RegisterType<InviteCommand>();

            // Misc
            builder.RegisterType<InMemoryWorkerContext>().AsImplementedInterfaces();

            builder.RegisterType<StatisticsRepository>().AsImplementedInterfaces();
            builder.RegisterType<GameActionCommand>();
            builder.RegisterType<GameActionStatisticsCommand>();
        }
        protected void DependencySetup(ContainerBuilder builder)
        {
            // Cloud Storage Account
            builder.RegisterInstance<CloudStorageAccount>(CloudStorageAccount.FromConfigurationSetting("DataConnectionString"));

            // Queues
            builder.RegisterQueue<GameActionStatisticsMessage>(ConfigurationConstants.GameActionStatisticsQueue)
                .AsImplementedInterfaces();
            builder.RegisterQueue<GameActionNotificationMessage>(ConfigurationConstants.GameActionNotificationsQueue)
                .AsImplementedInterfaces();
            builder.RegisterQueue<InviteMessage>(ConfigurationConstants.InvitesQueue)
                .AsImplementedInterfaces();

            // Blobs
            builder.RegisterBlob<UserProfile>(ConfigurationConstants.UsersContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<UserSession>(ConfigurationConstants.UserSessionsContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<Friends>(ConfigurationConstants.FriendsContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<NotificationStatus>(ConfigurationConstants.NotificationsContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<Game>(ConfigurationConstants.GamesContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<GameQueue>(ConfigurationConstants.GamesQueuesContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();
            builder.RegisterBlob<UserProfile>(ConfigurationConstants.GamesContainerName, true /* jsonpSupport */)
                .AsImplementedInterfaces();

            // Tables
            builder.RegisterTable<UserStats>(ConfigurationConstants.UserStatsTableName, true /* jsonpSupport */)
                .AsImplementedInterfaces();

            // Repositories
            builder.RegisterType<GameActionNotificationQueue>().AsImplementedInterfaces();
            builder.RegisterType<GameActionStatisticsQueue>().AsImplementedInterfaces();
            builder.RegisterType<GameRepository>().AsImplementedInterfaces();
            builder.RegisterType<IdentityProviderRepository>().AsImplementedInterfaces();
            builder.RegisterType<NotificationRepository>().AsImplementedInterfaces();
            builder.RegisterType<UserRepository>().AsImplementedInterfaces();
            builder.RegisterType<StatisticsRepository>().AsImplementedInterfaces();

            // Controllers
            builder.RegisterControllers(typeof(MvcApplication).Assembly);

            // Services
            builder.RegisterType<AuthService>().AsImplementedInterfaces().AsSelf();
            builder.RegisterType<EventService>().AsImplementedInterfaces().AsSelf();
            builder.RegisterType<GameService>().AsImplementedInterfaces().AsSelf();
            builder.RegisterType<HttpContextUserProvider>().AsImplementedInterfaces().AsSelf();
            builder.RegisterType<UserService>().AsImplementedInterfaces().AsSelf();

            // Api
            builder.RegisterType<AuthController>().AsImplementedInterfaces().AsSelf();
            builder.RegisterType<GameController>().AsImplementedInterfaces().AsSelf();
            builder.RegisterType<UserController>().AsImplementedInterfaces().AsSelf();
            builder.RegisterType<EventController>().AsImplementedInterfaces().AsSelf();
        }