https://github.com/synyx/imagescaler
a program that listens on rabbitmq message with image updates, loads an URL, scales the images and pushes them to a min.io instance
https://github.com/synyx/imagescaler
cdn image-processing minio object rabbitmq scaling storage
Last synced: 3 months ago
JSON representation
a program that listens on rabbitmq message with image updates, loads an URL, scales the images and pushes them to a min.io instance
- Host: GitHub
- URL: https://github.com/synyx/imagescaler
- Owner: synyx
- License: mit
- Created: 2019-05-24T21:07:34.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2020-04-30T07:49:23.000Z (about 6 years ago)
- Last Synced: 2025-12-18T20:49:11.322Z (6 months ago)
- Topics: cdn, image-processing, minio, object, rabbitmq, scaling, storage
- Language: Go
- Homepage:
- Size: 90.8 KB
- Stars: 6
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Message Driven Image Scaler
The imagescaler is a program that uses Go's builtin image processing capabilities to scale down images stored in an object storage (currently min.io) system.
## Motivation
Traditionally image processing is done from within a given program using native bindings to the overly popular ImageMagick (or similar programs). This has drawbacks:
* Operational complexity: The host or container needs to provide a recent version of the image processing tool. The lifecycle of the tool needs to managed, too.
* Synchronous calls of potentially expensive operations.
* ...
## Flow
The imagescaler consumes image update message, and reads them from the provided URL. This URL is not required to reside in the configured object storage, BTW. There are 2 different target scales:
* WEB for usage on web sites
* THUMBNAIL for icons or thumbnails (also on websites)
The scaled versions are stored (put) to a configured object storage (currently min.io) and new image update events for the scaled versions and their URLs are published.
## Message Format
Currently consuming and emitting messages formatted like this:
```
{
"userUUID": "schnubbli",
"imageUUID": "yolo",
"url": "http://localhost:9000/testbucket/vivian_robin.jpg",
"imageScale": "ORIGINAL"
}
```
## Configuration
tbw.