SlideShare una empresa de Scribd logo
1 de 20
Descargar para leer sin conexión
W E B V E V E R I E T




JavaScript Topic Maps in
  server environments


    Jan Schreiber <jans@ravn.no>

                              Ravn Webveveriet AS, 2010-10-01
                                                                1
Outline
                        • JavaScript
                        • The tmjs Topic Maps engine
                        • Use Case: A PSI Server
                        • Outlook


W E B V E V E R I E T


                                                       2
JavaScript
                        • JavaScript is LISP with a C-like syntax
                        • Virtually every personal computer in
                          the world has at least one JavaScript
                          interpreter installed on it and in active
                          use.




W E B V E V E R I E T


                                                                      3
tmjs
                        • A Topic Maps engine
                        • Written in pure JavaScript
                        • Full TMDM including Variants
                        • TMAPI 2.0-based
                        • In-memory backend, JTM import/
                          export, experimental XTM 2.0 import
                          (requires DOM)

W E B V E V E R I E T


                                                                4
tmjs
                        • Platform independent: All(iPhone &
                          browsers, mobile devices
                                                    modern

                          Android), server-side JavaScript
                        • Unit tests, CXTM tests (partly) & JSLint
                          validating
                        • Small changes to TMAPI due to the lack of
                          method overloading
                        • Syntactic sugar: Supports chaining of
                          TMAPI calls

W E B V E V E R I E T


                                                                      5
Chaining

                        1 tm.createTopic().addSubjectIdentifier(foo).
                        2   createName('bar').getParent().
                        3   createOccurrence(type,'baz').
                        4     addScopingTopic(quux);




W E B V E V E R I E T


                                                                        6
tmjs: Outlook
                        •   More import/export formats: XTM 2.0, CTM
                        •   Complete TMAPI, add more tests, full CXTM
                        •   Persistence:
                            •   Web SQL Database backend
                            •   Persistent backend for Node (couchdb?)
                        •   Later: Query language



W E B V E V E R I E T


                                                                         7
Use Case: A PSI Server


                        • Idea: Start the server with a Topic Map
                          and it will serve information about all
                          Subject Identifiers for a given domain




W E B V E V E R I E T


                                                                    8
• Screenshot node-psi-server


W E B V E V E R I E T


                                                       9
Server-side JavaScript


                        • 1996: Netscape releases LiveWire as
                          part of Netscape Enterprise Server 2.0
                        • 2009: Ryan Dahl writes Node

W E B V E V E R I E T


                                                                   10
Node
                        • A framework for low-level network
                          applications based on Google's V8
                          engine
                        • TCP, DNS and HTTP are first-class
                          protocols
                        • Event-based, asynchronous
                          programming
                        • All I/O is non-blocking
W E B V E V E R I E T


                                                              11
result = db_query(db, "SELECT * FROM topic");




W E B V E V E R I E T


                                                       12
db_query(db, "SELECT * FROM topic", callback);




W E B V E V E R I E T


                                                        13
db_query(db, "SELECT * FROM topic", callback);
       callback = function (err, result) {
                  // ...
       }


W E B V E V E R I E T


                                                        14
1              var tm, servername;
 2              // assumes that the TopicMap object tm has been initialized and
 3              // the topic map in question has been imported successfuly.
 4              // servername is set from a command line parameter
 5              http.createServer(function (req, res) {
 6                      var url = 'http://'+servername+req.url, loc, topic;
 7                      loc = tm.createLocator(url);
 8                      topic = tm.getTopicBySubjectIdentifier(loc);
 9                      if (topic) {
 10                         res.writeHead(200, {'Content-Type': 'text/html'});
 11                         // create a page with information about the PSI
 12                     } else {
 13                         // Not found: create a 404 response
 14                     }
 15                     res.close();
 16             }).listen(80);


W E B V E V E R I E T


                                                                                 15
Use Case: A PSI Server
               • More output formats: XHTML, JTM, XTM
               • Support for logging, caching, templates
               • Configurable list of information elements
                        that are included on generated pages (e.g.
                        dc:description, supertype-subtype)
               • PSI black-listing
               • subj3ct.com integration
W E B V E V E R I E T


                                                                     16
PSI Server: Observations

                        • Easy to implement
                        • It’s really fast: 200+200ms to read the
                          Opera topic map, 1ms to serve a PSI
                          page
                        • tmjs can be used on server and client
                          side    Reuse of application code


W E B V E V E R I E T


                                                                    17
Summary & Outlook

                        • Server side Topic Maps with JavaScript:
                          possible!
                        • Asynchronous TMAPI?
                        • In its current state maybe best suited
                          for low-level applications


W E B V E V E R I E T


                                                                    18
What could it be good for?


                        • TMRAP, TM REST API
                        • SDshare
                        • P2P applications
                        • DNS servers

W E B V E V E R I E T


                                                     19
Questions?

                        Download tmjs now!
                        http://github.com/jansc/tmjs
                        Coming soon:
                        http://github.com/jansc/node-psi-server



W E B V E V E R I E T


                                                                  20

Más contenido relacionado

La actualidad más candente

FreeBSD and Drivers
FreeBSD and DriversFreeBSD and Drivers
FreeBSD and DriversKernel TLV
 
More on bpftrace for MariaDB DBAs and Developers - FOSDEM 2022 MariaDB Devroom
More on bpftrace for MariaDB DBAs and Developers - FOSDEM 2022 MariaDB DevroomMore on bpftrace for MariaDB DBAs and Developers - FOSDEM 2022 MariaDB Devroom
More on bpftrace for MariaDB DBAs and Developers - FOSDEM 2022 MariaDB DevroomValeriy Kravchuk
 
Distributed app development with nodejs and zeromq
Distributed app development with nodejs and zeromqDistributed app development with nodejs and zeromq
Distributed app development with nodejs and zeromqRuben Tan
 
Development and deployment with composer and kite
Development and deployment with composer and kiteDevelopment and deployment with composer and kite
Development and deployment with composer and kiteChristian Opitz
 
LLJVM: LLVM bitcode to JVM bytecode
LLJVM: LLVM bitcode to JVM bytecodeLLJVM: LLVM bitcode to JVM bytecode
LLJVM: LLVM bitcode to JVM bytecodeTakeshi Yamamuro
 
Improving the ZFS Userland-Kernel API with Channel Programs - BSDCAN 2017 - M...
Improving the ZFS Userland-Kernel API with Channel Programs - BSDCAN 2017 - M...Improving the ZFS Userland-Kernel API with Channel Programs - BSDCAN 2017 - M...
Improving the ZFS Userland-Kernel API with Channel Programs - BSDCAN 2017 - M...Matthew Ahrens
 
Monitoraggio del Traffico di Rete Usando Python ed ntop
Monitoraggio del Traffico di Rete Usando Python ed ntopMonitoraggio del Traffico di Rete Usando Python ed ntop
Monitoraggio del Traffico di Rete Usando Python ed ntopPyCon Italia
 
IPv4aaS tutorial and hands-on
IPv4aaS tutorial and hands-onIPv4aaS tutorial and hands-on
IPv4aaS tutorial and hands-onAPNIC
 
NativeBoost
NativeBoostNativeBoost
NativeBoostESUG
 
OpenMP Tutorial for Beginners
OpenMP Tutorial for BeginnersOpenMP Tutorial for Beginners
OpenMP Tutorial for BeginnersDhanashree Prasad
 
High-Performance Networking Using eBPF, XDP, and io_uring
High-Performance Networking Using eBPF, XDP, and io_uringHigh-Performance Networking Using eBPF, XDP, and io_uring
High-Performance Networking Using eBPF, XDP, and io_uringScyllaDB
 
A Sneak Peek of MLIR in TensorFlow
A Sneak Peek of MLIR in TensorFlowA Sneak Peek of MLIR in TensorFlow
A Sneak Peek of MLIR in TensorFlowKoan-Sin Tan
 
Concurrent Programming OpenMP @ Distributed System Discussion
Concurrent Programming OpenMP @ Distributed System DiscussionConcurrent Programming OpenMP @ Distributed System Discussion
Concurrent Programming OpenMP @ Distributed System DiscussionCherryBerry2
 
OSDC 2017 - Casey Callendrello -The evolution of the Container Network Interface
OSDC 2017 - Casey Callendrello -The evolution of the Container Network InterfaceOSDC 2017 - Casey Callendrello -The evolution of the Container Network Interface
OSDC 2017 - Casey Callendrello -The evolution of the Container Network InterfaceNETWAYS
 

La actualidad más candente (17)

FreeBSD and Drivers
FreeBSD and DriversFreeBSD and Drivers
FreeBSD and Drivers
 
More on bpftrace for MariaDB DBAs and Developers - FOSDEM 2022 MariaDB Devroom
More on bpftrace for MariaDB DBAs and Developers - FOSDEM 2022 MariaDB DevroomMore on bpftrace for MariaDB DBAs and Developers - FOSDEM 2022 MariaDB Devroom
More on bpftrace for MariaDB DBAs and Developers - FOSDEM 2022 MariaDB Devroom
 
Distributed app development with nodejs and zeromq
Distributed app development with nodejs and zeromqDistributed app development with nodejs and zeromq
Distributed app development with nodejs and zeromq
 
Development and deployment with composer and kite
Development and deployment with composer and kiteDevelopment and deployment with composer and kite
Development and deployment with composer and kite
 
Open mp intro_01
Open mp intro_01Open mp intro_01
Open mp intro_01
 
LLJVM: LLVM bitcode to JVM bytecode
LLJVM: LLVM bitcode to JVM bytecodeLLJVM: LLVM bitcode to JVM bytecode
LLJVM: LLVM bitcode to JVM bytecode
 
Improving the ZFS Userland-Kernel API with Channel Programs - BSDCAN 2017 - M...
Improving the ZFS Userland-Kernel API with Channel Programs - BSDCAN 2017 - M...Improving the ZFS Userland-Kernel API with Channel Programs - BSDCAN 2017 - M...
Improving the ZFS Userland-Kernel API with Channel Programs - BSDCAN 2017 - M...
 
Monitoraggio del Traffico di Rete Usando Python ed ntop
Monitoraggio del Traffico di Rete Usando Python ed ntopMonitoraggio del Traffico di Rete Usando Python ed ntop
Monitoraggio del Traffico di Rete Usando Python ed ntop
 
IPv4aaS tutorial and hands-on
IPv4aaS tutorial and hands-onIPv4aaS tutorial and hands-on
IPv4aaS tutorial and hands-on
 
MPI n OpenMP
MPI n OpenMPMPI n OpenMP
MPI n OpenMP
 
NativeBoost
NativeBoostNativeBoost
NativeBoost
 
OpenMP Tutorial for Beginners
OpenMP Tutorial for BeginnersOpenMP Tutorial for Beginners
OpenMP Tutorial for Beginners
 
High-Performance Networking Using eBPF, XDP, and io_uring
High-Performance Networking Using eBPF, XDP, and io_uringHigh-Performance Networking Using eBPF, XDP, and io_uring
High-Performance Networking Using eBPF, XDP, and io_uring
 
A Sneak Peek of MLIR in TensorFlow
A Sneak Peek of MLIR in TensorFlowA Sneak Peek of MLIR in TensorFlow
A Sneak Peek of MLIR in TensorFlow
 
Concurrent Programming OpenMP @ Distributed System Discussion
Concurrent Programming OpenMP @ Distributed System DiscussionConcurrent Programming OpenMP @ Distributed System Discussion
Concurrent Programming OpenMP @ Distributed System Discussion
 
S emb t13-freertos
S emb t13-freertosS emb t13-freertos
S emb t13-freertos
 
OSDC 2017 - Casey Callendrello -The evolution of the Container Network Interface
OSDC 2017 - Casey Callendrello -The evolution of the Container Network InterfaceOSDC 2017 - Casey Callendrello -The evolution of the Container Network Interface
OSDC 2017 - Casey Callendrello -The evolution of the Container Network Interface
 

Similar a JavaScript Topic Maps in server environments

Using Smalltalk for controlling robotics systems
Using Smalltalk for controlling robotics systemsUsing Smalltalk for controlling robotics systems
Using Smalltalk for controlling robotics systemsSerge Stinckwich
 
introduction to node.js
introduction to node.jsintroduction to node.js
introduction to node.jsorkaplan
 
Deploying WO on Windows
Deploying WO on WindowsDeploying WO on Windows
Deploying WO on WindowsWO Community
 
Nodejs a-practical-introduction-oredev
Nodejs a-practical-introduction-oredevNodejs a-practical-introduction-oredev
Nodejs a-practical-introduction-oredevFelix Geisendörfer
 
Nodejs - Should Ruby Developers Care?
Nodejs - Should Ruby Developers Care?Nodejs - Should Ruby Developers Care?
Nodejs - Should Ruby Developers Care?Felix Geisendörfer
 
Kubernetes for java developers - Tutorial at Oracle Code One 2018
Kubernetes for java developers - Tutorial at Oracle Code One 2018Kubernetes for java developers - Tutorial at Oracle Code One 2018
Kubernetes for java developers - Tutorial at Oracle Code One 2018Anthony Dahanne
 
OSCON 2011 - Node.js Tutorial
OSCON 2011 - Node.js TutorialOSCON 2011 - Node.js Tutorial
OSCON 2011 - Node.js TutorialTom Croucher
 
Persistent Memory Programming with Pmemkv
Persistent Memory Programming with PmemkvPersistent Memory Programming with Pmemkv
Persistent Memory Programming with PmemkvIntel® Software
 
Live streaming of video and subtitles with MPEG-DASH
Live streaming of video and subtitles with MPEG-DASHLive streaming of video and subtitles with MPEG-DASH
Live streaming of video and subtitles with MPEG-DASHCyril Concolato
 
Network Stack in Userspace (NUSE)
Network Stack in Userspace (NUSE)Network Stack in Userspace (NUSE)
Network Stack in Userspace (NUSE)Hajime Tazaki
 
Modelling IMS QTI with Topic Maps
Modelling IMS QTI with Topic MapsModelling IMS QTI with Topic Maps
Modelling IMS QTI with Topic Mapstmra
 
Run-time of Node.js : V8 JavaScript Engine
Run-time of Node.js: V8 JavaScript EngineRun-time of Node.js: V8 JavaScript Engine
Run-time of Node.js : V8 JavaScript EngineGary Yeh
 
Станислав Сидоренко «DeviceHive Java Server – миграция на Spring Boot»
Станислав Сидоренко «DeviceHive Java Server – миграция на Spring Boot»Станислав Сидоренко «DeviceHive Java Server – миграция на Spring Boot»
Станислав Сидоренко «DeviceHive Java Server – миграция на Spring Boot»DataArt
 
Developing realtime apps with Drupal and NodeJS
Developing realtime apps with Drupal and NodeJS Developing realtime apps with Drupal and NodeJS
Developing realtime apps with Drupal and NodeJS drupalcampest
 
Новый InterSystems: open-source, митапы, хакатоны
Новый InterSystems: open-source, митапы, хакатоныНовый InterSystems: open-source, митапы, хакатоны
Новый InterSystems: open-source, митапы, хакатоныTimur Safin
 

Similar a JavaScript Topic Maps in server environments (20)

Using Smalltalk for controlling robotics systems
Using Smalltalk for controlling robotics systemsUsing Smalltalk for controlling robotics systems
Using Smalltalk for controlling robotics systems
 
introduction to node.js
introduction to node.jsintroduction to node.js
introduction to node.js
 
Deploying WO on Windows
Deploying WO on WindowsDeploying WO on Windows
Deploying WO on Windows
 
Surge2012
Surge2012Surge2012
Surge2012
 
Nodejs a-practical-introduction-oredev
Nodejs a-practical-introduction-oredevNodejs a-practical-introduction-oredev
Nodejs a-practical-introduction-oredev
 
Nodejs - Should Ruby Developers Care?
Nodejs - Should Ruby Developers Care?Nodejs - Should Ruby Developers Care?
Nodejs - Should Ruby Developers Care?
 
Kubernetes for java developers - Tutorial at Oracle Code One 2018
Kubernetes for java developers - Tutorial at Oracle Code One 2018Kubernetes for java developers - Tutorial at Oracle Code One 2018
Kubernetes for java developers - Tutorial at Oracle Code One 2018
 
OSCON 2011 - Node.js Tutorial
OSCON 2011 - Node.js TutorialOSCON 2011 - Node.js Tutorial
OSCON 2011 - Node.js Tutorial
 
Node.js for beginner
Node.js for beginnerNode.js for beginner
Node.js for beginner
 
Persistent Memory Programming with Pmemkv
Persistent Memory Programming with PmemkvPersistent Memory Programming with Pmemkv
Persistent Memory Programming with Pmemkv
 
Nodejs - A quick tour (v6)
Nodejs - A quick tour (v6)Nodejs - A quick tour (v6)
Nodejs - A quick tour (v6)
 
Live streaming of video and subtitles with MPEG-DASH
Live streaming of video and subtitles with MPEG-DASHLive streaming of video and subtitles with MPEG-DASH
Live streaming of video and subtitles with MPEG-DASH
 
Network Stack in Userspace (NUSE)
Network Stack in Userspace (NUSE)Network Stack in Userspace (NUSE)
Network Stack in Userspace (NUSE)
 
Beginners Node.js
Beginners Node.jsBeginners Node.js
Beginners Node.js
 
Modelling IMS QTI with Topic Maps
Modelling IMS QTI with Topic MapsModelling IMS QTI with Topic Maps
Modelling IMS QTI with Topic Maps
 
Run-time of Node.js : V8 JavaScript Engine
Run-time of Node.js: V8 JavaScript EngineRun-time of Node.js: V8 JavaScript Engine
Run-time of Node.js : V8 JavaScript Engine
 
Станислав Сидоренко «DeviceHive Java Server – миграция на Spring Boot»
Станислав Сидоренко «DeviceHive Java Server – миграция на Spring Boot»Станислав Сидоренко «DeviceHive Java Server – миграция на Spring Boot»
Станислав Сидоренко «DeviceHive Java Server – миграция на Spring Boot»
 
Developing realtime apps with Drupal and NodeJS
Developing realtime apps with Drupal and NodeJS Developing realtime apps with Drupal and NodeJS
Developing realtime apps with Drupal and NodeJS
 
Новый InterSystems: open-source, митапы, хакатоны
Новый InterSystems: open-source, митапы, хакатоныНовый InterSystems: open-source, митапы, хакатоны
Новый InterSystems: open-source, митапы, хакатоны
 
Nodejs
NodejsNodejs
Nodejs
 

Último

AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)Samir Dash
 
Continuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on ThanabotsContinuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on ThanabotsLeah Henrickson
 
AI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by AnitarajAI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by AnitarajAnitaRaj43
 
ERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctBrainSell Technologies
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfSrushith Repakula
 
The Zero-ETL Approach: Enhancing Data Agility and Insight
The Zero-ETL Approach: Enhancing Data Agility and InsightThe Zero-ETL Approach: Enhancing Data Agility and Insight
The Zero-ETL Approach: Enhancing Data Agility and InsightSafe Software
 
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Skynet Technologies
 
JohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptxJohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptxJohnPollard37
 
“Iamnobody89757” Understanding the Mysterious of Digital Identity.pdf
“Iamnobody89757” Understanding the Mysterious of Digital Identity.pdf“Iamnobody89757” Understanding the Mysterious of Digital Identity.pdf
“Iamnobody89757” Understanding the Mysterious of Digital Identity.pdfMuhammad Subhan
 
UiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overviewUiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overviewDianaGray10
 
Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireExakis Nelite
 
Cyber Insurance - RalphGilot - Embry-Riddle Aeronautical University.pptx
Cyber Insurance - RalphGilot - Embry-Riddle Aeronautical University.pptxCyber Insurance - RalphGilot - Embry-Riddle Aeronautical University.pptx
Cyber Insurance - RalphGilot - Embry-Riddle Aeronautical University.pptxMasterG
 
2024 May Patch Tuesday
2024 May Patch Tuesday2024 May Patch Tuesday
2024 May Patch TuesdayIvanti
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc
 
How to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfHow to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfdanishmna97
 
State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!Memoori
 
Portal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russePortal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russe中 央社
 
Intro to Passkeys and the State of Passwordless.pptx
Intro to Passkeys and the State of Passwordless.pptxIntro to Passkeys and the State of Passwordless.pptx
Intro to Passkeys and the State of Passwordless.pptxFIDO Alliance
 
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdfFrisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdfAnubhavMangla3
 

Último (20)

AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
 
Continuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on ThanabotsContinuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
Continuing Bonds Through AI: A Hermeneutic Reflection on Thanabots
 
AI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by AnitarajAI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by Anitaraj
 
ERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage IntacctERP Contender Series: Acumatica vs. Sage Intacct
ERP Contender Series: Acumatica vs. Sage Intacct
 
Overview of Hyperledger Foundation
Overview of Hyperledger FoundationOverview of Hyperledger Foundation
Overview of Hyperledger Foundation
 
How we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdfHow we scaled to 80K users by doing nothing!.pdf
How we scaled to 80K users by doing nothing!.pdf
 
The Zero-ETL Approach: Enhancing Data Agility and Insight
The Zero-ETL Approach: Enhancing Data Agility and InsightThe Zero-ETL Approach: Enhancing Data Agility and Insight
The Zero-ETL Approach: Enhancing Data Agility and Insight
 
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
Human Expert Website Manual WCAG 2.0 2.1 2.2 Audit - Digital Accessibility Au...
 
JohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptxJohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptx
 
“Iamnobody89757” Understanding the Mysterious of Digital Identity.pdf
“Iamnobody89757” Understanding the Mysterious of Digital Identity.pdf“Iamnobody89757” Understanding the Mysterious of Digital Identity.pdf
“Iamnobody89757” Understanding the Mysterious of Digital Identity.pdf
 
UiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overviewUiPath manufacturing technology benefits and AI overview
UiPath manufacturing technology benefits and AI overview
 
Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - Questionnaire
 
Cyber Insurance - RalphGilot - Embry-Riddle Aeronautical University.pptx
Cyber Insurance - RalphGilot - Embry-Riddle Aeronautical University.pptxCyber Insurance - RalphGilot - Embry-Riddle Aeronautical University.pptx
Cyber Insurance - RalphGilot - Embry-Riddle Aeronautical University.pptx
 
2024 May Patch Tuesday
2024 May Patch Tuesday2024 May Patch Tuesday
2024 May Patch Tuesday
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
 
How to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cfHow to Check CNIC Information Online with Pakdata cf
How to Check CNIC Information Online with Pakdata cf
 
State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!State of the Smart Building Startup Landscape 2024!
State of the Smart Building Startup Landscape 2024!
 
Portal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russePortal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russe
 
Intro to Passkeys and the State of Passwordless.pptx
Intro to Passkeys and the State of Passwordless.pptxIntro to Passkeys and the State of Passwordless.pptx
Intro to Passkeys and the State of Passwordless.pptx
 
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdfFrisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
Frisco Automating Purchase Orders with MuleSoft IDP- May 10th, 2024.pptx.pdf
 

JavaScript Topic Maps in server environments

  • 1. W E B V E V E R I E T JavaScript Topic Maps in server environments Jan Schreiber <jans@ravn.no> Ravn Webveveriet AS, 2010-10-01 1
  • 2. Outline • JavaScript • The tmjs Topic Maps engine • Use Case: A PSI Server • Outlook W E B V E V E R I E T 2
  • 3. JavaScript • JavaScript is LISP with a C-like syntax • Virtually every personal computer in the world has at least one JavaScript interpreter installed on it and in active use. W E B V E V E R I E T 3
  • 4. tmjs • A Topic Maps engine • Written in pure JavaScript • Full TMDM including Variants • TMAPI 2.0-based • In-memory backend, JTM import/ export, experimental XTM 2.0 import (requires DOM) W E B V E V E R I E T 4
  • 5. tmjs • Platform independent: All(iPhone & browsers, mobile devices modern Android), server-side JavaScript • Unit tests, CXTM tests (partly) & JSLint validating • Small changes to TMAPI due to the lack of method overloading • Syntactic sugar: Supports chaining of TMAPI calls W E B V E V E R I E T 5
  • 6. Chaining 1 tm.createTopic().addSubjectIdentifier(foo). 2 createName('bar').getParent(). 3 createOccurrence(type,'baz'). 4 addScopingTopic(quux); W E B V E V E R I E T 6
  • 7. tmjs: Outlook • More import/export formats: XTM 2.0, CTM • Complete TMAPI, add more tests, full CXTM • Persistence: • Web SQL Database backend • Persistent backend for Node (couchdb?) • Later: Query language W E B V E V E R I E T 7
  • 8. Use Case: A PSI Server • Idea: Start the server with a Topic Map and it will serve information about all Subject Identifiers for a given domain W E B V E V E R I E T 8
  • 9. • Screenshot node-psi-server W E B V E V E R I E T 9
  • 10. Server-side JavaScript • 1996: Netscape releases LiveWire as part of Netscape Enterprise Server 2.0 • 2009: Ryan Dahl writes Node W E B V E V E R I E T 10
  • 11. Node • A framework for low-level network applications based on Google's V8 engine • TCP, DNS and HTTP are first-class protocols • Event-based, asynchronous programming • All I/O is non-blocking W E B V E V E R I E T 11
  • 12. result = db_query(db, "SELECT * FROM topic"); W E B V E V E R I E T 12
  • 13. db_query(db, "SELECT * FROM topic", callback); W E B V E V E R I E T 13
  • 14. db_query(db, "SELECT * FROM topic", callback); callback = function (err, result) { // ... } W E B V E V E R I E T 14
  • 15. 1 var tm, servername; 2 // assumes that the TopicMap object tm has been initialized and 3 // the topic map in question has been imported successfuly. 4 // servername is set from a command line parameter 5 http.createServer(function (req, res) { 6 var url = 'http://'+servername+req.url, loc, topic; 7 loc = tm.createLocator(url); 8 topic = tm.getTopicBySubjectIdentifier(loc); 9 if (topic) { 10 res.writeHead(200, {'Content-Type': 'text/html'}); 11 // create a page with information about the PSI 12 } else { 13 // Not found: create a 404 response 14 } 15 res.close(); 16 }).listen(80); W E B V E V E R I E T 15
  • 16. Use Case: A PSI Server • More output formats: XHTML, JTM, XTM • Support for logging, caching, templates • Configurable list of information elements that are included on generated pages (e.g. dc:description, supertype-subtype) • PSI black-listing • subj3ct.com integration W E B V E V E R I E T 16
  • 17. PSI Server: Observations • Easy to implement • It’s really fast: 200+200ms to read the Opera topic map, 1ms to serve a PSI page • tmjs can be used on server and client side Reuse of application code W E B V E V E R I E T 17
  • 18. Summary & Outlook • Server side Topic Maps with JavaScript: possible! • Asynchronous TMAPI? • In its current state maybe best suited for low-level applications W E B V E V E R I E T 18
  • 19. What could it be good for? • TMRAP, TM REST API • SDshare • P2P applications • DNS servers W E B V E V E R I E T 19
  • 20. Questions? Download tmjs now! http://github.com/jansc/tmjs Coming soon: http://github.com/jansc/node-psi-server W E B V E V E R I E T 20