SlideShare a Scribd company logo
1 of 9
Node.js access to Oracle Db ,[object Object]
Data in 4 Easy Steps Node pub/sub with Redis Java pub/sub with Redis Java does query with message from Node Java publishes result set Async provides patterns for control flow
Java client receives a message containing the text to a query or stored procedure It processes the message by performing the request It returns the Result as a JSONArray of Jason Objects.
Lines 4 – 9, create 2 pairs of pub/sub clients Line 12-13, 15-16, when ready, subscribe to the results which is the JSONArray of JSONObjects Node.js
For query and storedProc, when a message is received, send it to the cb callback provided by Async. Publish the query or storedProc that was passed . Node.js
When processing is complete the node client ends the sub / pub connection. Node.js
Async provides parallel control flow.  On line 10, the query function publishes it's message as does the storedProc function on line 24. Node.js test client
Continuing... Parallel control calls the anonymous function on line 32.  The results obj contains the JSONArray data.  After logging the results, the pub / sub is ended. Node.js test client
All open source. For complete write up see http://barton-notestomyself.blogspot.com/2011/12/nodejs-oracle-db-not-so-bad-union.html  Node.js Oracle db Pub/Sub

More Related Content

What's hot (13)

Mule esb How to convert from CSV to Json in 5 minutes
Mule esb How to convert from CSV to Json in 5 minutesMule esb How to convert from CSV to Json in 5 minutes
Mule esb How to convert from CSV to Json in 5 minutes
 
xslt in mule
xslt in mulexslt in mule
xslt in mule
 
Mule Ajax Connector
Mule Ajax ConnectorMule Ajax Connector
Mule Ajax Connector
 
Apache lb
Apache lbApache lb
Apache lb
 
Integrate with database by groovy
Integrate with database by groovyIntegrate with database by groovy
Integrate with database by groovy
 
Play Framework
Play FrameworkPlay Framework
Play Framework
 
Lambda expressions java8 - yousry
Lambda expressions java8 - yousryLambda expressions java8 - yousry
Lambda expressions java8 - yousry
 
Json to json transformation in mule
Json to json transformation in muleJson to json transformation in mule
Json to json transformation in mule
 
User Camp High Availability Presentation
User Camp High Availability PresentationUser Camp High Availability Presentation
User Camp High Availability Presentation
 
Boulder_OneStop_presentation
Boulder_OneStop_presentationBoulder_OneStop_presentation
Boulder_OneStop_presentation
 
UltraESB - Advanced services
UltraESB - Advanced servicesUltraESB - Advanced services
UltraESB - Advanced services
 
Encrypting/Decrypting mule
Encrypting/Decrypting  muleEncrypting/Decrypting  mule
Encrypting/Decrypting mule
 
Introduction to AdroitLogic and UltraESB
Introduction to AdroitLogic and UltraESBIntroduction to AdroitLogic and UltraESB
Introduction to AdroitLogic and UltraESB
 

Similar to Node.js and Oracle db - Pub/Sub with Redis

Scripts Python Dbapi
Scripts Python DbapiScripts Python Dbapi
Scripts Python Dbapi
AkramWaseem
 
Asynchronous I/O in NodeJS - new standard or challenges?
Asynchronous I/O in NodeJS - new standard or challenges?Asynchronous I/O in NodeJS - new standard or challenges?
Asynchronous I/O in NodeJS - new standard or challenges?
Dinh Pham
 

Similar to Node.js and Oracle db - Pub/Sub with Redis (20)

Java web services using JAX-WS
Java web services using JAX-WSJava web services using JAX-WS
Java web services using JAX-WS
 
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...
 
Yet another json rpc library (mole rpc)
Yet another json rpc library (mole rpc)Yet another json rpc library (mole rpc)
Yet another json rpc library (mole rpc)
 
Arpita industrial trainingppt
Arpita industrial trainingpptArpita industrial trainingppt
Arpita industrial trainingppt
 
Nodejs vatsal shah
Nodejs vatsal shahNodejs vatsal shah
Nodejs vatsal shah
 
Advance Java Practical file
Advance Java Practical fileAdvance Java Practical file
Advance Java Practical file
 
node.js.pptx
node.js.pptxnode.js.pptx
node.js.pptx
 
Database Access With JDBC
Database Access With JDBCDatabase Access With JDBC
Database Access With JDBC
 
NodeJS guide for beginners
NodeJS guide for beginnersNodeJS guide for beginners
NodeJS guide for beginners
 
JDBC
JDBCJDBC
JDBC
 
4-INTERDUCATION TO JDBC-2019.ppt
4-INTERDUCATION TO JDBC-2019.ppt4-INTERDUCATION TO JDBC-2019.ppt
4-INTERDUCATION TO JDBC-2019.ppt
 
Jdbc ppt
Jdbc pptJdbc ppt
Jdbc ppt
 
Introduction to Node.JS
Introduction to Node.JSIntroduction to Node.JS
Introduction to Node.JS
 
RESTful API In Node Js using Express
RESTful API In Node Js using Express RESTful API In Node Js using Express
RESTful API In Node Js using Express
 
Scripts Python Dbapi
Scripts Python DbapiScripts Python Dbapi
Scripts Python Dbapi
 
NodeJS @ ACS
NodeJS @ ACSNodeJS @ ACS
NodeJS @ ACS
 
ASP.NET vNext ANUG 20140817
ASP.NET vNext ANUG 20140817ASP.NET vNext ANUG 20140817
ASP.NET vNext ANUG 20140817
 
Node js Introduction
Node js IntroductionNode js Introduction
Node js Introduction
 
Asynchronous I/O in NodeJS - new standard or challenges?
Asynchronous I/O in NodeJS - new standard or challenges?Asynchronous I/O in NodeJS - new standard or challenges?
Asynchronous I/O in NodeJS - new standard or challenges?
 
Kalp Corporate Node JS Perfect Guide
Kalp Corporate Node JS Perfect GuideKalp Corporate Node JS Perfect Guide
Kalp Corporate Node JS Perfect Guide
 

Recently uploaded

IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 

Recently uploaded (20)

04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
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)
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
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
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
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
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
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
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
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
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 

Node.js and Oracle db - Pub/Sub with Redis

  • 1.
  • 2. Data in 4 Easy Steps Node pub/sub with Redis Java pub/sub with Redis Java does query with message from Node Java publishes result set Async provides patterns for control flow
  • 3. Java client receives a message containing the text to a query or stored procedure It processes the message by performing the request It returns the Result as a JSONArray of Jason Objects.
  • 4. Lines 4 – 9, create 2 pairs of pub/sub clients Line 12-13, 15-16, when ready, subscribe to the results which is the JSONArray of JSONObjects Node.js
  • 5. For query and storedProc, when a message is received, send it to the cb callback provided by Async. Publish the query or storedProc that was passed . Node.js
  • 6. When processing is complete the node client ends the sub / pub connection. Node.js
  • 7. Async provides parallel control flow. On line 10, the query function publishes it's message as does the storedProc function on line 24. Node.js test client
  • 8. Continuing... Parallel control calls the anonymous function on line 32. The results obj contains the JSONArray data. After logging the results, the pub / sub is ended. Node.js test client
  • 9. All open source. For complete write up see http://barton-notestomyself.blogspot.com/2011/12/nodejs-oracle-db-not-so-bad-union.html Node.js Oracle db Pub/Sub