SlideShare a Scribd company logo
1 of 37
Download to read offline
SQL Server 2008 R2
  StreamInsight
  Speaker: Mark Simms
    Microsoft SQLCAT


 Silicon Valley SQL Server User Group
               May, 2010




    Mark Ginnebaugh, User Group Leader,
          mark@designmind.com
masimms@microsoft.com
Load barrier is dictated by
 current choices of the solution,
                                                                                         Facts/sec.
 e.g., loading into databases,
 persisting into files. This is
 intrinsic because in current
 approaches no processing can
 be done till the data is loaded.               Custom-built solutions that
                                               carry huge development and           100000
                                                    customization costs

                                                                                    10000
                               Active DW analytics
                                                                                    1000

           Traditional DW Analytics
                                                                                    100
years                months                days               hrs      min    sec

                            Time of interest
                                                                               Present
    ET time in ETL   Load time in ETL
Analytical results need to reflect important changes in
 business reality immediately and enable responses to them
 with minimal latency
             Database Applications    Event-driven Applications
Query        Ad-hoc queries or        Continuous standing
Paradigm     requests                 queries
Latency      Seconds, hours, days     Milliseconds or less
Data Rate    Hundreds of events/sec   Tens of thousands of
                                      events/sec or more
Query        Declarative relational   Declarative relational and
Semantics    analytics                temporal analytics

                           request        Event
                                                       output
                                                       stream
                                         input
                                        stream
              response
                                                                   5
Latency
Months
                                                                 StreamInsight
Days                                                            Target Scenarios

hours         Relational Database Applications           Operational Analytics
                                                       Applications, e.g., Logistics,
Minutes                                Data Warehousing           etc.
                                          Applications
Seconds
                                                       Web Analytics Applications

100 ms        Monitoring                Manufacturing
                                                                 Financial trading
              Applications               Applications
< 1ms
                                                                 Applications

          0           10         100         1000       10000        100000     ~1million

                             Aggregate Data Rate (Events/sec.)
                                                                                        6
Manufacturing:         Web Analytics:          Financial Services:      Power Utilities:
                     • Sensor on plant      • Click-stream data     • Stock & news feeds     • Energy
                       floor                • Online customer       • Algorithmic trading      consumption
                     • React through          behavior              • Patterns over time     • Outages
                       device controllers   • Page layout           • Super-low latency      • Smart grids
                     • Aggregated data      • 100,000 events /sec   • 100,000 events /sec    • 100,000 events/sec
                     • 10,000 events/sec

       Asset Instrumentation for Data Acquisition, Subscriptions to Data Feeds
       Data Stream




                                                                                                           Data Stream
                                                  Visual trend-line and KPI monitoring
                                                  Batch & product management
                                                  Automated anomaly detection
                                                  Real-time customer segmentation
                                                  Algorithmic trading
                                                  Proactive condition-based maintenance



                                                    Asset Specs &                              StreamInsight Engine
                                                     Parameters
                                                                                            • Threshold queries
Stream Data Store &                                                                         • Event correlation from
      Archive                                                            Lookup               multiple sources
                                                                                            • Pattern queries




                                                                                                                         7
StreamInsight
Industry trends
                                                         advantage
• Data acquisition
  costs are
                                           Manage        • Process data
                       Monitor KPIs                        incrementally,
  negligible                              business via
                        Record raw                         i.e., while it is in
                                         KPI-triggered
• Raw storage costs    data (history)                      flight
  are small and
                                            actions
                                                         • Avoid loading
  continue to                                              while still doing
  decrease                                                 the processing
                                                           you want
• Processing costs
  are non-negligible         Mine historical data        • Seamless
                                                           querying for
• Data loading                Devise new KPIs
                                                           monitoring,
  costs continue to                                        managing and
  be significant                                           mining


                                                                           8
StreamInsight Application
 Development
                               StreamInsight Application at Runtime
 Event sources                                                               Event targets

                            Input                                Output
   Devices, Sensors        Adapters      StreamInsight Engine   Adapters   Pagers &
                                                                           Monitoring devices
                                        Standing Queries                            KPI Dashboards,
                                                                                    SharePoint UI
    Web servers
                                         Query         Query
                                         Logic         Logic

                                                                                  Trading stations
Event stores &
Databases                                              Query
                                                       Logic

Stock ticker, news feeds                                                   Event stores & Databases
SELECT COUNT(*) FROM ParkingLot
WHERE type = ‘AUTO’
AND color = ‘RED’
red
cars
             last hour




 Doesn’t seem like a
  great solution…
This is the streaming data paradigm in a nutshell –
          ask questions about data in flight.
Engine


Adapters
      Engine
Queries

  Extensions
Host

                        visual debugger
API
expressed

                   question
data
                   data
question
Tell me the just the color of each car that passes.




var result = from car in carStream
             select new
             {
                 car.Color
             };
Give me only trucks.




var result = from car in carStream
             where car.Type == “Truck”
             select car;
Tell me the number of cars passed
                   every 10 seconds.




var result = from win in carStream.TumblingWindow(
                           TimeSpan.FromSeconds(10))
             select new
             {
                 count = win.Count()
             };
var result = from win in carStream.TumblingWindow(
                           TimeSpan.FromSeconds(10))
             select new
             {
                 count = win.Count()
             };
Count the number of cars for each make
           separately every 10 seconds.


var result = from car in carStream
             group car by car.make into eachGroup
             from win in carStream.TumblingWindow(
                           TimeSpan.FromSeconds(10))
             select new
             {
                 make = eachGroup.Key,
                 count = win.Count()
             };
application time

Current Time Indicators
public void EnqueueEvent(SourceData d)
{
    var ev = CreateInsertEvent();

    ev.Payload = new MouseEvent { Id = d.id, Value = d.value };
    ev.StartTime = d.timestamp;

    Enqueue(ref ev);
}
public void EnqueueEvent(SourceData d)
{
    if                  AdapterState


       return


    var ev = CreateInsertEvent();

    ev.Payload = new MouseEvent { Id = d.id, Value = d.value };
    ev.StartTime = d.timestamp;

    Enqueue(ref ev);
}
public void EnqueueEvent(SourceData d)
{
    if                  AdapterState


       return


    var ev = CreateInsertEvent();
    if (ev == null) return;

    ev.Payload = new MouseEvent { Id = d.id, Value = d.value };
    ev.StartTime = d.timestamp;

    Enqueue(ref ev);
}
public void EnqueueEvent(SourceData d)
{
    if                  AdapterState


        return


    var ev = CreateInsertEvent();
    if (ev == null) return;

    ev.Payload = new MouseEvent { Id = d.id, Value = d.value };
    ev.StartTime = d.timestamp;

    if (Enqueue(ref ev) == EnqueueOperationResult.Full)
    {

        Ready();
        return;
    }
}
Use them wisely!
public class TimeWeightedAverage :
                      CepTimeSensitiveAggregate<double, double>
{
    public override double
    GenerateOutput(IEnumerable<IntervalEvent<double>> events,
                   WindowDescriptor windowDescriptor)
    {
        double avg = 0;
        foreach (IntervalEvent<double> ev in events)
        {
            avg += intervalEvent.Payload *
                       (ev.EndTime - ev.StartTime).Ticks;
        }
        return = avg / (windowDescriptor.EndTime –
                        windowDescriptor.StartTime).Ticks;
    }
}
To learn more or inquire about speaking opportunities, please contact:

                Mark Ginnebaugh, User Group Leader
                      mark@designmind.com

More Related Content

Similar to Microsoft StreamInsight

Iaitam 2011-itam final frontier
Iaitam 2011-itam final frontierIaitam 2011-itam final frontier
Iaitam 2011-itam final frontier
slemm
 
16h00 globant - aws globant-big-data_summit2012
16h00   globant - aws globant-big-data_summit201216h00   globant - aws globant-big-data_summit2012
16h00 globant - aws globant-big-data_summit2012
infolive
 
BAM CEP / Business Activity Monitoring , Complex Event Processingomplex
BAM CEP / Business Activity Monitoring , Complex Event Processingomplex BAM CEP / Business Activity Monitoring , Complex Event Processingomplex
BAM CEP / Business Activity Monitoring , Complex Event Processingomplex
Liviu Claudiu Cismaru
 
Guy Nirpaz Next Gen App Servers
Guy Nirpaz Next Gen App ServersGuy Nirpaz Next Gen App Servers
Guy Nirpaz Next Gen App Servers
deimos
 

Similar to Microsoft StreamInsight (20)

Scalable Computing Labs (SCL).
Scalable Computing Labs (SCL).Scalable Computing Labs (SCL).
Scalable Computing Labs (SCL).
 
IBM Smarter Business 2012 - PureSystems - PureData
IBM Smarter Business 2012 - PureSystems - PureDataIBM Smarter Business 2012 - PureSystems - PureData
IBM Smarter Business 2012 - PureSystems - PureData
 
Java Batch for Cost Optimized Efficiency
Java Batch for Cost Optimized EfficiencyJava Batch for Cost Optimized Efficiency
Java Batch for Cost Optimized Efficiency
 
Spark meetup stream processing use cases
Spark meetup   stream processing use casesSpark meetup   stream processing use cases
Spark meetup stream processing use cases
 
TH e-GIF on SOA Using Open Enterprise Architecture
TH e-GIF on SOA Using Open Enterprise ArchitectureTH e-GIF on SOA Using Open Enterprise Architecture
TH e-GIF on SOA Using Open Enterprise Architecture
 
Evolving analytics at ebay - 2012 Tableau Customer Conference
Evolving analytics at ebay - 2012 Tableau Customer ConferenceEvolving analytics at ebay - 2012 Tableau Customer Conference
Evolving analytics at ebay - 2012 Tableau Customer Conference
 
Technology in support of utilities challenges
Technology in support of utilities challengesTechnology in support of utilities challenges
Technology in support of utilities challenges
 
Data & analytics challenges in a microservice architecture
Data & analytics challenges in a microservice architectureData & analytics challenges in a microservice architecture
Data & analytics challenges in a microservice architecture
 
Iaitam 2011-itam final frontier
Iaitam 2011-itam final frontierIaitam 2011-itam final frontier
Iaitam 2011-itam final frontier
 
Advanced Logging and Analysis for SOA, Social, Cloud and Big Data
Advanced Logging and Analysis for SOA, Social, Cloud and Big DataAdvanced Logging and Analysis for SOA, Social, Cloud and Big Data
Advanced Logging and Analysis for SOA, Social, Cloud and Big Data
 
Track and Trace Solution Details
Track and Trace Solution DetailsTrack and Trace Solution Details
Track and Trace Solution Details
 
9sept2009 iiruc
9sept2009 iiruc9sept2009 iiruc
9sept2009 iiruc
 
Sybase Complex Event Processing
Sybase Complex Event ProcessingSybase Complex Event Processing
Sybase Complex Event Processing
 
Siddhi: A Second Look at Complex Event Processing Implementations
Siddhi: A Second Look at Complex Event Processing ImplementationsSiddhi: A Second Look at Complex Event Processing Implementations
Siddhi: A Second Look at Complex Event Processing Implementations
 
Globant and Big Data on AWS
Globant and Big Data on AWSGlobant and Big Data on AWS
Globant and Big Data on AWS
 
16h00 globant - aws globant-big-data_summit2012
16h00   globant - aws globant-big-data_summit201216h00   globant - aws globant-big-data_summit2012
16h00 globant - aws globant-big-data_summit2012
 
Finding fraud in large, diverse data sets
Finding fraud in large, diverse data setsFinding fraud in large, diverse data sets
Finding fraud in large, diverse data sets
 
BAM CEP / Business Activity Monitoring , Complex Event Processingomplex
BAM CEP / Business Activity Monitoring , Complex Event Processingomplex BAM CEP / Business Activity Monitoring , Complex Event Processingomplex
BAM CEP / Business Activity Monitoring , Complex Event Processingomplex
 
Guy Nirpaz Next Gen App Servers
Guy Nirpaz Next Gen App ServersGuy Nirpaz Next Gen App Servers
Guy Nirpaz Next Gen App Servers
 
Cloud Service Management: Why Machine Learning is Now Essential
Cloud Service Management: Why Machine Learning is Now EssentialCloud Service Management: Why Machine Learning is Now Essential
Cloud Service Management: Why Machine Learning is Now Essential
 

More from Mark Ginnebaugh

More from Mark Ginnebaugh (20)

Automating Microsoft Power BI Creations 2015
Automating Microsoft Power BI Creations 2015Automating Microsoft Power BI Creations 2015
Automating Microsoft Power BI Creations 2015
 
Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction
Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction
Microsoft SQL Server Analysis Services (SSAS) - A Practical Introduction
 
Platfora - An Analytics Sandbox In A World Of Big Data
Platfora - An Analytics Sandbox In A World Of Big DataPlatfora - An Analytics Sandbox In A World Of Big Data
Platfora - An Analytics Sandbox In A World Of Big Data
 
Microsoft SQL Server Relational Databases and Primary Keys
Microsoft SQL Server Relational Databases and Primary KeysMicrosoft SQL Server Relational Databases and Primary Keys
Microsoft SQL Server Relational Databases and Primary Keys
 
DesignMind Microsoft Business Intelligence SQL Server
DesignMind Microsoft Business Intelligence SQL ServerDesignMind Microsoft Business Intelligence SQL Server
DesignMind Microsoft Business Intelligence SQL Server
 
San Francisco Bay Area SQL Server July 2013 meetings
San Francisco Bay Area SQL Server July 2013 meetingsSan Francisco Bay Area SQL Server July 2013 meetings
San Francisco Bay Area SQL Server July 2013 meetings
 
Silicon Valley SQL Server User Group June 2013
Silicon Valley SQL Server User Group June 2013Silicon Valley SQL Server User Group June 2013
Silicon Valley SQL Server User Group June 2013
 
Microsoft SQL Server Continuous Integration
Microsoft SQL Server Continuous IntegrationMicrosoft SQL Server Continuous Integration
Microsoft SQL Server Continuous Integration
 
Hortonworks Big Data & Hadoop
Hortonworks Big Data & HadoopHortonworks Big Data & Hadoop
Hortonworks Big Data & Hadoop
 
Microsoft SQL Server Physical Join Operators
Microsoft SQL Server Physical Join OperatorsMicrosoft SQL Server Physical Join Operators
Microsoft SQL Server Physical Join Operators
 
Microsoft PowerPivot & Power View in Excel 2013
Microsoft PowerPivot & Power View in Excel 2013Microsoft PowerPivot & Power View in Excel 2013
Microsoft PowerPivot & Power View in Excel 2013
 
Microsoft Data Warehouse Business Intelligence Lifecycle - The Kimball Approach
Microsoft Data Warehouse Business Intelligence Lifecycle - The Kimball ApproachMicrosoft Data Warehouse Business Intelligence Lifecycle - The Kimball Approach
Microsoft Data Warehouse Business Intelligence Lifecycle - The Kimball Approach
 
Fusion-io Memory Flash for Microsoft SQL Server 2012
Fusion-io Memory Flash for Microsoft SQL Server 2012Fusion-io Memory Flash for Microsoft SQL Server 2012
Fusion-io Memory Flash for Microsoft SQL Server 2012
 
Microsoft Data Mining 2012
Microsoft Data Mining 2012Microsoft Data Mining 2012
Microsoft Data Mining 2012
 
Microsoft SQL Server PASS News August 2012
Microsoft SQL Server PASS News August 2012Microsoft SQL Server PASS News August 2012
Microsoft SQL Server PASS News August 2012
 
Business Intelligence Dashboard Design Best Practices
Business Intelligence Dashboard Design Best PracticesBusiness Intelligence Dashboard Design Best Practices
Business Intelligence Dashboard Design Best Practices
 
Microsoft Mobile Business Intelligence
Microsoft Mobile Business Intelligence Microsoft Mobile Business Intelligence
Microsoft Mobile Business Intelligence
 
Microsoft SQL Server 2012 Cloud Ready
Microsoft SQL Server 2012 Cloud ReadyMicrosoft SQL Server 2012 Cloud Ready
Microsoft SQL Server 2012 Cloud Ready
 
Microsoft SQL Server 2012 Master Data Services
Microsoft SQL Server 2012 Master Data ServicesMicrosoft SQL Server 2012 Master Data Services
Microsoft SQL Server 2012 Master Data Services
 
Microsoft SQL Server PowerPivot
Microsoft SQL Server PowerPivotMicrosoft SQL Server PowerPivot
Microsoft SQL Server PowerPivot
 

Recently uploaded

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Recently uploaded (20)

Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 

Microsoft StreamInsight

  • 1. SQL Server 2008 R2 StreamInsight Speaker: Mark Simms Microsoft SQLCAT Silicon Valley SQL Server User Group May, 2010 Mark Ginnebaugh, User Group Leader, mark@designmind.com
  • 3.
  • 4. Load barrier is dictated by current choices of the solution, Facts/sec. e.g., loading into databases, persisting into files. This is intrinsic because in current approaches no processing can be done till the data is loaded. Custom-built solutions that carry huge development and 100000 customization costs 10000 Active DW analytics 1000 Traditional DW Analytics 100 years months days hrs min sec Time of interest Present ET time in ETL Load time in ETL
  • 5. Analytical results need to reflect important changes in business reality immediately and enable responses to them with minimal latency Database Applications Event-driven Applications Query Ad-hoc queries or Continuous standing Paradigm requests queries Latency Seconds, hours, days Milliseconds or less Data Rate Hundreds of events/sec Tens of thousands of events/sec or more Query Declarative relational Declarative relational and Semantics analytics temporal analytics request Event output stream input stream response 5
  • 6. Latency Months StreamInsight Days Target Scenarios hours Relational Database Applications Operational Analytics Applications, e.g., Logistics, Minutes Data Warehousing etc. Applications Seconds Web Analytics Applications 100 ms Monitoring Manufacturing Financial trading Applications Applications < 1ms Applications 0 10 100 1000 10000 100000 ~1million Aggregate Data Rate (Events/sec.) 6
  • 7. Manufacturing: Web Analytics: Financial Services: Power Utilities: • Sensor on plant • Click-stream data • Stock & news feeds • Energy floor • Online customer • Algorithmic trading consumption • React through behavior • Patterns over time • Outages device controllers • Page layout • Super-low latency • Smart grids • Aggregated data • 100,000 events /sec • 100,000 events /sec • 100,000 events/sec • 10,000 events/sec Asset Instrumentation for Data Acquisition, Subscriptions to Data Feeds Data Stream Data Stream Visual trend-line and KPI monitoring Batch & product management Automated anomaly detection Real-time customer segmentation Algorithmic trading Proactive condition-based maintenance Asset Specs & StreamInsight Engine Parameters • Threshold queries Stream Data Store & • Event correlation from Archive Lookup multiple sources • Pattern queries 7
  • 8. StreamInsight Industry trends advantage • Data acquisition costs are Manage • Process data Monitor KPIs incrementally, negligible business via Record raw i.e., while it is in KPI-triggered • Raw storage costs data (history) flight are small and actions • Avoid loading continue to while still doing decrease the processing you want • Processing costs are non-negligible Mine historical data • Seamless querying for • Data loading Devise new KPIs monitoring, costs continue to managing and be significant mining 8
  • 9. StreamInsight Application Development StreamInsight Application at Runtime Event sources Event targets Input Output Devices, Sensors Adapters StreamInsight Engine Adapters Pagers & Monitoring devices Standing Queries KPI Dashboards, SharePoint UI Web servers Query Query Logic Logic Trading stations Event stores & Databases Query Logic Stock ticker, news feeds Event stores & Databases
  • 10.
  • 11.
  • 12.
  • 13.
  • 14.
  • 15.
  • 16. SELECT COUNT(*) FROM ParkingLot WHERE type = ‘AUTO’ AND color = ‘RED’
  • 17. red cars last hour Doesn’t seem like a great solution…
  • 18. This is the streaming data paradigm in a nutshell – ask questions about data in flight.
  • 19. Engine Adapters Engine Queries Extensions Host visual debugger API
  • 20. expressed question data data question
  • 21. Tell me the just the color of each car that passes. var result = from car in carStream select new { car.Color };
  • 22. Give me only trucks. var result = from car in carStream where car.Type == “Truck” select car;
  • 23. Tell me the number of cars passed every 10 seconds. var result = from win in carStream.TumblingWindow( TimeSpan.FromSeconds(10)) select new { count = win.Count() };
  • 24. var result = from win in carStream.TumblingWindow( TimeSpan.FromSeconds(10)) select new { count = win.Count() };
  • 25.
  • 26. Count the number of cars for each make separately every 10 seconds. var result = from car in carStream group car by car.make into eachGroup from win in carStream.TumblingWindow( TimeSpan.FromSeconds(10)) select new { make = eachGroup.Key, count = win.Count() };
  • 28.
  • 29.
  • 30. public void EnqueueEvent(SourceData d) { var ev = CreateInsertEvent(); ev.Payload = new MouseEvent { Id = d.id, Value = d.value }; ev.StartTime = d.timestamp; Enqueue(ref ev); }
  • 31. public void EnqueueEvent(SourceData d) { if AdapterState return var ev = CreateInsertEvent(); ev.Payload = new MouseEvent { Id = d.id, Value = d.value }; ev.StartTime = d.timestamp; Enqueue(ref ev); }
  • 32. public void EnqueueEvent(SourceData d) { if AdapterState return var ev = CreateInsertEvent(); if (ev == null) return; ev.Payload = new MouseEvent { Id = d.id, Value = d.value }; ev.StartTime = d.timestamp; Enqueue(ref ev); }
  • 33. public void EnqueueEvent(SourceData d) { if AdapterState return var ev = CreateInsertEvent(); if (ev == null) return; ev.Payload = new MouseEvent { Id = d.id, Value = d.value }; ev.StartTime = d.timestamp; if (Enqueue(ref ev) == EnqueueOperationResult.Full) { Ready(); return; } }
  • 35. public class TimeWeightedAverage : CepTimeSensitiveAggregate<double, double> { public override double GenerateOutput(IEnumerable<IntervalEvent<double>> events, WindowDescriptor windowDescriptor) { double avg = 0; foreach (IntervalEvent<double> ev in events) { avg += intervalEvent.Payload * (ev.EndTime - ev.StartTime).Ticks; } return = avg / (windowDescriptor.EndTime – windowDescriptor.StartTime).Ticks; } }
  • 36.
  • 37. To learn more or inquire about speaking opportunities, please contact: Mark Ginnebaugh, User Group Leader mark@designmind.com