✨
Singularity
English
English
  • Overview
    • What is Singularity
    • V1 or V2
  • Installation
    • Download binaries
    • Install via docker
    • Built from source
    • Deploy to production
    • Version upgrade
  • Data Preparation
    • Get Started
    • Performance Tuning
  • Content Distribution
    • Distribute CAR files
  • Deal Making
    • Create a deal schedule
  • Topics
    • Inline Preparation
    • Benchmark
  • 💻CLI Reference
    • Menu
    • Ez Prep
    • Version
    • Admin
      • Init
      • Reset
      • Migrate Dataset
      • Migrate Schedule
    • Download
    • Extract Car
    • Deal
      • Schedule
        • Create
        • List
        • Update
        • Pause
        • Resume
        • Remove
      • Send Manual
      • List
    • Run
      • Api
      • Dataset Worker
      • Content Provider
      • Deal Tracker
      • Deal Pusher
      • Download Server
    • Wallet
      • Import
      • List
      • Remove
    • Storage
      • Create
        • Acd
        • Azureblob
        • B2
        • Box
        • Drive
        • Dropbox
        • Fichier
        • Filefabric
        • Ftp
        • Google Cloud Storage
        • Gphotos
        • Hdfs
        • Hidrive
        • Http
        • Internetarchive
        • Jottacloud
        • Koofr / Digi Storage
          • Digistorage
          • Koofr / Digi Storage
          • Other
        • Local
        • Mailru
        • Mega
        • Netstorage
        • Onedrive
        • Oos
          • Env_auth
          • Instance_principal_auth
          • No_auth
          • Resource_principal_auth
          • User_principal_auth
        • Opendrive
        • Pcloud
        • Premiumizeme
        • Putio
        • Qingstor
        • AWS S3 and compliant
          • Aws
          • Alibaba
          • Arvancloud
          • Ceph
          • Chinamobile
          • Cloudflare
          • Digitalocean
          • Dreamhost
          • Huaweiobs
          • Ibmcos
          • Idrive
          • Ionos
          • Liara
          • Lyvecloud
          • Minio
          • Netease
          • Other
          • Qiniu
          • Rackcorp
          • Scaleway
          • Seaweedfs
          • Stackpath
          • Storj
          • Tencentcos
          • Wasabi
        • Seafile
        • Sftp
        • Sharefile
        • Sia
        • Smb
        • Storj
          • Existing
          • New
        • Sugarsync
        • Swift
        • Union
        • Uptobox
        • Webdav
        • Yandex
        • Zoho
      • Explore
      • List
      • Remove
      • Update
        • Acd
        • Azureblob
        • B2
        • Box
        • Drive
        • Dropbox
        • Fichier
        • Filefabric
        • Ftp
        • Google Cloud Storage
        • Gphotos
        • Hdfs
        • Hidrive
        • Http
        • Internetarchive
        • Jottacloud
        • Koofr / Digi Storage
          • Digistorage
          • Koofr / Digi Storage
          • Other
        • Local
        • Mailru
        • Mega
        • Netstorage
        • Onedrive
        • Oos
          • Env_auth
          • Instance_principal_auth
          • No_auth
          • Resource_principal_auth
          • User_principal_auth
        • Opendrive
        • Pcloud
        • Premiumizeme
        • Putio
        • Qingstor
        • AWS S3 and compliant
          • Aws
          • Alibaba
          • Arvancloud
          • Ceph
          • Chinamobile
          • Cloudflare
          • Digitalocean
          • Dreamhost
          • Huaweiobs
          • Ibmcos
          • Idrive
          • Ionos
          • Liara
          • Lyvecloud
          • Minio
          • Netease
          • Other
          • Qiniu
          • Rackcorp
          • Scaleway
          • Seaweedfs
          • Stackpath
          • Storj
          • Tencentcos
          • Wasabi
        • Seafile
        • Sftp
        • Sharefile
        • Sia
        • Smb
        • Storj
          • Existing
          • New
        • Sugarsync
        • Swift
        • Union
        • Uptobox
        • Webdav
        • Yandex
        • Zoho
      • Rename
    • Prep
      • Create
      • List
      • Status
      • Rename
      • Attach Source
      • Attach Output
      • Detach Output
      • Start Scan
      • Pause Scan
      • Start Pack
      • Pause Pack
      • Start Daggen
      • Pause Daggen
      • List Pieces
      • Add Piece
      • Explore
      • Attach Wallet
      • List Wallets
      • Detach Wallet
      • Remove
  • 🌐Web API Reference
    • Admin
    • Deal Schedule
    • Deal
    • File
    • Job
    • Piece
    • Preparation
    • Storage
    • Wallet Association
    • Wallet
    • Specification
  • ❓FAQ
    • Database is locked
Powered by GitBook
On this page
  • 1. Start the Content Provider Service
  • 2. Methods for CAR File Download
  • Direct HTTP Download
  • Singularity Download Server
  • Singularity Download Utility

Was this helpful?

Edit on GitHub
  1. Content Distribution

Distribute CAR files

To ensure your data is easily accessible by storage providers, you need to distribute the CAR (Content Addressable Archive) files effectively.

1. Start the Content Provider Service

Begin by launching the content provider service. This service facilitates the download of pieces from the dataset you've prepared.

singularity run content-provider

2. Methods for CAR File Download

There are multiple ways for storage providers to download the CAR files:

Direct HTTP Download

Providers can utilize the HTTP API exposed by the content provider service to directly download the CAR file:

wget http://127.0.0.1:7777/piece/bagaxxxxxxxxxxx

If you've specified an output directory during preparation, the CAR files will be sourced directly from there. However, if you used inline preparation or accidentally deleted the CAR files, the service will retrieve the content from the original data source and serve it.

Singularity Download Server

If the data source is remote, i.e. comes from S3 or FTP, and the client has enabled inline preparation, then we can save the egress by assembling the CAR files directly from the original data source. Singularity download server allows streaming the CAR file directly from original source by first querying the content provider for the CAR file metadata which tells how to assemble the CAR file from the original files. Since it is a local HTTP server, you may choose to use any other HTTP client to download the CAR file, even with multithreading.

singularity run download-server --metadata-api "http://content-provider:7777" --bind "127.0.0.1:8888"
wget http://127.0.0.1:8888/piece/bagaxxxxxxxxxxx

This method also works with boost online deal, as the client can make a boost online deal proposal to SP using below command:

boost deal --http-url "http://127.0.0.1:8888/piece/bagaxxxx"

Or, when using Singularity to make deals, you can create a deal schedule with below command:

deal schedule create --url-template "http://127.0.0.1:8888/piece/{PIECE_CID}"

Singularity Download Utility

Similar to the download server, the download utility serves the same purpose without standing up a local HTTP server.

singularity download --api "http://content-provider:7777" bagaxxxxxxxxxxx

This utility communicates with the content provider service to fetch metadata about the piece. Once obtained, it uses this metadata to reconstruct the piece directly from the original data source.

PreviousPerformance TuningNextCreate a deal schedule

Last updated 1 year ago

Was this helpful?