Iznik is a platform for online reuse of unwanted items. This is the fast API server, written in Go.
The aim is to provide fast read-only access, so that we can:
- Render pages significantly faster than when using the PHP server. Language wars are dull, but Go is faster, and the easy parallelisation which goroutines offer make it possible to reduce the latency of individual calls dramatically.
- Reduce the CPU load on our limited server hardware. Most Freegle workload is read operations, and Go is much lighter on CPU than PHP.
So although having two servers in different languages is an niffy architecture smell, the nifty practical benefits are huge.
These are out of scope:
- Access to data which is private to moderators.
- Almost all write-access or any kind of actions.
Those things are done using the PHP API. For that reason the CircleCI testing for this server installs the PHP server code to set up a test environment.
The development has been funded by Freegle for use in the UK, but it is an open source platform which can be used or adapted by others.
It would be very lovely if you sponsored us.
This code is licensed under the GPL v2 (see LICENSE file). If you intend to use it, Freegle would be interested to hear about it; you can mail [email protected].