CTS2 OverviewCTS2 DEVELOPMENTFRAMEWORK
Schedule• What is it?• Why a framework?• What does this do for me?• Plugins• Implementations available now• CTS2 Complianc...
CTS2 Development Framework• Under development by Mayo Clinic• A Framework for creating CTS2 implementations• Uses Model Vi...
CTS2 Development Framework• A MVC architecture that is compliant with the CTS2 API specification• Can be used to   • Imple...
CTS2 Development Framework• Can be used to (continued)   • Implement new views (21090,    cRDF, …)  • Extend the controlle...
CTS2 Development Framework      “Model” Component• Transforms View (CTS2 PIM) structures into state (aka “backing store”) ...
CTS2 Development Framework       “View” Component• Implements the static portion of the CTS2 model  • CodeSystemCatalogEnt...
CTS2 Development Framework    “Controller” Component• Implements the behavioral portion of the CTS2 model   • Accepts even...
Why a Development Framework?• CTS2 isn‟t one implementation of the spec, it (may be) many.• Different use-cases demand dif...
Why a Development Framework?• One CTS2 implementation probably can‟t, most likely shouldn‟t, and certainly doesn‟t need to...
Why a Development Framework?• CTS2 is large but very modular. You don‟t want to support/maintain what you don‟t need.• CTS...
What does this do for me?• Most web apps contain lots of boilerplate code – accepting HTTP requests, error handling, admin...
What does this do for me?• Defines the CTS PIM interfaces in the code. This is what implementers will implement.• Using th...
What does this do for me?• Development tools provide   • REST HTTP URL bindings   • CTS2 model as Java Beans   • CTS2 REST...
What DOESN‟T this do for me?• Store content in a database/filesystem/triplestore• Read content from a persistence store• T...
CTS2 Implementations as Plugins• Actual implementations are bundled together as a “plugin” to the framework.• Each plugin ...
CTS2 Implementations as Plugins• Actual implementations are bundled together as a “plugin” to the framework.• Each plugin ...
CTS2 Implementations as Plugins         Wait… is this OSGi?Yes – the Plugin Framework ispowered by Apache Felix. Any valid...
CTS2 Implementations as Plugins         Is this OSGi (cont.)?OSGi allows you to use off-the-shelfOSGi components and tools...
What can a Plugin do?•   Connect to a SQL database•   Connect to a triple store•   Read from a file system•   Aggregate tw...
Plugin Behavior• Plugins may be    • Activated    • Deactivated    • Removed    • Uploaded    • Discovered and QueriedPlug...
Plugin API• An admin API for plugin management is provided.  The API is REST based• Easy to hook into CI Servers to run in...
Implemented Plugins• eXist XML Database Plugin:    • http://informatics.mayo.edu/exist/cts2/rest/codesystems• NCBO Bioport...
Implemented Plugins• eXist XML Database Plugin:    • Based on the eXist XML Database    • Supports:       • READ       • Q...
Implemented Plugins• NCBO Bioportal Wrapper   • A Wrapper around the NCBO Bioportal REST       Service   •   Supports:    ...
Planned Plugins• RDF Triple-Store Plugin• LexEVS Plugin
A Service Plugin in two classes• http://informatics.mayo.edu/cts2/framework /example-plugin-tutorial/
Next steps• Solidify Development Framework Service Interfaces• Add a „Compliance Test‟ suite• Find common functionality an...
Resourceshttp://informatics.mayo.edu/cts2/framework/example-plugin-tutorial/http://informatics.mayo.edu/cts2/framework/ins...
Questions?
Upcoming SlideShare
Loading in …5
×

CTS2 Development Framework

1,362 views

Published on

The CTS2 Development framework Overview.

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,362
On SlideShare
0
From Embeds
0
Number of Embeds
609
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

CTS2 Development Framework

  1. 1. CTS2 OverviewCTS2 DEVELOPMENTFRAMEWORK
  2. 2. Schedule• What is it?• Why a framework?• What does this do for me?• Plugins• Implementations available now• CTS2 Compliance in two Java classes
  3. 3. CTS2 Development Framework• Under development by Mayo Clinic• A Framework for creating CTS2 implementations• Uses Model View Controller (MVC) architectural pattern
  4. 4. CTS2 Development Framework• A MVC architecture that is compliant with the CTS2 API specification• Can be used to • Implement against different back ends (e.g. RDF, SQL, existing terminology structures or API‟s) • Specify and/or create different import and export maps (IHTSDO, OWL, …)
  5. 5. CTS2 Development Framework• Can be used to (continued) • Implement new views (21090, cRDF, …) • Extend the controller with business rules and workflow constraints
  6. 6. CTS2 Development Framework “Model” Component• Transforms View (CTS2 PIM) structures into state (aka “backing store”) • Enforces post-conditions • May also enforce some invariants
  7. 7. CTS2 Development Framework “View” Component• Implements the static portion of the CTS2 model • CodeSystemCatalogEntry, … • (Indirectly) enforces some invariants
  8. 8. CTS2 Development Framework “Controller” Component• Implements the behavioral portion of the CTS2 model • Accepts events • Validates invariants • Enforces preconditions
  9. 9. Why a Development Framework?• CTS2 isn‟t one implementation of the spec, it (may be) many.• Different use-cases demand different implementations.
  10. 10. Why a Development Framework?• One CTS2 implementation probably can‟t, most likely shouldn‟t, and certainly doesn‟t need to implement all of CTS2
  11. 11. Why a Development Framework?• CTS2 is large but very modular. You don‟t want to support/maintain what you don‟t need.• CTS2 is a specification but you may need more – extensions may be needed.• Persistence back-ends are different.
  12. 12. What does this do for me?• Most web apps contain lots of boilerplate code – accepting HTTP requests, error handling, admin interfaces… etc.• We don‟t want CTS2 implementers writing boilerplate code!
  13. 13. What does this do for me?• Defines the CTS PIM interfaces in the code. This is what implementers will implement.• Using these interfaces, the Development Framework will expose the implementation as HTTP REST (current), SOAP (planned)… etc. -- all using the same implementation.
  14. 14. What does this do for me?• Development tools provide • REST HTTP URL bindings • CTS2 model as Java Beans • CTS2 REST client • Various Builder pattern query building objects • Plugin admin structure
  15. 15. What DOESN‟T this do for me?• Store content in a database/filesystem/triplestore• Read content from a persistence store• Tell you what your persistence store should be
  16. 16. CTS2 Implementations as Plugins• Actual implementations are bundled together as a “plugin” to the framework.• Each plugin has its own classpath• May be implemented in Java, Groovy, Scala, Clojure…• Build support provided for Gradle and Maven
  17. 17. CTS2 Implementations as Plugins• Actual implementations are bundled together as a “plugin” to the framework.• Each plugin has its own classpath• May be implemented in Java, Groovy, Scala, Clojure…• Build support provided for Gradle and Maven
  18. 18. CTS2 Implementations as Plugins Wait… is this OSGi?Yes – the Plugin Framework ispowered by Apache Felix. Any validOSGi bundle is a valid CTS2Development Framework plugin.
  19. 19. CTS2 Implementations as Plugins Is this OSGi (cont.)?OSGi allows you to use off-the-shelfOSGi components and tools, alongwith custom created bundles.
  20. 20. What can a Plugin do?• Connect to a SQL database• Connect to a triple store• Read from a file system• Aggregate two or more existing CTS2 services• …
  21. 21. Plugin Behavior• Plugins may be • Activated • Deactivated • Removed • Uploaded • Discovered and QueriedPlugins are hot-swappable. Changing plugins does NOTmean you must restart your container.
  22. 22. Plugin API• An admin API for plugin management is provided. The API is REST based• Easy to hook into CI Servers to run integration tests
  23. 23. Implemented Plugins• eXist XML Database Plugin: • http://informatics.mayo.edu/exist/cts2/rest/codesystems• NCBO Bioportal Wrapper • http://informatics.mayo.edu/cts2/rest/codesystems
  24. 24. Implemented Plugins• eXist XML Database Plugin: • Based on the eXist XML Database • Supports: • READ • QUERY • MAINTENANCE
  25. 25. Implemented Plugins• NCBO Bioportal Wrapper • A Wrapper around the NCBO Bioportal REST Service • Supports: • READ • QUERY
  26. 26. Planned Plugins• RDF Triple-Store Plugin• LexEVS Plugin
  27. 27. A Service Plugin in two classes• http://informatics.mayo.edu/cts2/framework /example-plugin-tutorial/
  28. 28. Next steps• Solidify Development Framework Service Interfaces• Add a „Compliance Test‟ suite• Find common functionality and include it with the Development Framework• Add SOAP endpoint?• Allow „View‟ plugins (allow for custom representations like CSV, text, Excel, etc…)• Loader Plugins• OSGi?
  29. 29. Resourceshttp://informatics.mayo.edu/cts2/framework/example-plugin-tutorial/http://informatics.mayo.edu/cts2/framework/installation/http://informatics.mayo.edu/cts2/framework/create-a-plugin/
  30. 30. Questions?

×