SlideShare ist ein Scribd-Unternehmen logo
1 von 49
Downloaden Sie, um offline zu lesen
How Watson, Bluemix, Cloudant, and
XPages Can Work Together In A Real
World Application
Frank van der Linden, elstar IT
Full stack Java Developer
WCS-1785
IBM InterConnect 2017 Conference
Me
• Freelance Full stack Java developer
• Owner of elstar IT
• Curious of new technology
• IBM Champion 2013, 2014 and 2017
• Run (mountain) marathons
How do we proceed
• HR Assistant
• Running it on IBM Bluemix
• Store it in Cloudant
• Analyse it with IBM Watson
• Show it with Charts
• Lessons learned
HR Assistant
Demo time
Frédéric Dehédin
• At the time of the project: Senior Application developer
at Belsoft Collaboration AG
• @fdehedin
• http://www.fdehedin.ch/
Facts
• Winner of the ICS Developer Competition 2016
• Runs on the XSP runtime on IBM Bluemix
• Store all the data in Cloudant
• Analyse jobs and job applications with IBM Watson
• Backend is pure Java, no Java Notes objects
Add ons
• Cloudant connector OSGi plugin
• Take out the security issue
• Storing in and retrieving from Cloudant. JSON <—> POJO
• Can be accessed from Java backend.
• Do the heavy lifting. Don't reinvent the wheel.
Add ons
• Jackson Mapper OSGi plugin
• Take out the security issue
• Used with the IBM Watson services
• Conversion of JSON to POJO
• Makes @Annotations available in Java back end
Roadmap
Running it on IBM Bluemix
Overview
• Bluemix is IBM PaaS, with various services
• We picked a few services
Credentials
Deploy to IBM Bluemix
• Fill the Bluemix Manifest file under
Application Configuration
• Will result in a yaml file
Deploy to IBM Bluemix
• Set location of deployment
• Add shared-plugin folder
• Add the OSGi plugins
Deploy to IBM Bluemix
• Deploy Application
Store it in Cloudant
What is Cloudant
• It is the cloud version of CouchDb
• It is document based
• CouchDb is created by Damien Katz
• Cloudant is bought by IBM
• Is like MongoDb or NSF a NoSQL datastore
What is Cloudant
• Data stored as JSON
• View and Search ‘formula’ defined in javascript
• Replication
• Tasks
• Build in API
• No annoying limitations
Cloudant database
Design document
• Special type of document
• Holds javascript for View and FT Search definition.
• It is JSON everywhere.
• _rev and _id are reserved parameters.
• doc{}, is the actual data from application
Document
Attachment @ Cloudant
• Stored as base64 encoded String
• Can be as standalone
• Or as part of Document (we choose this way)
• Store id as attachmentId, so it can be retrieved when needed
Attachment @ Cloudant
• AttachmentDAO
Attachment @ Cloudant
• AttachmentController
• Convert upload to Attachment
object
Attachment @ Cloudant
• ControllerBase
• All controllers can use these methods
Attachment @ Cloudant
• Servlet is called in application for download
• base64 data for the image tag
Analyse it with IBM Watson
Watson API explorer
• Very useful to test input and see what is returned
Services we used
• Tone analyser, to get the tone of the text
• Personality Insight, to determine the personality of the job applicant
• AlchemyLanguage, to get the keywords from the Job and Job
application (now "Watson Natural Language Understanding”)
tone analyser schema
Tone analyser
• The same structure to call the Watson services
Tone analyser
• ToneAnalyzerRequest contain the text to analyse
• ToneAnalyzerInjector gets text from model class
Tone analyser
• Post the data to IBM Watson service (1)
• Convert the response back to Java class (2)
1
2
Tone analyser
• ToneAnalyzerResponse holds the results
• Use @annotations from Jackson to map
JSON to properties
• Result is the source of the charts
Show it with charts
ChartJS
• Open source HTML5 javascript based
• Responsive
• DataSets = Array of Objects
ChartJS
• Factory to produce the chart data, accepts objects
• Factory set default Chart Type, like Radar or Bar
ChartJS
ChartJS
• Custom control to display data
ChartJS
• Custom control to display data.
Lessons learned
Lessons learned
• No Single Sign On service on all datacenters
• Manifest yaml file and GIT are not an happy couple
• API’s are not consistent across Watson services
• Cloudant is a very reliable, flexible and fast NoSQL datastore
• IBM Watson services are really powerful.
Lessons learned
• There is no RichText on the web, it is HTML
• Handling attachments on Cloudant was a challenge. Took some time get a
robust solution.
• BTW the way, we won the competition ;-)
Questions
3:30 PM - 4:00 PM
Meet the IBM Champion desk
Bayside Level 1
Resources
• HR Assistant on Bluemix
• https://hrassistant.eu-gb.mybluemix.net/
• HR Assistant code on GitHub
• https://github.com/flinden68/HR-Assistant
• IBM Watson services
• https://www.ibm.com/watson/developercloud/services-catalog.html
• IBM Cloudant documentation
• https://docs.cloudant.com/
• HR Assistant Demo
• https://youtu.be/yM5Foxn9Fvg
Resources
• OSGi Cloudant connector
• https://bitbucket.org/flinden68/cloudant-connector
• OSGi Jackson JSON Wrapper
• https://bitbucket.org/flinden68/jackson-json-mapper-plugin
• ChartJS
• http://www.chartjs.org/
• Watson API Explorer
• https://watson-api-explorer.mybluemix.net/
Reach out to me
• @flinden68
• http://www.elstarit.nl
• flinden68@elstarit.nl
• https://nl.linkedin.com/in/flinden68

Weitere ähnliche Inhalte

Was ist angesagt?

SQL Azure Dec Update
SQL Azure Dec UpdateSQL Azure Dec Update
SQL Azure Dec Update
Eric Nelson
 

Was ist angesagt? (20)

MongoDB World 2018: Replatforming: Switching to MongoDB for Flexibility, Scal...
MongoDB World 2018: Replatforming: Switching to MongoDB for Flexibility, Scal...MongoDB World 2018: Replatforming: Switching to MongoDB for Flexibility, Scal...
MongoDB World 2018: Replatforming: Switching to MongoDB for Flexibility, Scal...
 
MongoDB World 2018: Solving Your Backup Needs Using MongoDB Ops Manager, Clou...
MongoDB World 2018: Solving Your Backup Needs Using MongoDB Ops Manager, Clou...MongoDB World 2018: Solving Your Backup Needs Using MongoDB Ops Manager, Clou...
MongoDB World 2018: Solving Your Backup Needs Using MongoDB Ops Manager, Clou...
 
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
DC Titanium User Group Meetup: Appcelerator Titanium Alloy jan2013
 
Dev ops-presentation
Dev ops-presentationDev ops-presentation
Dev ops-presentation
 
Maxis Alchemize imug 2017
Maxis Alchemize imug 2017Maxis Alchemize imug 2017
Maxis Alchemize imug 2017
 
Architectural Patterns for Scaling Microservices and APIs - GlueCon 2015
Architectural Patterns for Scaling Microservices and APIs - GlueCon 2015Architectural Patterns for Scaling Microservices and APIs - GlueCon 2015
Architectural Patterns for Scaling Microservices and APIs - GlueCon 2015
 
Azure functions
Azure functionsAzure functions
Azure functions
 
When Our Serverless Team Chooses Containers
When Our Serverless Team Chooses ContainersWhen Our Serverless Team Chooses Containers
When Our Serverless Team Chooses Containers
 
The Serverless Native Mindset: Ben Kehoe, iRobot, Serverless NYC 2018
The Serverless Native Mindset: Ben Kehoe, iRobot, Serverless NYC 2018The Serverless Native Mindset: Ben Kehoe, iRobot, Serverless NYC 2018
The Serverless Native Mindset: Ben Kehoe, iRobot, Serverless NYC 2018
 
The Future of Data Engineering - 2019 InfoQ QConSF
The Future of Data Engineering - 2019 InfoQ QConSFThe Future of Data Engineering - 2019 InfoQ QConSF
The Future of Data Engineering - 2019 InfoQ QConSF
 
Hybrid Integration with BizTalk Server - ACSUG
Hybrid Integration with BizTalk Server - ACSUGHybrid Integration with BizTalk Server - ACSUG
Hybrid Integration with BizTalk Server - ACSUG
 
SQL Azure Dec Update
SQL Azure Dec UpdateSQL Azure Dec Update
SQL Azure Dec Update
 
In Memory Databases: A Real Time Analytics Solution
In Memory Databases: A Real Time Analytics SolutionIn Memory Databases: A Real Time Analytics Solution
In Memory Databases: A Real Time Analytics Solution
 
Microsoft Machine Learning Smackdown
Microsoft Machine Learning SmackdownMicrosoft Machine Learning Smackdown
Microsoft Machine Learning Smackdown
 
Building the Serverless Container Experience: Kevin McGrath, Spotinst, Server...
Building the Serverless Container Experience: Kevin McGrath, Spotinst, Server...Building the Serverless Container Experience: Kevin McGrath, Spotinst, Server...
Building the Serverless Container Experience: Kevin McGrath, Spotinst, Server...
 
Keep Calm And Serilog Elasticsearch Kibana on .NET Core
Keep Calm And Serilog Elasticsearch Kibana on .NET CoreKeep Calm And Serilog Elasticsearch Kibana on .NET Core
Keep Calm And Serilog Elasticsearch Kibana on .NET Core
 
Presto Summit 2018 - 02 - LinkedIn
Presto Summit 2018  - 02 - LinkedInPresto Summit 2018  - 02 - LinkedIn
Presto Summit 2018 - 02 - LinkedIn
 
A Multi-Tenancy Cloud-Native Digital Library Platform
A Multi-Tenancy Cloud-Native Digital Library PlatformA Multi-Tenancy Cloud-Native Digital Library Platform
A Multi-Tenancy Cloud-Native Digital Library Platform
 
Integration Monday - BizTalk Migrator Deep Dive
Integration Monday - BizTalk Migrator Deep DiveIntegration Monday - BizTalk Migrator Deep Dive
Integration Monday - BizTalk Migrator Deep Dive
 
Technology Roadmap by ericnel
Technology Roadmap by ericnelTechnology Roadmap by ericnel
Technology Roadmap by ericnel
 

Ähnlich wie Wcs-1785 How Watson, Bluemix, Cloudant and XPages can work together in a real world application

Netflix oss season 2 episode 1 - meetup Lightning talks
Netflix oss   season 2 episode 1 - meetup Lightning talksNetflix oss   season 2 episode 1 - meetup Lightning talks
Netflix oss season 2 episode 1 - meetup Lightning talks
Ruslan Meshenberg
 
Cloud computing workshop at IIT bombay
Cloud computing workshop at IIT bombayCloud computing workshop at IIT bombay
Cloud computing workshop at IIT bombay
Nilesh Satpute
 

Ähnlich wie Wcs-1785 How Watson, Bluemix, Cloudant and XPages can work together in a real world application (20)

DEV03 - How Watson, Bluemix, Cloudant, and XPages Can Work Together In A Real...
DEV03 - How Watson, Bluemix, Cloudant, and XPages Can Work Together In A Real...DEV03 - How Watson, Bluemix, Cloudant, and XPages Can Work Together In A Real...
DEV03 - How Watson, Bluemix, Cloudant, and XPages Can Work Together In A Real...
 
Cloudant e XPages
Cloudant e XPagesCloudant e XPages
Cloudant e XPages
 
9 - Making Sense of Containers in the Microsoft Cloud
9 - Making Sense of Containers in the Microsoft Cloud9 - Making Sense of Containers in the Microsoft Cloud
9 - Making Sense of Containers in the Microsoft Cloud
 
Windows 8 Apps and the Outside World
Windows 8 Apps and the Outside WorldWindows 8 Apps and the Outside World
Windows 8 Apps and the Outside World
 
Container Orchestration for .NET Developers
Container Orchestration for .NET DevelopersContainer Orchestration for .NET Developers
Container Orchestration for .NET Developers
 
Utilizing the open ntf domino api
Utilizing the open ntf domino apiUtilizing the open ntf domino api
Utilizing the open ntf domino api
 
Mongo DB at Community Engine
Mongo DB at Community EngineMongo DB at Community Engine
Mongo DB at Community Engine
 
MongoDB at community engine
MongoDB at community engineMongoDB at community engine
MongoDB at community engine
 
MEAN Stack Warm-up
MEAN Stack Warm-upMEAN Stack Warm-up
MEAN Stack Warm-up
 
Working and Features of HTML5 and PhoneGap - An Overview
Working and Features of HTML5 and PhoneGap - An OverviewWorking and Features of HTML5 and PhoneGap - An Overview
Working and Features of HTML5 and PhoneGap - An Overview
 
AWS for Java Developers workshop
AWS for Java Developers workshopAWS for Java Developers workshop
AWS for Java Developers workshop
 
Ibm db2update2019 icp4 data
Ibm db2update2019   icp4 dataIbm db2update2019   icp4 data
Ibm db2update2019 icp4 data
 
Netflix oss season 2 episode 1 - meetup Lightning talks
Netflix oss   season 2 episode 1 - meetup Lightning talksNetflix oss   season 2 episode 1 - meetup Lightning talks
Netflix oss season 2 episode 1 - meetup Lightning talks
 
GraphDb in XPages
GraphDb in XPagesGraphDb in XPages
GraphDb in XPages
 
Introduction to node.js aka NodeJS
Introduction to node.js aka NodeJSIntroduction to node.js aka NodeJS
Introduction to node.js aka NodeJS
 
Cloud computing workshop at IIT bombay
Cloud computing workshop at IIT bombayCloud computing workshop at IIT bombay
Cloud computing workshop at IIT bombay
 
AWS re:Invent 2016: Workshop: Using the Database Migration Service (DMS) for ...
AWS re:Invent 2016: Workshop: Using the Database Migration Service (DMS) for ...AWS re:Invent 2016: Workshop: Using the Database Migration Service (DMS) for ...
AWS re:Invent 2016: Workshop: Using the Database Migration Service (DMS) for ...
 
IBM - Introduction to Cloudant
IBM - Introduction to CloudantIBM - Introduction to Cloudant
IBM - Introduction to Cloudant
 
0812 2014 01_toronto-smac meetup_i_os_cloudant_worklight_part2
0812 2014 01_toronto-smac meetup_i_os_cloudant_worklight_part20812 2014 01_toronto-smac meetup_i_os_cloudant_worklight_part2
0812 2014 01_toronto-smac meetup_i_os_cloudant_worklight_part2
 
With Automated ML, is Everyone an ML Engineer?
With Automated ML, is Everyone an ML Engineer?With Automated ML, is Everyone an ML Engineer?
With Automated ML, is Everyone an ML Engineer?
 

Mehr von Frank van der Linden

how to connect your app to the activity stream with x-pages
how to connect your app to the activity stream with x-pageshow to connect your app to the activity stream with x-pages
how to connect your app to the activity stream with x-pages
Frank van der Linden
 

Mehr von Frank van der Linden (20)

Engage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyEngage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The Ugly
 
Engage 2020: Hello are you listening, There is stream for everything
Engage 2020: Hello are you listening, There is stream for everythingEngage 2020: Hello are you listening, There is stream for everything
Engage 2020: Hello are you listening, There is stream for everything
 
NCUG 2019: Super charge your API’s with Reactive streams
NCUG 2019: Super charge your API’s with Reactive streamsNCUG 2019: Super charge your API’s with Reactive streams
NCUG 2019: Super charge your API’s with Reactive streams
 
NCUG 2019: Spring forward: an introduction to Spring boot and Thymeleaf for (...
NCUG 2019: Spring forward: an introduction to Spring boot and Thymeleaf for (...NCUG 2019: Spring forward: an introduction to Spring boot and Thymeleaf for (...
NCUG 2019: Spring forward: an introduction to Spring boot and Thymeleaf for (...
 
Engage 2019: The good, the bad and the ugly: a not so objective view on front...
Engage 2019: The good, the bad and the ugly: a not so objective view on front...Engage 2019: The good, the bad and the ugly: a not so objective view on front...
Engage 2019: The good, the bad and the ugly: a not so objective view on front...
 
Social connections14: Super charge your API’s with Reactive streams
Social connections14: Super charge your API’s with Reactive streamsSocial connections14: Super charge your API’s with Reactive streams
Social connections14: Super charge your API’s with Reactive streams
 
Icon UK 2018 - Spring forward: an introduction to Spring boot and Thymeleaf f...
Icon UK 2018 - Spring forward: an introduction to Spring boot and Thymeleaf f...Icon UK 2018 - Spring forward: an introduction to Spring boot and Thymeleaf f...
Icon UK 2018 - Spring forward: an introduction to Spring boot and Thymeleaf f...
 
Spring forward: an introduction to Spring boot and Thymeleaf
Spring forward: an introduction to Spring boot and ThymeleafSpring forward: an introduction to Spring boot and Thymeleaf
Spring forward: an introduction to Spring boot and Thymeleaf
 
A (XPages) developers guide to Cloudant
A (XPages) developers guide to CloudantA (XPages) developers guide to Cloudant
A (XPages) developers guide to Cloudant
 
Let's serve your data
Let's serve your dataLet's serve your data
Let's serve your data
 
Let's server your Data
Let's server your DataLet's server your Data
Let's server your Data
 
Don't worry with bower
Don't worry with bowerDon't worry with bower
Don't worry with bower
 
Bccon use notes objects in memory and other useful
Bccon   use notes objects in memory and other usefulBccon   use notes objects in memory and other useful
Bccon use notes objects in memory and other useful
 
Use notes objects in memory and other useful java tips for xpages development
Use notes objects in memory and other useful java tips for xpages developmentUse notes objects in memory and other useful java tips for xpages development
Use notes objects in memory and other useful java tips for xpages development
 
An XPager's Guide to Process Server-Side Jobs on Domino
An XPager's Guide to Process Server-Side Jobs on DominoAn XPager's Guide to Process Server-Side Jobs on Domino
An XPager's Guide to Process Server-Side Jobs on Domino
 
The power of dots
The power of dotsThe power of dots
The power of dots
 
Let me introduce you: DOTS
Let me introduce you: DOTSLet me introduce you: DOTS
Let me introduce you: DOTS
 
Integrate domino designer with cvs source control
Integrate domino designer with cvs source controlIntegrate domino designer with cvs source control
Integrate domino designer with cvs source control
 
how to connect your app to the activity stream with x-pages
how to connect your app to the activity stream with x-pageshow to connect your app to the activity stream with x-pages
how to connect your app to the activity stream with x-pages
 
Uklug2012 yellow and blue stream
Uklug2012 yellow and blue streamUklug2012 yellow and blue stream
Uklug2012 yellow and blue stream
 

Kürzlich hochgeladen

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
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 

Kürzlich hochgeladen (20)

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
 
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
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
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
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
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...
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.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
 
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
 
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
 
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
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
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
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
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...
 

Wcs-1785 How Watson, Bluemix, Cloudant and XPages can work together in a real world application

  • 1. How Watson, Bluemix, Cloudant, and XPages Can Work Together In A Real World Application Frank van der Linden, elstar IT Full stack Java Developer WCS-1785 IBM InterConnect 2017 Conference
  • 2. Me • Freelance Full stack Java developer • Owner of elstar IT • Curious of new technology • IBM Champion 2013, 2014 and 2017 • Run (mountain) marathons
  • 3. How do we proceed • HR Assistant • Running it on IBM Bluemix • Store it in Cloudant • Analyse it with IBM Watson • Show it with Charts • Lessons learned
  • 6.
  • 7. Frédéric Dehédin • At the time of the project: Senior Application developer at Belsoft Collaboration AG • @fdehedin • http://www.fdehedin.ch/
  • 8. Facts • Winner of the ICS Developer Competition 2016 • Runs on the XSP runtime on IBM Bluemix • Store all the data in Cloudant • Analyse jobs and job applications with IBM Watson • Backend is pure Java, no Java Notes objects
  • 9. Add ons • Cloudant connector OSGi plugin • Take out the security issue • Storing in and retrieving from Cloudant. JSON <—> POJO • Can be accessed from Java backend. • Do the heavy lifting. Don't reinvent the wheel.
  • 10. Add ons • Jackson Mapper OSGi plugin • Take out the security issue • Used with the IBM Watson services • Conversion of JSON to POJO • Makes @Annotations available in Java back end
  • 12. Running it on IBM Bluemix
  • 13. Overview • Bluemix is IBM PaaS, with various services • We picked a few services
  • 15. Deploy to IBM Bluemix • Fill the Bluemix Manifest file under Application Configuration • Will result in a yaml file
  • 16. Deploy to IBM Bluemix • Set location of deployment • Add shared-plugin folder • Add the OSGi plugins
  • 17. Deploy to IBM Bluemix • Deploy Application
  • 18. Store it in Cloudant
  • 19. What is Cloudant • It is the cloud version of CouchDb • It is document based • CouchDb is created by Damien Katz • Cloudant is bought by IBM • Is like MongoDb or NSF a NoSQL datastore
  • 20. What is Cloudant • Data stored as JSON • View and Search ‘formula’ defined in javascript • Replication • Tasks • Build in API • No annoying limitations
  • 22. Design document • Special type of document • Holds javascript for View and FT Search definition.
  • 23. • It is JSON everywhere. • _rev and _id are reserved parameters. • doc{}, is the actual data from application Document
  • 24. Attachment @ Cloudant • Stored as base64 encoded String • Can be as standalone • Or as part of Document (we choose this way) • Store id as attachmentId, so it can be retrieved when needed
  • 25. Attachment @ Cloudant • AttachmentDAO
  • 26. Attachment @ Cloudant • AttachmentController • Convert upload to Attachment object
  • 27. Attachment @ Cloudant • ControllerBase • All controllers can use these methods
  • 28. Attachment @ Cloudant • Servlet is called in application for download • base64 data for the image tag
  • 29. Analyse it with IBM Watson
  • 30. Watson API explorer • Very useful to test input and see what is returned
  • 31. Services we used • Tone analyser, to get the tone of the text • Personality Insight, to determine the personality of the job applicant • AlchemyLanguage, to get the keywords from the Job and Job application (now "Watson Natural Language Understanding”)
  • 33. Tone analyser • The same structure to call the Watson services
  • 34. Tone analyser • ToneAnalyzerRequest contain the text to analyse • ToneAnalyzerInjector gets text from model class
  • 35. Tone analyser • Post the data to IBM Watson service (1) • Convert the response back to Java class (2) 1 2
  • 36. Tone analyser • ToneAnalyzerResponse holds the results • Use @annotations from Jackson to map JSON to properties • Result is the source of the charts
  • 37. Show it with charts
  • 38. ChartJS • Open source HTML5 javascript based • Responsive • DataSets = Array of Objects
  • 39. ChartJS • Factory to produce the chart data, accepts objects • Factory set default Chart Type, like Radar or Bar
  • 41. ChartJS • Custom control to display data
  • 42. ChartJS • Custom control to display data.
  • 44. Lessons learned • No Single Sign On service on all datacenters • Manifest yaml file and GIT are not an happy couple • API’s are not consistent across Watson services • Cloudant is a very reliable, flexible and fast NoSQL datastore • IBM Watson services are really powerful.
  • 45. Lessons learned • There is no RichText on the web, it is HTML • Handling attachments on Cloudant was a challenge. Took some time get a robust solution. • BTW the way, we won the competition ;-)
  • 46. Questions 3:30 PM - 4:00 PM Meet the IBM Champion desk Bayside Level 1
  • 47. Resources • HR Assistant on Bluemix • https://hrassistant.eu-gb.mybluemix.net/ • HR Assistant code on GitHub • https://github.com/flinden68/HR-Assistant • IBM Watson services • https://www.ibm.com/watson/developercloud/services-catalog.html • IBM Cloudant documentation • https://docs.cloudant.com/ • HR Assistant Demo • https://youtu.be/yM5Foxn9Fvg
  • 48. Resources • OSGi Cloudant connector • https://bitbucket.org/flinden68/cloudant-connector • OSGi Jackson JSON Wrapper • https://bitbucket.org/flinden68/jackson-json-mapper-plugin • ChartJS • http://www.chartjs.org/ • Watson API Explorer • https://watson-api-explorer.mybluemix.net/
  • 49. Reach out to me • @flinden68 • http://www.elstarit.nl • flinden68@elstarit.nl • https://nl.linkedin.com/in/flinden68