Social platform embeds not working

Facebook, LinkedIn, X, and some other platforms use HTTP range requests to read Open Graph tags. In certain cases, this may cause the associated crawler to not work for Magnolia websites.

A workaround is to use a voter that bypasses the gzip filter if the incoming request is within the specified range type and is coming from the configured platform.

Click to see an example configuration for Facebook.
config.server.filters.gzip.bypasses.facebook.yaml
gzip:
  class: info.magnolia.module.cache.filter.GZipFilter
  jcr:primaryType: mgnl:content
  bypasses:
    jcr:primaryType: mgnl:content
    vaadinPush:
      class: info.magnolia.voting.voters.URIRegexVoter
      enabled: true
      pattern: ^.*\/.magnolia\/admincentral(-m5)*\/PUSH(\?.+)*$
    facebook:
      class: info.magnolia.voting.voters.BoolVoterSet
      op: AND
      voters:
        userAgent:
          class: info.magnolia.voting.voters.RequestHeaderPatternRegexVoter
          headerName: User-Agent
          pattern: .*facebookexternalhit.*
        rangeRequest:
          class: info.magnolia.voting.voters.RequestHeaderPatternRegexVoter
          headerName: Range
          pattern: .*
Feedback

DX Core

×

Location

This widget lets you know where you are on the docs site.

You are currently perusing through the DX Core docs.

Main doc sections

DX Core Headless PaaS Legacy Cloud Incubator modules