Skip to content

Commit

Permalink
Merge branch 'develop' into documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
adriiglz committed Feb 18, 2024
2 parents 8b9d3ee + 9bb9172 commit b410db9
Show file tree
Hide file tree
Showing 6 changed files with 262 additions and 101 deletions.
1 change: 1 addition & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
55 changes: 53 additions & 2 deletions docs/src/01_introduction_and_goals.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,13 @@ ifndef::imagesdir[:imagesdir: ../images]
Describes the relevant requirements and the driving forces that software architects and development team must consider.
These include
* underlying business goals,
* underlying business goals,
* essential features,
* essential functional requirements,
* quality goals for the architecture and
* relevant stakeholders and their expectations
****
In these points, the main goals and functional requirements will be explained. In order to give context on how the webapp will be developed.

=== Requirements Overview

Expand All @@ -40,7 +41,43 @@ Keep these excerpts as short as possible. Balance readability of this document w
See https://docs.arc42.org/section-1/[Introduction and Goals] in the arc42 documentation.
****

The functional requirements have been grouped into the different microservices the web application will have.
==== User and Authorization Services
[decimal]
. The User service allows the user to
[arabic]
.. Register.
.. Delete the account.
.. Update the account.
.. Recover the password.
. The authorization service allows the user to
[arabic]
.. Log in.
.. Log out.
. A user can retrieve the following information from the User service
[arabic]
.. Name.
.. Email.
.. Profile picture.
.. Questions answered.
. The system must be able to manage the user's access to the system.

==== Question Service
[decimal, start=5]
. The Question service retrieves questions generated from wikidata.
. A user can retrieve the following information from the Question service
[arabic]
.. Select a category.
.. Select a difficulty.
.. Select a question.
.. Select an answer.
. Questions must be stored in a database.
. The database used is MongoDB.
. Questions are classified by
[arabic]
.. Category.
.. Difficulty.
. The questions should be selected randomly.
=== Quality Goals

[role="arc42help"]
Expand All @@ -62,6 +99,20 @@ If you as an architect do not know how the quality of your work will be judged..
.Form
A table with quality goals and concrete scenarios, ordered by priorities
****
[options="header", cols="1,1"]
|===
| Goal | Description
| Testability |Test will be developed, so the application has a good quality.

| Usability | The application has to be intuitive for its users.

| Portability | The application works in different devices and browsers. With different screen sizes.

| Performance | The application can handle a big number of users and give good response times.



|===

=== Stakeholders

Expand Down
66 changes: 41 additions & 25 deletions docs/src/03_system_scope_and_context.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -48,28 +48,44 @@ The title of the table is the name of your system, the three columns contain the
****

**<Diagram or Table>**

**<optionally: Explanation of external domain interfaces>**

=== Technical Context

[role="arc42help"]
****
.Contents
Technical interfaces (channels and transmission media) linking your system to its environment. In addition a mapping of domain specific input/output to the channels, i.e. an explanation which I/O uses which channel.
.Motivation
Many stakeholders make architectural decision based on the technical interfaces between the system and its context. Especially infrastructure or hardware designers decide these technical interfaces.
.Form
E.g. UML deployment diagram describing channels to neighboring systems,
together with a mapping table showing the relationships between channels and input/output.
****

**<Diagram or Table>**

**<optionally: Explanation of technical interfaces>**

**<Mapping Input/Output to Channels>**
[plantuml,"Context diagram",png]
----
actor Player
actor Client
[Wikidata] <<external>>
[WIQ Game] <<system>>
[UsersAPI] <<internal>>
[GeneratedQuestionsAPI] <<internal>>
Player ..> (WIQ Game) : register/login
Client ..> (WIQ Game) : view data
[GeneratedQuestionsAPI] ..> Wikidata
[WIQ Game] ..> UsersAPI
[WIQ Game] ..> GeneratedQuestionsAPI
----

[cols="e,2e" options="header"]
|===
|Element |Description

|Player
|Plays the game and can consult past scores

|Client
|Can access the data about players and generated questions

|WIQ Game
|Main system in which generated questions are shown and can be answered by players

|Wikidata
|External data repository from which questions are generated using the WikidataAPI

|MongoDB
|Database for storing generated questions, players' info and scores

|Users Info API
|Allows clients to see the info about players stored in the database

|Generated Questions API
|Allows clients to see the info about generated questions stored in the database
|===
150 changes: 77 additions & 73 deletions docs/src/05_building_block_view.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -63,18 +63,53 @@ In the best case you will get away with examples or simple signatures.
****

_**<Overview Diagram>**_
[plantuml,"White box overall system",png]
----
actor Player
actor Client
[Wikidata]
rectangle "WIQ Game (Level 1)"{
[WIQ Game GUI]
[Data View]
[UsersAPI]
[GeneratedQuestionsAPI] #BurlyWood
Player ..> (WIQ Game GUI)
Client ..> (Data View)
[GeneratedQuestionsAPI] ..> Wikidata
[WIQ Game GUI] ..> UsersAPI
[WIQ Game GUI] ..> GeneratedQuestionsAPI
[Data View] ..> UsersAPI
[Data View] ..> GeneratedQuestionsAPI
}
----

Motivation::

_<text explanation>_
We made the decomposition separating the functionallities (The names are self explanatory but components will be described later)

Contained Black boxes::

Contained Building Blocks::
_<Description of contained building block (black boxes)>_
[cols="e,2e" options="header"]
|===
|Name |Responsibility

|WIQ Game GUI
|Main window in which questions are shown and can be answered by the player. The latter can also see past scores.

|Data View
|Access to data about users and generated questions for the client.

|Generated Questions API
|In charge of generating the questions and storing their data

|UsersAPI
|In charge of keeping track of the data of the users (registration and scores)

|Wikidata
|External element used for the generation of questions

Important Interfaces::
_<Description of important interfaces>_
|===

[role="arc42help"]
****
Expand All @@ -97,8 +132,6 @@ Its headline is the name of the black box.
****


==== <Name black box 1>

[role="arc42help"]
****
Here you describe <black box 1>
Expand All @@ -113,37 +146,6 @@ according the the following black box template:
****

_<Purpose/Responsibility>_

_<Interface(s)>_

_<(Optional) Quality/Performance Characteristics>_

_<(Optional) Directory/File Location>_

_<(Optional) Fulfilled Requirements>_

_<(optional) Open Issues/Problems/Risks>_




==== <Name black box 2>

_<black box template>_

==== <Name black box n>

_<black box template>_


==== <Name interface 1>

...

==== <Name interface m>



=== Level 2

Expand All @@ -156,57 +158,59 @@ Please prefer relevance over completeness. Specify important, surprising, risky,
Leave out normal, simple, boring or standardized parts of your system
****

==== White Box _<building block 1>_
==== Generated Questions API (White Box)

[role="arc42help"]
****
...describes the internal structure of _building block 1_.
****

_<white box template>_

==== White Box _<building block 2>_


_<white box template>_

...

==== White Box _<building block m>_


_<white box template>_

[plantuml,"Generated Questions API (White Box)",png]
----
[Wikidata]
[wikidatanpm] <<library>>
[WIQ Game GUI]
[Data View]
database MongoDB
rectangle "GenedQuestsAPI (Level 2)"{
=== Level 3
[GenQuestsService] ..> wikidatanpm
[GenQuestsService] ..> Wikidata
[GenQuestsService] <--> MongoDB
[WIQ Game GUI] ..> GenQuestsService : new Question
[Data View] ..> GenQuestsService : get Questions
}
----

[role="arc42help"]
****
Here you can specify the inner structure of (some) building blocks from level 2 as white boxes.
When you need more detailed levels of your architecture please copy this
part of arc42 for additional levels.
****
Motivation::

We made the decomposition separating the functionallities.

==== White Box <_building block x.1_>

[role="arc42help"]
****
Specifies the internal structure of _building block x.1_.
****
Contained Black boxes::

[cols="e,2e" options="header"]
|===
|Name |Responsibility

_<white box template>_
|GenQuestsService
|Receives different petitions regarding the generation of questions or their retrieval and responds accordingly.

|wikidatanpm
|External library that facilitates and simplifies the use of wikidata for the generation of questions.

==== White Box <_building block x.2_>
|MongoDB
|The data of the generated questions is stored here for showing it later to the client.

_<white box template>_
|===

Additional explanation of relationships::

The service is requested either the generation of a question or the retrieval of a subset (from WIQ Game GUI or
Data View respectively).

==== White Box <_building block y.1_>
For the first case, it makes use of the library to generate the question, retrieves it
for the interface to use and stores the pertinent data in the DB.

_<white box template>_
In the other case, it just makes the query according to the client choosings and retrieves the data of the
questions for the Data View to show.
Loading

0 comments on commit b410db9

Please sign in to comment.