Herzog August Bibliothek Wolfenbüttel Backend, Service, Listener VuFind's new SOLR connection Originally Presented By David Maus Herzog August Bibliothek.

Slides:



Advertisements
Similar presentations
Chapter 6 Server-side Programming: Java Servlets
Advertisements

VuFind Beyond MARC discovering everything else Demian Katz VuFind Developer
MWD1001 Website Production Using JavaScript with Forms.
Coding Standard: General Rules 1.Always be consistent with existing code. 2.Adopt naming conventions consistent with selected framework. 3.Use the same.
Review Linked list: Doubly linked list, insertback, insertbefore Remove Search.
Visibility Information Exchange Web System. Source Data Import Source Data Validation Database Rules Program Logic Storage RetrievalPresentation AnalysisInterpretation.
Solr has a lot of extensive features Solr Integration and Enhancements Todd Hatcher.
Feb. 23, 2004CS WPI1 CS 509 Design of Software Systems Lecture #5 Monday, Feb. 23, 2004.
Microsoft ® Official Course Interacting with the Search Service Microsoft SharePoint 2013 SharePoint Practice.
Exceptions. Many problems in code are handled when the code is compiled, but not all Some are impossible to catch before the program is run  Must run.
Dependency Injection and Model-View-Controller. Overview Inversion of Control Model-View-Controller.
Dataface API Essentials Steve Hannah Web Lite Solutions Corp.
ZFApp Preview Walkthrough. What is ZFApp? ZFApp is an application framework built on top of Zend Framework Fully compatible with the latest ZF Versions.
Apache Chemistry face-to-face meeting April 2010.
Configuration Management and Server Administration Mohan Bang Endeca Server.
1 Exception Handling Introduction to Exception Handling Exception Handling in PLs –Ada –C++ –Java Sebesta Chapter 14.
Understanding Events and Exceptions Lesson 3. Objective Domain Matrix Skills/ConceptsMTA Exam Objectives Understand events and event handling Understand.
Designing and Implementing Web Data Services in Perl
Copyright © 2012 Accenture All Rights Reserved.Copyright © 2012 Accenture All Rights Reserved. Accenture, its logo, and High Performance Delivered are.
Design patterns. What is a design pattern? Christopher Alexander: «The pattern describes a problem which again and again occurs in the work, as well as.
RECALL THE MAIN COMPONENTS OF KIM Functional User Interfaces We just looked at these Reference Implementation We will talk about these later Service Interface.
LiveCycle Data Services Introduction Part 2. Part 2? This is the second in our series on LiveCycle Data Services. If you missed our first presentation,
Standalone Java Application vs. Java Web Application
Rendering Contexts and Components What is a uPortal3 context ? –Defines all aspects of a traditional portal instance Design, navigation, profiles Parameter.
Victor Mushkatin, MCSE, MCSD CORPORATION Alexander Zakonov, MCSE, MCSD Stephen Pelletier, MCSE.
Revolutionizing enterprise web development Searching with Solr.
1 st LDAP Conference 2007, Köln Germany 6-7 September 2007 Moving LDAP Writes to Web Services Kostas Kalevras National Technical University of Athens,
Drupal Commerce Better than Uber Andrew Root: druroot.
Lecture Set 11 Creating and Using Classes Part B – Class Features – Constructors, Methods, Fields, Properties, Shared Data.
(Business) Process Centric Exchanges
Chapter 6 Server-side Programming: Java Servlets
Introduction to Exception Handling and Defensive Programming.
2007. Software Engineering Laboratory, School of Computer Science S E Web-Harvest Web-Harvest: Open Source Web Data Extraction tool 이재정 Software Engineering.
Chapter 8 Object Design Reuse and Patterns. Object Design Object design is the process of adding details to the requirements analysis and making implementation.
Domain Driven Web Development With WebJinn Sergei Kojarski College of Computer & Information Science Northeastern University joint work with David H. Lorenz.
Alternative Architectures: Inversion of Control Mike Hadlow mikehadlow.blogspot.com.
Server-side Programming The combination of –HTML –JavaScript –DOM is sometimes referred to as Dynamic HTML (DHTML) Web pages that include scripting are.
Class Builder Tutorial Presented By- Amit Singh & Sylendra Prasad.
Testing OO software. State Based Testing State machine: implementation-independent specification (model) of the dynamic behaviour of the system State:
PHP Error Handling Section :I Source: 1.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 JSP Application Models.
Exceptions in C++. Exceptions  Exceptions provide a way to handle the errors generated by our programs by transferring control to functions called handlers.
CSI 3125, Preliminaries, page 1 SERVLET. CSI 3125, Preliminaries, page 2 SERVLET A servlet is a server-side software program, written in Java code, that.
Plug-in Architectures Presented by Truc Nguyen. What’s a plug-in? “a type of program that tightly integrates with a larger application to add a special.
Introduction to Object-Oriented Programming Lesson 2.
RESTful Web Services What is RESTful?
MVC WITH CODEIGNITER Presented By Bhanu Priya.
REST By: Vishwanath Vineet.
Spring RabbitMQ Martin Toshev.
1 Enhanced Mobility Support for Roaming Users: Extending the IEEE Information Service WWIC 2010 Luleå, June 1-3, 2010 Karl Andersson*, Andrea G.
Rich Internet Applications 2. Core JavaScript. The importance of JavaScript Many choices open to the developer for server-side Can choose server technology.
Java Programming: Advanced Topics 1 Enterprise JavaBeans Chapter 14.
Exceptions Lecture 11 COMP 401, Fall /25/2014.
Text INTRODUCTION TO ASP.NET. InterComm Campaign Guidelines CONFIDENTIAL Simply Server side language Simplified page development model Modular, well-factored,
Duke CPS Programming Heuristics l Identify the aspects of your application that vary and separate them from what stays the same ä Take what varies.
Representational State Transfer COMP6017 Topics on Web Services Dr Nicholas Gibbins –
Lecture 11 Dr. Eng. Ibrahim El-Nahry Exception Handling.
VuFind 2.0 an introduction Demian Katz VuFind Developer
Zend\EventManager Zend\Serializer Zend\Cache Zend\Stdlib\ErrorHandler.
Magento Technical Guidelines Eugene Shakhsuvarov, Software Magento
Representational State Transfer
Indexer AKEEL AHMED.
IS333D: MULTI-TIER APPLICATION DEVELOPMENT
Northbound API Dan Shmidt | January 2017
AVG 24th 2015 ADVANCED c# - part 1.
Exception Handling Oo28.
Web Applications Best Practices
Lucene/Solr Architecture
Lecture 5: Functions and Parameters
Exceptions and networking
Presentation transcript:

Herzog August Bibliothek Wolfenbüttel Backend, Service, Listener VuFind's new SOLR connection Originally Presented By David Maus Herzog August Bibliothek Wolfenbüttel VuFind Anwendertreffen September 16 th - 17 th, Hamburg Harburg

Herzog August Bibliothek Wolfenbüttel VuFind 2.x Paradigms  Based on Zend Framework 2 Hint: If in doubt, check the framework's source code  PHP Namespaces and ClassLoader Search term: PSR-0  Front Controller Pattern Make decisions up-front, then execute  ServiceManager as central registry...not perfect, but better than global variables

Herzog August Bibliothek Wolfenbüttel Problems with the old SOLR connection  Organic growth (PHP4, PHP5) "works for me"  Tight coupling of functionality ("talk to SOLR"), index schema, and web application  One class does everything  Hard to extend programmatically...except "works for me"

Herzog August Bibliothek Wolfenbüttel VuFind 2.x SOLR connection  Separation of concerns Processing a user query implemented by exchangeable objects Separation of functionality and application VuFindSearch – Functionality ("Framework") VuFind\Search – Specialized instances of framework classes ("Application")  Parameter aggregation Search parameters are aggregated from different sources Close match of SOLR-Functions and VuFind-Classes  Events as extension points Flexible EventManager provided by the Zend Framework Modification of search behaviour by custom modules is possible

Herzog August Bibliothek Wolfenbüttel VuFind 2.x SOLR Backend

Herzog August Bibliothek Wolfenbüttel VuFindSearch\Backend\Solr\Backend  Translates search requests into SOLR parameters  Defines the response writer (hardcoded) wt=json&json.nl=arrarr  Uses QueryBuilder to translate search (field, term) in SOLR search syntax includes spellcheck.q and hl.q  Delegates to Connector class  Deserializes the response  Creates response using the factory pattern VuFindSearch\Backend\Solr\Response\Json\RecordCollectionFactory

Herzog August Bibliothek Wolfenbüttel VuFindSearch\Backend\Solr\Connector  Connection to SOLR index  Uses HandlerMap to map search operations (search, retrieve, morelikethis, …) to SOLR Request Handlers VuFindSearch\Backend\Solr\HandlerMap Supports Appends, Defaults, Invariants analogous to SOLR  HTTP Transport  Error handling: Triggers an exception in case of error VuFindSearch\Backend\Exception\BackendException VuFindSearch\Backend\Exception\RemoteErrorException (HTTP 5xx) VuFindSearch\Backend\Exception\RequestErrorException (HTTP 4xx)

Herzog August Bibliothek Wolfenbüttel VuFindSearch\Response\RecordCollectionFactoryInterface  Executing a search operation always returns a RecordCollection ! Support for other response types (e.g. terms, alphabetic browse) would be nice  RecordCollectionFactory creates RecordCollection based on the SOLR response ! Hard-coded response writer, only JSON is currently supported  RecordCollectionFactory instantiates appropriate RecordDriver objects  RecordCollection acts as wrapper for the entire SOLR response (Facets)

Herzog August Bibliothek Wolfenbüttel VuFind\Search\BackendManager  Backend configuration  Uses a local ("scoped") ServiceManager to create backend instances  Backend instances are addressed by a distinct name Aliases can be used and are helpful in some circumstances  Factory Pattern to instantiate and configure backends

Herzog August Bibliothek Wolfenbüttel VuFindSearch\Service  Integrates backends and backend operations  Backend instances are addressed by name  Uses the event system to resolve a backend name to a backend instance  Executes events before (pre) and after (post) a search operation  Executes event in case an error occurred (error)  Defined objects (listeners) can react to the events

Herzog August Bibliothek Wolfenbüttel Event: VuFindSearch\Service::EVENT_RESOLVE  "short-circuited": Stops as soon as a listener provides a backend  Event contains information about the search operation ("context") and all formal parameters  Association between backend name and backend instance is cached internally

Herzog August Bibliothek Wolfenbüttel Event: VuFindSearch\Service::EVENT_PRE/EVENT_POST  EVENT_PRE contains the resolved backend, name of operation and all formal parameters  EVENT_POST contains the search response (RecordCollection)  Listeners can manipulate the response and secondary search parameters

Herzog August Bibliothek Wolfenbüttel Event: VuFindSearch\Service::EVENT_ERROR  Service catches exceptions from the backend  The error event contains the exception  Exception is rethrown  Use-case: Support SOLR 3.x and SOLR 4.x error responses Response bodies are different (text/plain with stack trace vs. real JSON response)

Herzog August Bibliothek Wolfenbüttel

VuFind 2.2 (Summer 2014)  More parameter aggregation at the higher levels Options – Params – Results (SearchObject)  Custom faceting behaviour? Your feedback!  Support other response types Terms/AlphabeticBrowse => Systematic Access ftw!