Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Player URL possibly invalid #1004

Closed
lkiesow opened this issue Sep 17, 2024 · 2 comments
Closed

Player URL possibly invalid #1004

lkiesow opened this issue Sep 17, 2024 · 2 comments
Assignees
Labels
priority:high type:bug v:2 Everything related to the Stud.IP Opencast Plugin Version 2.x v:3 Everything related to the Stud.IP Opencast Plugin Version 3.x
Milestone

Comments

@lkiesow
Copy link
Contributor

lkiesow commented Sep 17, 2024

The plugin looks for the search service and then uses ${search.service.host}/play/${id} to link to the player. That's not necessarily correct and caused a completely broken plugin for us after the last update:

if ($endpoint['service_type'] == 'search') {
$url = parse_url($endpoint['service_url']);
$oc_url = $url['scheme'] . '://'. $url['host']
. ($url['port'] ? ':' . $url['port'] : '');
$url = $oc_url . '/play/' . $episode_id;

Instead of using the search service, the plugin should actually use org.opencastproject.engage.ui.player.redirect which provides /play. The service should usually be on the presentation node:

 curl -s -u admin:opencast 'https://develop.opencast.org/services/services.json?serviceType=org.opencastproject.engage.ui.player.redirect' | jq
{
  "services": {
    "service": {
      "type": "org.opencastproject.engage.ui.player.redirect",
      "host": "https://develop.opencast.org",
      "path": "/play",
      "active": true,
      "online": true,
      "maintenance": false,
      "jobproducer": false,
      "onlinefrom": "2024-09-17T02:00:59.370+02:00",
      "service_state": "NORMAL",
      "state_changed": "2024-09-17T02:00:59.370+02:00",
      "error_state_trigger": 0,
      "warning_state_trigger": 0
    }
  }
}
@lkiesow lkiesow added type:bug v:2 Everything related to the Stud.IP Opencast Plugin Version 2.x labels Sep 17, 2024
dennis531 added a commit to dennis531/studip-opencast-plugin that referenced this issue Sep 18, 2024
@tgloeggl tgloeggl added this to the Opencast 2.14 milestone Sep 18, 2024
@tgloeggl tgloeggl reopened this Sep 18, 2024
tgloeggl added a commit that referenced this issue Sep 18, 2024
@tgloeggl tgloeggl assigned tgloeggl and unassigned dennis531 Sep 24, 2024
@tgloeggl tgloeggl added the v:3 Everything related to the Stud.IP Opencast Plugin Version 3.x label Sep 24, 2024
@tgloeggl tgloeggl modified the milestones: Opencast 2.14, Opencast 3.0 Sep 24, 2024
@tgloeggl
Copy link
Member

This also is a problem in the new plugin version

@tgloeggl
Copy link
Member

More changes for V2: 8c59206

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority:high type:bug v:2 Everything related to the Stud.IP Opencast Plugin Version 2.x v:3 Everything related to the Stud.IP Opencast Plugin Version 3.x
Projects
Status: Testing
Development

No branches or pull requests

3 participants