Inheritance: IRecordProcessor
示例#1
0
        static void Main()
        {
            var awsKey = "AKIAJTGWYUCX6G7P2FOQ";
            var awsSecret = "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";
            var region = RegionEndpoint.USEast1;
            var appName = "YC-test";
            var streamName = "YC-test";
            var workerId = "PHANTOM-cs";

            BasicConfigurator.Configure();

            var processor = new MyProcessor();

            Console.WriteLine("Starting client application...");

            var factory = new MyProcessorFactory();
            var app = ReactoKinesixApp.CreateNew(awsKey, awsSecret, region, appName, streamName, workerId, factory);

            app.OnInitialized += (_, evtArgs) => Console.WriteLine("Client application started");
            app.OnBatchProcessed += (_, evtArgs) => Console.WriteLine("Another batch processed...");

            Console.WriteLine("Press any key to quit...");
            Console.ReadKey();

            app.Dispose();
        }
示例#2
0
        static void Main()
        {
            var awsKey     = "AKIAJTGWYUCX6G7P2FOQ";
            var awsSecret  = "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";
            var region     = RegionEndpoint.USEast1;
            var appName    = "YC-test";
            var streamName = "YC-test";
            var workerId   = "PHANTOM-cs";

            BasicConfigurator.Configure();

            var processor = new MyProcessor();

            Console.WriteLine("Starting client application...");

            var factory = new MyProcessorFactory();
            var app     = ReactoKinesixApp.CreateNew(awsKey, awsSecret, region, appName, streamName, workerId, factory);

            app.OnInitialized    += (_, evtArgs) => Console.WriteLine("Client application started");
            app.OnBatchProcessed += (_, evtArgs) => Console.WriteLine("Another batch processed...");

            Console.WriteLine("Press any key to quit...");
            Console.ReadKey();

            app.Dispose();
        }