[Pharo-users] Microservices using Pharo
serpi90 at gmail.com
Wed Jun 27 02:19:59 EDT 2018
At work we're using some microservices in pharo, implemented with Zink and
Teapot, can't tell you much about performance because they are not being
stress tested currently.
I'm using Traefik as a load balancer WITH sticky session on docker, mainly
because it scales acording to the docker configuration (traefik can detect
new docker instances and add them to the load balancer group)
To keep images running we use a docker swarm which is in charge of
restarting them if they fail. Why? ease of use, it's easier to deploy and
keep track of what is where.
For the Pharo docker image i'm running one based on debian slim, with the
VM for Pharo 6.1 (32 bit). Code in https://github.com/ba-st/docker-pharo,
available in the docker registry as basmalltalk/pharo:6.1
As i have no need for the sources file and removing it reduces the final
image size it's removed, but you can add it (or prevent it's removal if you
If you need help with any of these, please ask (if it's urgent send me a
direct mail, i don't read the Pharo list very often).
On 27 June 2018 at 02:42, jtuchel at objektfabrik.de <jtuchel at objektfabrik.de>
> Am 26.06.18 um 21:41 schrieb Norbert Hartl:
> Am 26.06.2018 um 20:44 schrieb Andrei Stebakov <lispercat at gmail.com>:
> What would be an example for load balancer for Pharo images? Can we run
> multiple images on the same server or for the sake of balancing
> configuration we can only run one image per server?
> There are a lot of possibilities. You can start multiple images on
> different ports and use nginx with an upstream rule to load balance. I
> would recommend using docker for spawning multiple images on a host. Again
> with nginx as frontend load balancer. The point is that you can have at
> least twice as muh inages running then you have CPU cores. And of course a
> lot more.
> the last time I checked nginx, the load balancing and sticky session stuff
> was not available in the free edition. So I guess you either pay for nginx
> (which I think is good) or you know some free 3d party addons...
> I wonder what exactly the benefit of Docker is in that game? On our
> servers we run 10 images on 4 cores with HT (8 virtual cores) and very
> rareley have real performance problems. We use Glorp, so there is a lot of
> SQL queriing going on for quite basic things already. So my guess would be
> that your "2 images per core" are conservative and leave air for even a
> third one, depending on all the factors already discussed here.
> What's not to underestimate is all the stuff around monitoring and
> restarting images when things go wrong, but that's another story...
> Objektfabrik Joachim Tuchel mailto:jtuchel at objektfabrik.de <jtuchel at objektfabrik.de>
> Fliederweg 1 http://www.objektfabrik.de
> D-71640 Ludwigsburg http://joachimtuchel.wordpress.com
> Telefon: +49 7141 56 10 86 0 Fax: +49 7141 56 10 86 1
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Pharo-users