From b82a205b740840e2a7d0fa3eecf3e361ca73416e Mon Sep 17 00:00:00 2001 From: Marc Radulescu Date: Wed, 26 Nov 2014 18:51:12 +0100 Subject: added office analogy to help understanding of gitlab architecture --- doc/development/architecture.md | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) (limited to 'doc/development/architecture.md') diff --git a/doc/development/architecture.md b/doc/development/architecture.md index c4813d22eaa..109b21ab2a5 100644 --- a/doc/development/architecture.md +++ b/doc/development/architecture.md @@ -8,6 +8,38 @@ EE releases are available not long after CE releases. To obtain the GitLab EE th Both EE and CE require an add-on component called gitlab-shell. It is obtained from the [gitlab-shell repository](https://gitlab.com/gitlab-org/gitlab-shell/tree/master). New versions are usually tags but staying on the master branch will give you the latest stable version. New releases are generally around the same time as GitLab CE releases with exception for informal security updates deemed critical. +## Physical office analogy + +You can imagine GitLab as a physical office. + +**The repositories** are the goods GitLab handling. +They can be stored in a warehouse. +This can be either a hard disk, or something more complex, such as a NFS filesystem; + +**NginX** acts like the front-desk. +Users come to NginX and request actions to be done by workers in the office; + +**The database** is a series of metal file cabinets with information on: + - The goods in the warehouse (metadata, issues, merge requests etc); + - The users coming to the front desk (permissions) + +**Redis** is a [communication board with “cubby holes”](http://cache3.asset-cache.net/gc/52392865-mail-lies-in-cubby-holes-in-the-trenton-post-gettyimages.jpg?v=1&c=IWSAsset&k=2&d=OCUJ5gVf7YdJQI2Xhkc2QMDTqXzgg%2Fa7CPCCcA9Ug%2BfL2iMdhkcAYaLLAievbZlwJI9YEbpjb1pB2Fh7Fge3%2FA%3D%3D) that can contain tasks for office workers; + +**Sidekiq** is a worker that primarily handles sending out emails. +It takes tasks from the Redis communication board; + +**A Unicorn worker** is a worker that handles quick/mundane tasks. +They work with the communication board (Redis). +Their job description: + - check permissions by checking the user session stored in a Redis “cubby hole”; + - make tasks for Sidekiq; + - fetch stuff from the warehouse or move things around in there; + +**Gitlab-shell** is a third kind of worker that takes orders from a fax machine (SSH) instead of the front desk (HTTP). +Gitlab-shell communicates with Sidekiq via the “communication board” (Redis), and asks quick questions of the Unicorn workers either directly or via the front desk. + +**GitLab Enterprise Edition (the application)** is the collection of processes and business practices that the office is run by. + ## System Layout When referring to ~git in the pictures it means the home directory of the git user which is typically /home/git. -- cgit v1.2.1 From 8ccaee19792ac10dffd7a86be0835f2ea5674d0e Mon Sep 17 00:00:00 2001 From: Marc Radulescu Date: Wed, 26 Nov 2014 20:54:42 +0100 Subject: replaced hotlink --- doc/development/architecture.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc/development/architecture.md') diff --git a/doc/development/architecture.md b/doc/development/architecture.md index 109b21ab2a5..68c813d4339 100644 --- a/doc/development/architecture.md +++ b/doc/development/architecture.md @@ -23,7 +23,7 @@ Users come to NginX and request actions to be done by workers in the office; - The goods in the warehouse (metadata, issues, merge requests etc); - The users coming to the front desk (permissions) -**Redis** is a [communication board with “cubby holes”](http://cache3.asset-cache.net/gc/52392865-mail-lies-in-cubby-holes-in-the-trenton-post-gettyimages.jpg?v=1&c=IWSAsset&k=2&d=OCUJ5gVf7YdJQI2Xhkc2QMDTqXzgg%2Fa7CPCCcA9Ug%2BfL2iMdhkcAYaLLAievbZlwJI9YEbpjb1pB2Fh7Fge3%2FA%3D%3D) that can contain tasks for office workers; +**Redis** is a [communication board with “cubby holes”](https://dev.gitlab.org/gitlab/gitlabhq/blob/master/doc/development/cubby_holes.jpg) that can contain tasks for office workers; **Sidekiq** is a worker that primarily handles sending out emails. It takes tasks from the Redis communication board; -- cgit v1.2.1 From c85d4af88921aba31afd39c3403fe2d41381c2ca Mon Sep 17 00:00:00 2001 From: Marc Radulescu Date: Thu, 27 Nov 2014 10:24:19 +0100 Subject: remove unnecessarry image --- doc/development/architecture.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc/development/architecture.md') diff --git a/doc/development/architecture.md b/doc/development/architecture.md index 68c813d4339..209182e7742 100644 --- a/doc/development/architecture.md +++ b/doc/development/architecture.md @@ -23,7 +23,7 @@ Users come to NginX and request actions to be done by workers in the office; - The goods in the warehouse (metadata, issues, merge requests etc); - The users coming to the front desk (permissions) -**Redis** is a [communication board with “cubby holes”](https://dev.gitlab.org/gitlab/gitlabhq/blob/master/doc/development/cubby_holes.jpg) that can contain tasks for office workers; +**Redis** is a communication board with “cubby holes” that can contain tasks for office workers; **Sidekiq** is a worker that primarily handles sending out emails. It takes tasks from the Redis communication board; -- cgit v1.2.1 From ad6c372eeee5d112ad199dd4e487df584976445d Mon Sep 17 00:00:00 2001 From: Ewan Edwards Date: Tue, 3 Feb 2015 15:18:40 -0800 Subject: Fix a number of discovered typos, capitalization of developer and product names, plus a couple of instances of bad Markdown markup. --- doc/development/architecture.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'doc/development/architecture.md') diff --git a/doc/development/architecture.md b/doc/development/architecture.md index 209182e7742..714cc016004 100644 --- a/doc/development/architecture.md +++ b/doc/development/architecture.md @@ -16,8 +16,8 @@ You can imagine GitLab as a physical office. They can be stored in a warehouse. This can be either a hard disk, or something more complex, such as a NFS filesystem; -**NginX** acts like the front-desk. -Users come to NginX and request actions to be done by workers in the office; +**Nginx** acts like the front-desk. +Users come to Nginx and request actions to be done by workers in the office; **The database** is a series of metal file cabinets with information on: - The goods in the warehouse (metadata, issues, merge requests etc); @@ -70,7 +70,7 @@ To summarize here's the [directory structure of the `git` user home directory](. ps aux | grep '^git' -GitLab has several components to operate. As a system user (i.e. any user that is not the `git` user) it requires a persistent database (MySQL/PostreSQL) and redis database. It also uses Apache httpd or nginx to proxypass Unicorn. As the `git` user it starts Sidekiq and Unicorn (a simple ruby HTTP server running on port `8080` by default). Under the GitLab user there are normally 4 processes: `unicorn_rails master` (1 process), `unicorn_rails worker` (2 processes), `sidekiq` (1 process). +GitLab has several components to operate. As a system user (i.e. any user that is not the `git` user) it requires a persistent database (MySQL/PostreSQL) and redis database. It also uses Apache httpd or Nginx to proxypass Unicorn. As the `git` user it starts Sidekiq and Unicorn (a simple ruby HTTP server running on port `8080` by default). Under the GitLab user there are normally 4 processes: `unicorn_rails master` (1 process), `unicorn_rails worker` (2 processes), `sidekiq` (1 process). ### Repository access @@ -146,13 +146,13 @@ nginx Apache httpd -- [Explanation of apache logs](http://httpd.apache.org/docs/2.2/logs.html). +- [Explanation of Apache logs](http://httpd.apache.org/docs/2.2/logs.html). - `/var/log/apache2/` contains error and output logs (on Ubuntu). - `/var/log/httpd/` contains error and output logs (on RHEL). redis -- `/var/log/redis/redis.log` there are also logrotated logs there. +- `/var/log/redis/redis.log` there are also log-rotated logs there. PostgreSQL -- cgit v1.2.1