Skip to content

Commit

Permalink
issue_1551 added mivideo/kaltura video resources access query into en… (
Browse files Browse the repository at this point in the history
  • Loading branch information
zqian committed Dec 6, 2023
1 parent 28ca15f commit 9fb4601
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions config/env_sample.hjson
Original file line number Diff line number Diff line change
Expand Up @@ -289,6 +289,31 @@
"postfix": ""
}
},
# replace "mivideo" with Kaltura brand name inside your institution
"mivideo": {
"query":
'''
SELECT 'mivideo' AS resource_type,
replace(object.id, 'https://aakaf.mivideo.it.umich.edu/caliper/info/media/' , '') AS resource_id,
cast(-1 as INT64) AS user_id,
replace(
replace(actor.id, 'https://aakaf.mivideo.it.umich.edu/caliper/info/user/' , ''), '+', '@'
) AS user_login_name,
@canvas_data_id_increment + CAST(JSON_EXTRACT_SCALAR(object.extensions, '$.kaf:course_id') AS INT64) AS course_id,
object.name AS name,
datetime(EVENT_TIME) AS access_time
FROM event_store.expanded
WHERE
ed_app.id = 'https://aakaf.mivideo.it.umich.edu/caliper/info/app/KafEdApp'
AND TYPE = 'MediaEvent'
AND action = 'Started'
AND JSON_EXTRACT_SCALAR(object.extensions, '$.kaf:course_id') IN UNNEST(@course_ids_short)
''',
"app_display_name": "MiVideo",
"/* mention if the caliper event data is providing long or short canvas id and change the query to store long id as in this case": "*/",
"canvas_course_id_format": "SHORT",
"urls": {"prefix": "https://aakaf.mivideo.it.umich.edu/caliper/info/media/" , "postfix": ""}
}
},
# Disable/Enable courses_enabled api
"COURSES_ENABLED": false,
Expand Down

0 comments on commit 9fb4601

Please sign in to comment.