Background

inQuiry BB has multiple components like assessment-service, questionset-editor, player and Flink jobs spread across multiple GitHub repositories. The objective is to decouple the inQuiry specific code from KP (Knowledge-Platform) Git Repos and bring it under the inQuiry BB space in GitHub.

Components:

Component

Proposed Github Repo

Description

assessment-service

Sunbird-inQuiry/assessment-service

Microservice for question & questionset api's

questionset-publish

Sunbird-inQuiry/data-pipeline

Asynchronous job for publishing question & questionset

player

Sunbird-inQuiry/player

quml player to render Question & QuestionSet

editor

Sunbird-inQuiry/editor

Editor for creating Question & QuestionSet

portal

Sunbird-inQuiry/portal

A dummy portal to experience inQuiry Capabilities.

Open Question:

  1. We need same provisioning scripts across multiple repos. Where do we hold provisioning scripts?

  2. For private devops repo, as per devops team, we can have a common one with BB specific folder or a BB Specific repo itself. Should inQuiry have its own private repo?

Dependency:

Component 

Component Type

Dependency

taxonomy-service

Microservice

  • Required for creating inQuiry specific category & its definition, framework and its related objects.

search-service

Microservice

  • Required to search existing Question/QuestionSet objects

content-service

Microservice

  • Required for asset api's as inQuiry editor needs them.

  • Once Knowlg BB Provides asset api’s as a separate service, inQuiry will stop using content-service

search-indexer

Flink Job

  • This flink job is required to sync objects from graph DB to Elasticsearch

learning-service

api service (VM Based)

  • Question & QuestionSet can have framework data (e.g: board, medium, subject).

  • System uses redis cache for validation of these attributes.

  • Population of redis cache data is part of framework publish api.

  • Once Knowlg BB migrate the framework publish api to taxonomy-service. inQuiry stop using learning-service.

  • API migration is expected in JAS release

Goals:

  1. Code Movement to inQuiry Github Repo

  2. Configuration Changes for inQuiry components

  3. Build and Deployment Script Movement - will be done under the guidance of the devops team.

  4. Deployment of inQuiry components and dependent Knowlg components

Code Movement to inQuiry Github

Component

Knowlg Dependency

Dependency Resolution Proposal

assessment-service

The micro-service is dependent on below modules:

  1. platform-core with all its submodules

  2. ontology-engine with all its submodules.

  3. platform-modules - only import-manager submodules are required.

  • For now, inQuiry will use these components directly from Knowlg BB repo for building inQuiry components. 

  • Once Knowlg BB makes it available as a maven dependency, inQuiry will add them and the build script will be modified.  

questionset-publish

The flink job is dependent on below modules:

  1. jobs-core

  2. publish-core

  • inQuiry will take both modules from Knowlg BB repo while building the job.

  • Once SB-Obsrv is the owner for jobs-core module. Once it is available as a maven dependency, inQuiry will stop using jobs-core from Knowlg.

  • Once publish-core is available as maven dependency, inQuiry will start using it and do the build script changes.

editor

Code of collection editor and questionset editor is tightly coupled. Need to break down the code as a base-editor, collection editor & questionset editor

  • inQuiry will use the codebase directly from Knowlg BB until we have a base editor.

  • For now, inQuiry won’t maintain any codebase but will hold the ownership for questionset editor related code..

  • Once Knowlg BB will  have a base editor, inQuiry will have its own codebase for questionset editor.

player

No dependency

Codebase will move as is to inQuiry Github

Configuration Changes for inQuiry components:

Deployment of inQuiry components and dependent Knowlg components

  1. Deploy inQuiry in the same server where Knowlg BB components are deployed.

  2. Deploy inQuiry in a different server than where Knowlg BB components are deployed.

  3. Deploy inQuiry where Knowlg BB components are not deployed.

Deploy inQuiry in the same server where Knowlg BB components are deployed.

Deploy inQuiry in a different server than where Knowlg BB components are deployed.

Object Type

Description

Database Dependency

Resolution

ObjectCategoryDefinition

  • inQuiry micro-service uses ObjectCategoryDefinition data to validate Question & QuestionSet object.

  • No graph db dependency.

  • As of now cassandra db is required for fetching definition.

  • Code changes can be done to make api calls instead of db calls.

  • this behaviour can be controlled through service level configuration to make db call or api call.

License

  • Currently Question & QuestionSets are not using License but it can be configured as edge prop under object level config

  • Service needs all License values in redis cache (edge_license).

  • Currently these cache record population is part of vm setup (manual cache entry), which should be enhanced to use the available data in the platform.

  • No dependency on any other db for license

  • We can use composite search api to populate the available license data to redis cache instead of fetching from graph db.

Framework

  • Question & QuestionSet objects are having framework related configuration to validate.

  • System Fetch all framework master categories from graph db and populate orgFramework & targetFramework related data to validate the node object.

  • System/Service Validates Framework Categories (e.g: board, medium, subject, etc) using redis cache. key: cat_[FRAMEWORK_NAME][TERM_NAME]

  • population of category cache is dependent on framework publish api, which again make use of graph db.

  • graph db hard dependency is there.

  • We can have the code changes to make use of taxnomoy api (may need to introduce new category list api) or search api to get all master categories.

  • In case of cache doesn't have framework term record, We can fetch the a particular framework on demand using taxonomy api and populate the category cache.

  • Another solution for category cache could be get all list of frameworks and then filter their terms and populate category cache using taxonomy api as part of service initialization.

Deploy inQuiry where Knowlg BB components are not deployed.

Open Questions: