BuddyDev

Search

oEmbed parameters for performance?

  • Participant
    Level: Enlightened
    Posts: 57
    Tony on #32042

    Hello –

    I am using the xProfile plugin. I like it but I am seeing some real performance issues with the oEmbed field.
    In my buddyboss site I am using it so members can link to their videos on youtube, vimeo etc.

    It takes up to 10 seconds for the preview of the video to display in some cases.
    Are there any parameters that I can use to speed this up?

  • Participant
    Level: Enlightened
    Posts: 57
    Tony on #32043
    This reply has been marked as private.
  • Keymaster
    (BuddyDev Team)
    Posts: 24706
    Brajesh Singh on #32056

    Hi Tony,
    Thank you for reporting the issue.

    Currently, we are not caching the results of the oembed and that is the most probably reason for it.

    I will update the plugin and add cache for oEmbed result in next week’s release. That should fix the issue for you.

    Regards
    Brajesh

  • Participant
    Level: Enlightened
    Posts: 57
    Tony on #32297

    Hi Brajesh –

    I saw the plugin was updated, but I didn’t see any mention of this in the release notes.
    Was this updated in the most recent 1.1.6 update?

    Thank you.

  • Keymaster
    (BuddyDev Team)
    Posts: 24706
    Brajesh Singh on #32299

    Hi Tony,
    Thank you for checking back.

    I have explored it now. It is not feasible to cache properly with current BuddyPress setup.
    In order to use the cache we need the ability to store result and delete/update when a new value is entered.

    Currently, BuddyPress only provides the value reliably(url). In teh display callback, even the user id is optional and not always available. We need the user, field id and value to do the caching reliably.

    Another strategy will be to hash the url and create a transient based on this hashed url. The problem with this approach is when a value is updated, we will not be able to clear old value as the key changes.

    I am unable to add this solution in the plugin. I can certainly add a filter to allow you load the content from the remote site or a cached store using the second strategy(you will need to implement your own caching strategy). Let me know if it works for you?

    Regards
    Brajesh

  • Participant
    Level: Enlightened
    Posts: 57
    Tony on #32306

    If this helps answer the question, I am using BuddyBoss plus the LSCache plugin with Lite Speed server.

You must be logged in to reply to this topic.

This topic is: not resolved