public static ConfigurationRootModel BuildContainer(
            ContainerBuilder containerBuilder,
            IServiceFabricConfigurationService serviceFabricConfigurationService)
        {
            IStatelessServiceConfiguration statelessServiceConfiguration = serviceFabricConfigurationService.GetConfigSectionAsStatelessServiceConfiguration();

            containerBuilder.RegisterModule(new StatelessServiceModule(statelessServiceConfiguration));

            ReportServiceConfiguration reportServiceConfiguration = serviceFabricConfigurationService.GetConfigSectionAs <ReportServiceConfiguration>("ReportServiceConfiguration");
            AzureStorageOptions        azureBlobStorageOptions    = serviceFabricConfigurationService.GetConfigSectionAs <AzureStorageOptions>("AzureStorageSection");
            VersionInfo versionInfo = serviceFabricConfigurationService.GetConfigSectionAs <VersionInfo>("VersionSection");

            // register message mapper
            containerBuilder.RegisterType <DefaultJobContextMessageMapper <JobContextMessage> >().As <IMapper <JobContextMessage, JobContextMessage> >();

            // register MessageHandler
            containerBuilder.RegisterType <MessageHandler>().As <IMessageHandler <JobContextMessage> >().InstancePerLifetimeScope();

            containerBuilder.RegisterType <JobContextManager <JobContextMessage> >().As <IJobContextManager <JobContextMessage> >()
            .InstancePerLifetimeScope();

            containerBuilder.RegisterType <JobContextMessage>().As <IJobContextMessage>()
            .InstancePerLifetimeScope();

            containerBuilder.RegisterModule <SerializationModule>();

            return(new ConfigurationRootModel
            {
                reportServiceConfiguration = reportServiceConfiguration,
                azureBlobStorageOptions = azureBlobStorageOptions,
                versionInfo = versionInfo
            });
        }
Beispiel #2
0
 static ReportsController()
 {
     //Setup the ReportServiceConfiguration
     configurationInstance = new ReportServiceConfiguration
     {
         HostAppId            = "Html5App",
         Storage              = new FileStorage(),
         ReportSourceResolver = new UriReportSourceResolver(Path.Combine(HttpContext.Current.Server.MapPath("~/"), "Reports"))
     };
 }
Beispiel #3
0
        public ReportsController(IHostingEnvironment environment)
        {
            var reportsPath = Path.Combine(environment.WebRootPath, "Reports");

            ReportServiceConfiguration = new ReportServiceConfiguration
            {
                HostAppId      = "EpilutionsWeb",
                Storage        = new FileStorage(),
                ReportResolver = new ReportFileResolver(reportsPath)
            };
        }
Beispiel #4
0
        public ReportsController(IHostingEnvironment environment)
        {
            _reportsPath = Path.Combine(environment.WebRootPath, "Reports");

            ReportServiceConfiguration = new ReportServiceConfiguration
            {
                HostAppId      = "SiamEast",
                Storage        = new FileStorage(),
                ReportResolver = new ReportTypeResolver()
                                 .AddFallbackResolver(new ReportFileResolver(_reportsPath))
            };
        }
        static ReportsController()
        {
            var resolver = new UriReportSourceResolver(HttpContext.Current.Server.MapPath("~/Reports"))
                           .AddFallbackResolver(new TypeReportSourceResolver()
                                                .AddFallbackResolver(new CustomReportSourceResolver()));

            configurationInstance = new ReportServiceConfiguration
            {
                HostAppId            = "Application1",
                ReportSourceResolver = resolver,
                Storage = new Telerik.Reporting.Cache.File.FileStorage(),
            };
        }
Beispiel #6
0
        public ReportsController(ConfigurationService configSvc)
        {
            reportsPath = Path.Combine(configSvc.Environment.WebRootPath, "Reports");

            ReportServiceConfiguration = new ReportServiceConfiguration
            {
                ReportingEngineConfiguration = configSvc.Configuration,
                HostAppId      = "AspNetCoreReportDemo",
                Storage        = new FileStorage(),
                ReportResolver = new ReportTypeResolver()
                                 .AddFallbackResolver(new ReportFileResolver(this.reportsPath)),
            };
        }
Beispiel #7
0
        static ReportsController()
        {
            var appPath     = HttpContext.Current.Server.MapPath("~/");
            var reportsPath = Path.Combine(appPath, "Reports");

            var resolver = new ReportFileResolver(reportsPath)
                           .AddFallbackResolver(new ReportTypeResolver());

            configurationInstance = new ReportServiceConfiguration
            {
                HostAppId      = "ShoppingOnlineApp",
                Storage        = new FileStorage(),
                ReportResolver = resolver
            };
        }
Beispiel #8
0
        static ReportsController()
        {
            var appPath     = HttpContext.Current.Server.MapPath("~/");
            var reportsPath = HttpContext.Current.Server.MapPath("~/Reports");

            var resolver = new ReportFileResolver(reportsPath)
                           .AddFallbackResolver(new ReportTypeResolver());

            //Setup the ReportServiceConfiguration
            configurationInstance = new ReportServiceConfiguration
            {
                HostAppId      = "Html5App",
                Storage        = new Telerik.Reporting.Cache.File.FileStorage(),
                ReportResolver = resolver,
            };
        }
Beispiel #9
0
        static ReportsController()
        {
            var appPath     = HttpContext.Current.Server.MapPath("~/");
            var reportsPath = Path.Combine(appPath, @"..\..\..\Report Designer\Examples");
            var resolver    = new ReportFileResolver(reportsPath)
                              .AddFallbackResolver(new ReportTypeResolver());

            configurationInstance = new ReportServiceConfiguration
            {
                HostAppId      = "Html5DemoApp",
                Storage        = new FileStorage(),
                ReportResolver = resolver,
                // ReportSharingTimeout = 0,
                // ClientSessionTimeout = 15,
            };
        }
Beispiel #10
0
        static ReportsController()
        {
            //This is the folder that contains the XML (trdx) report definitions
            //In this case this is the app folder
            var reportPath = HttpContext.Current.Server.MapPath("~/");

            //Add resolver for trdx report definitions,
            //then add resolver for class report definitions as fallback resolver;
            //finally create the resolver and use it in the ReportServiceConfiguration instance.
            var resolver = new ReportFileResolver(reportPath)
                           .AddFallbackResolver(new ReportTypeResolver());

            //Setup the ReportServiceConfiguration
            configurationInstance = new ReportServiceConfiguration
            {
                HostAppId      = "Html5DemoApp",
                Storage        = new FileStorage(),
                ReportResolver = resolver,
                // ReportSharingTimeout = 0,
                // ClientSessionTimeout = 15,
            };
        }
        static ReportsController()
        {
            //This is the folder that contains the XML (trdx) report definitions
            //In this case this is the app folder
            var reportPath = HttpContext.Current.Server.MapPath("~/");

            //Add resolver for trdx report definitions,
            //then add resolver for class report definitions as fallback resolver;
            //finally create the resolver and use it in the ReportServiceConfiguration instance.
            var resolver = new ReportFileResolver(reportPath)
                .AddFallbackResolver(new ReportTypeResolver());

            //Setup the ReportServiceConfiguration
            configurationInstance = new ReportServiceConfiguration
            {
                HostAppId = "Html5DemoApp",
                Storage = new FileStorage(),
                ReportResolver = resolver,
                // ReportSharingTimeout = 0,
                // ClientSessionTimeout = 15,
            };
        }
Beispiel #12
0
        static ReportDesignerController()
        {
            //This is the folder that contains the report definitions
            //In this case this is the Reports folder
            string reportsPath = Path.Combine(HttpContext.Current.Server.MapPath("~/"), "Reports");

            //Setup the ReportServiceConfiguration
            ConfigurationInstance = new ReportServiceConfiguration
            {
                HostAppId            = "AspNetMvcApp",
                Storage              = new FileStorage(),
                ReportSourceResolver = CreateResolver(reportsPath),
                //ReportSharingTimeout = 1000,
                //ClientSessionTimeout = 20,
            };

            DesignerConfigurationInstance = new ReportDesignerServiceConfiguration
            {
                DefinitionStorage = new FileDefinitionStorage(reportsPath),
                SettingsStorage   = new FileSettingsStorage(Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), "Telerik Reporting"))
            };
        }
        static ReportsController()
        {
            //This is the folder that contains the XML (trdx) report definitions
            //In this case this is the app folder
          // ReportLibrary2.Report2.ChangeSqlString("Data Source=devServer;Initial Catalog=Z_Yamhill;User ID=sa;Password=data22");
            var reportsPath = HttpContext.Current.Server.MapPath("~/");

            //Add resolver for trdx report definitions, 
            //then add resolver for class report definitions as fallback resolver; 
            //finally create the resolver and use it in the ReportServiceConfiguration instance.
            var resolver = new ReportFileResolver(reportsPath)
                .AddFallbackResolver(new ReportTypeResolver());

            //Setup the ReportServiceConfiguration
            configurationInstance = new ReportServiceConfiguration
            {
                HostAppId = "MvcApp",
                Storage = new FileStorage(),
                ReportResolver = resolver,
                // ReportSharingTimeout = 0,
                // ClientSessionTimeout = 15,
            };
        }
Beispiel #14
0
        static ReportsController()
        {
            //This is the folder that contains the XML (trdx) report definitions
            //In this case this is the app folder
            // ReportLibrary2.Report2.ChangeSqlString("Data Source=devServer;Initial Catalog=Z_Yamhill;User ID=sa;Password=data22");
            var reportsPath = HttpContext.Current.Server.MapPath("~/");

            //Add resolver for trdx report definitions,
            //then add resolver for class report definitions as fallback resolver;
            //finally create the resolver and use it in the ReportServiceConfiguration instance.
            var resolver = new ReportFileResolver(reportsPath)
                           .AddFallbackResolver(new ReportTypeResolver());

            //Setup the ReportServiceConfiguration
            configurationInstance = new ReportServiceConfiguration
            {
                HostAppId      = "MvcApp",
                Storage        = new FileStorage(),
                ReportResolver = resolver,
                // ReportSharingTimeout = 0,
                // ClientSessionTimeout = 15,
            };
        }