• Docs >
  • 29. Pull resources using HTTP/1.1
Shortcuts

29. Pull resources using HTTP/1.1

Once you understand that there are different fetch backends, you can configure the server to pull resources using HTTP/1.1. There are two different ways to go about this, using different fetch backends.

29.1. The http-fetch fetch backend

This backend supports pooling, and specifying both a host and a path-prefix. HTTPS is not supported

To use it, instead of having root-dir in the devlove contain a string, it should contain the backend configuration. Like this:

---
shimmercat-devlove:
  domains:
    elec development.aspdotnetstorefront.outdoorexperten.se:
      root-dir:
        fetch-backend: http
        http-port: lookup(development.aspdotnetstorefront.outdoorexperten.se):80
        use-host: development.aspdotnetstorefront.outdoorexperten.se
      views-dir: views-dir
      changelist-settings:
        tOld: 7200
        tNew: 20

Notice there:

  • views-dir must be given if we are using any backend which is not a local-filesystem backend.

  • The same as in other cases, it’s important to set the changelist-settings

  • It’s also possible to specify a key path-prefix at the same level than fetch-backend with a fragment to prepend to the path.

29.2. The use-consultant fetch backend

This uses one of the consultants configured for this electric domain, the one that you name it. As such, it supports HTTPS and pooling, although such configuration is just taken from the consultant. To use it, have an object under root-dir with a keyword use-consultant and the name of the consultant to use (which you should have also defined):

shimmercat-devlove:
   domains:
      elec www.supershoes.com:
          consultant:
            connect-to: "8080"
          root-dir:
            use-consultant: default