TaskQueue configuration

Lookup for publishing result at the NextGen Deliver due to his nature should be executed in separate queue. RDS queue for prod-like is the must, needs to be configured as per documentation (@see taoTaskQueue readme)

To be independent workers has be to launched as a separate processes:

  • sudo -u www-data php index.php 'oat\taoTaskQueue\scripts\tools\RunWorker' --queue=ng_publication
  • sudo -u www-data php index.php 'oat\taoTaskQueue\scripts\tools\RunWorker' --queue=queue

TanantAPI configuration

There are 3 existing implementations that work with the Tenant API configurable at config/taoDeliverConnect/DeliverTenantService.conf.php

  1. \oat\taoDeliverConnect\model\api\TenantHttpAPI is used to retrieve data based on agreed Rest contract

  2. \oat\taoDeliverConnect\model\api\TenantConfigurableAPI uses plain configuration in tao native format
  3. \oat\taoDeliverConnect\model\api\TenantDriverApiReader access with a configurable KV driver to storage, f.e. to the environment variables

    return new oat\taoDeliverConnect\model\DeliverTenantService( [ 'tenant_api' => new TenantDriverApiReader( [ TenantDriverApiReader::OPTION_DRIVER => EnvironmentVariableKVDriver::class ] ), ] );

    Sample data in DotEnv format ( for the explanation please see comments to the code at the TenantDriverApiReader) :

    DELIVERTENANT_COUNT=2
    
    DELIVERTENANT_0_ID=1
    DELIVERTENANT_0_LABEL=coool_label
    DELIVERTENANT_0_CUSTOMER_ID=77
    DELIVERTENANT_0_ROOT_URL='http://deliver.docker.localhost/api/v1/'
    
    DELIVERTENANT_0_LTI_CREDENTIALS_COUNT=2
    
    DELIVERTENANT_0_LTI_CREDENTIALS_0_KEY=aaa1
    DELIVERTENANT_0_LTI_CREDENTIALS_0_SECRET=***
    
    DELIVERTENANT_0_LTI_CREDENTIALS_0_ROLES_COUNT=2
    DELIVERTENANT_0_LTI_CREDENTIALS_0_ROLES_0=learner
    DELIVERTENANT_0_LTI_CREDENTIALS_0_ROLES_1=ContentDeveloper
    
    DELIVERTENANT_0_LTI_CREDENTIALS_1_KEY=bbb1
    DELIVERTENANT_0_LTI_CREDENTIALS_1_SECRET=bbb1
    
    DELIVERTENANT_0_LTI_CREDENTIALS_1_ROLES_COUNT=2
    DELIVERTENANT_0_LTI_CREDENTIALS_1_ROLES_0=learner
    DELIVERTENANT_0_LTI_CREDENTIALS_1_ROLES_1=ContentDeveloper
    
    DELIVERTENANT_0_OAUTH_CREDENTIALS_COUNT=1
    DELIVERTENANT_0_OAUTH_CREDENTIALS_0_KEY=bbb1
    DELIVERTENANT_0_OAUTH_CREDENTIALS_0_SECRET=bbb1
    DELIVERTENANT_0_OAUTH_CREDENTIALS_0_ROLES_COUNT=2
    DELIVERTENANT_0_OAUTH_CREDENTIALS_0_ROLES_0=learner
    DELIVERTENANT_0_OAUTH_CREDENTIALS_0_ROLES_1=ContentDeveloper
    
    DELIVERTENANT_1_ID=2
    DELIVERTENANT_1_LABEL=coool_label211
    DELIVERTENANT_1_CUSTOMER_ID=78
    DELIVERTENANT_1_ROOT_URL='http://deliver.docker.localhost/api/v1/'
    DELIVERTENANT_1_LTI_CREDENTIALS_COUNT=2
    DELIVERTENANT_1_LTI_CREDENTIALS_0_KEY=aaa2
    DELIVERTENANT_1_LTI_CREDENTIALS_0_SECRET=aaa2
    DELIVERTENANT_1_LTI_CREDENTIALS_0_ROLES_COUNT=2
    DELIVERTENANT_1_LTI_CREDENTIALS_0_ROLES_0=learner
    DELIVERTENANT_1_LTI_CREDENTIALS_0_ROLES_1=ContentDeveloper
    DELIVERTENANT_1_LTI_CREDENTIALS_1_KEY=bbb2
    DELIVERTENANT_1_LTI_CREDENTIALS_1_SECRET=bbb2
    DELIVERTENANT_1_LTI_CREDENTIALS_1_ROLES_COUNT=2
    DELIVERTENANT_1_LTI_CREDENTIALS_1_ROLES_0=learner
    DELIVERTENANT_1_LTI_CREDENTIALS_1_ROLES_1=ContentDeveloper