Skip to main content

Notes on Real Time Data Processing



Real time is real hot right now. Days became hours, hours became minutes, minutes became seconds, seconds became nano seconds. Time is money. Go ahead. Show me the money. This is the mantra from all of hardware and software vendors. Do the analytics in real time. Your decisions, results and revenues will automatically jump up. When you perform a database transaction, events are triggered by exchange of messages using some protocol. The systems are recording changes as the event are unfolding. Analysis of this data should happen immediately after the event.  So, colloquially, real time processing is analysis of data as the event is unfolding. 

But, What is real time?

In all of cosmos, there is one, just one phenomenon we know happening in real time.  EPR thought experiment was invented by Einstein, Podolsky, Rosen to show quantum theory was an incomplete explanation of reality.  Simply put, it shows the information can travel the length of the universe — instantly. This violates Einstein's special theory of relativity which states that nothing can travel faster than light. Experiments have shown EPR's REAL TIME effect, seemingly faster than light, does happen. Such is the strange quantum world. See http://en.wikipedia.org/wiki/EPR_paradox, if you’re curious about more information. 

So, in physics, you  hardly hear about real time travel or information processing.  Speed of information travel, except in quantum world, is restricted by speed of light.


Real Time in Software. 

Computer science and software, of course, won’t be bothered with such constraints.  Everything from streaming, fast data ingestion, messaging, business intelligence to queries on the stream claim real time computing.  There is, however,a restrictive and reasonable definition of real-time computing in Wikepedia:  hardware and software systems that are subject to a "real-time constraint", for example operational deadlines from event to system response. Real-time programs must guarantee response within strict time constraints, often referred to as "deadlines". The “real-time constraint” can be defined exactly in cases where violation has immediate effect, like fire extinguisher, furnace temperature monitor, etc.

In other cases, e.g. stock trade or option trading, real time means doing it faster than competition to maximize revenue & profit.  The faster you do it, the higher is the revenue/profit possibility. So, for that, what’s the limit? Nano second? Planck second? Here, every nano second counts. Every type of bandwidth counts. Every optimization counts.  All to save precious time.

So, it's important to realize which use case your real time system is handling -- whether you're time-bound to ensure you avoid catastrophe or you're chasing time's tail to maximize profit. Once you determine your constraint, it's easier to design systems, select the right architecture & tools to achieve that.

For interesting evolution of the term real time, see Phillip Laplante's article on It Isn’t Your Father’s Realtime Anymore at: http://queue.acm.org/detail.cfm?id=1117409

Comments

Popular posts from this blog

MongoDB to Couchbase for Developers: Part 2: Database Objects

    MongoDB developers and DBAs work with physical clusters, machines, instances, storage systems, disks, etc. All MongoDB users, developers, and their applications work with logical entities: databases, collections, documents, fields, shards, users, data types.  There are a lot of similarities with Couchbase since both are document (JSON) oriented databases.  Let’s compare and contrast the two with respect to database objects.  Here’s the first part of this series comparing the architecture.   MongoDB Organization A full list of MongoDB schema objects is listed here and here . A database instance can have many databases; A database can have many collections; Each collection can have many indexes.  Each collection can be sharded based into multiple chunks on multiple nodes of a cluster using hash-sharding strategy or index sharding strategy.  The MongoDB indexes are local to their data.  Therefore, the indexes use the same strategy as ...

Swami Vivekananda: The Monk That Nobody Sent to Chicago

  There’s a saying in Chicago: “We don’t want nobody that nobody sent.” This was the cold reception Swami Vivekananda faced when he arrived in the windy city in July 1893, determined to attend the World Parliament of Religions that September. He belonged to no organization, carried no letter of recommendation, his countrymen were nobody, and represented an alien religion to the Western world. As the days passed, his hope of attending the parliament dwindled. With money running out and the odds stacked against him, he left the Windy City and went to Boston, praying for a glimmer of opportunity.  Swamiji came to America to share India’s most profound gift: the wisdom of the Hindu sages, preserved through centuries of oral tradition and embodied by its monks. This was 1893, not 1993—India was under the British grip, its resources drained, and its spirit subdued. Swamiji’s mission was not just a cultural exchange; it was a bold step toward envisioning a future where India could re...

MongoDB to Couchbase for Developers: Part 1: Architecture

  Introduction By any measure, MongoDB is a popular document-oriented JSON database. In the last dozen years, it has grown from its humble beginnings of a single lock per database to a modern multi-document transaction with snapshot isolation. MongoDB University has trained a large number of developers to develop the MongoDB database. There are many JSON databases now. While it's easy to start with MongoDB to learn NoSQL and flexible JSON schema, many customers choose Couchbase for performance, scale, and SQL. As you progress in your database evaluation and evolution, it's easier to start from what you know now. That's the idea for this series. Use your MongoDB knowledge to easily learn and eventually master Couchbase.  Don't despair if you don't know MongoDB do know any one of the RDBMS. This Oracle to Couchbase series will help you learn by comparison.  Many nations are known by their language: French, German, Spanish). Many databases are known for their language...