Backend Development 6 min read

Inside 360’s Image Service: How Davinci and Picasso Power Fast Uploads and Downloads

This article explains the architecture of 360’s image hosting platform, detailing the Davinci upload pipeline and the Picasso download flow, the processing steps, caching layers, and the supporting infrastructure that enables billions of image requests daily.

360 Zhihui Cloud Developer
360 Zhihui Cloud Developer
360 Zhihui Cloud Developer
Inside 360’s Image Service: How Davinci and Picasso Power Fast Uploads and Downloads

Overview

Many companies build shared infrastructure services such as push, cache, MQ, storage, and image hosting to improve service quality and development speed. 360’s image service, called HULK, supports most business lines with features like cropping, compression, filters, pHash calculation, face detection, format conversion, and GIF first‑frame extraction, handling over 150 billion page views per day.

Upload Module (Davinci)

The upload process consists of the following steps:

SDK upload : Clients use an SDK or direct HTTP POST to the Davinci upload API, which is load‑balanced by Nginx on port 80.

Nginx 80 forwarding : Requests are forwarded via upstream to backend Nginx on port 8360.

Queueing : The backend service enqueues the upload task to Gearman, returning a task ID for result queries.

Image processing and storage : Gearman workers asynchronously compress, crop, perform face detection, etc., then store the image and its metadata in Cassandra; the processing result is cached in Redis.

Result retrieval : Clients poll the task ID to obtain the final image URL and metadata. Synchronous upload and callback notifications are also supported.

Davinci architecture diagram
Davinci architecture diagram

Download Module (Picasso)

The download flow works as follows:

Image URL request : The client requests an image URL, which is resolved via CNAME to a CDN node. If the CDN has the image cached, it returns the data immediately.

CDN miss : The request is sent back to the backend Nginx on port 80.

Varnish front‑cache : Varnish checks its cache; a hit returns the image directly.

Backend handling : On a miss, Nginx on port 8360 forwards the request to PHP‑FastCGI, which reads the image from storage.

Image processing : The Nginx filter module (built with GraphicsMagick) applies transformations specified in the URL parameters, such as cropping, filters, black‑white conversion, face cropping, or extracting the first frame of a GIF.

Response : The processed image is returned to the client and cached at the CDN edge.

Picasso architecture diagram
Picasso architecture diagram

Supporting Infrastructure

The service relies on LVS for load balancing, Redis for caching task results, Cassandra for persistent storage, CDN for edge delivery, QCMD for command execution, and the Wonder monitoring system, forming a stable and maintainable backend ecosystem.

backend architecturecachingCDNImage Servicedownload flowupload pipeline
360 Zhihui Cloud Developer
Written by

360 Zhihui Cloud Developer

360 Zhihui Cloud is an enterprise open service platform that aims to "aggregate data value and empower an intelligent future," leveraging 360's extensive product and technology resources to deliver platform services to customers.

0 followers
Reader feedback

How this landed with the community

login Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.