Skip to content

Commit 2603e3e

Browse files
authored
Merge pull request #216 from valens200/docs
chore(report): REST APIs week 1 & 2 report
2 parents f72a153 + e18ea34 commit 2603e3e

File tree

14 files changed

+417
-53
lines changed

14 files changed

+417
-53
lines changed

docs/2024/index.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,10 @@ More info to come here.
2020

2121
### Projects
2222

23-
[//]: # (Following are the important links to projects.)
23+
[//]: # "Following are the important links to projects."
2424

2525
| Contributor | Project |
26-
|:-----------------------------------------------------|:-------------------------------------------------------------|
26+
| :--------------------------------------------------- | :----------------------------------------------------------- |
2727
| [Aaditya Singh](https://github.com/aadsingh) | [Overhaul Scheduler Design](/docs/2024/scheduler) |
2828
| [Abdelrahman Jamal](https://github.com/Hero2323) | [AI Powered License Detection](/docs/2024/license-detection) |
2929
| [Abhishek Kumar](https://github.com/abhi-kumar17871) | [SPDX 3.0 Support](/docs/2024/spdx30) |
@@ -50,16 +50,16 @@ More info to come here.
5050
### Meetings table
5151

5252
| Topic(s) | Timings | Meeting link | ICS |
53-
|:--------------------|:------------------------------|:--------------------------------------------------------------------------------------------------------|:-------------------------------------|
54-
| General Meeting | *Thursday* 13:30 - 14:30 UTC | [Jitsi](https://meet.jit.si/moderated/5a655b3b6f3b4f83cddb13b93ac5408d6de48bf4ce1049f4128aa1c885478d48) | [.ics](/ics/gsoc_2024_weekly.ics) |
53+
| :------------------ | :---------------------------- | :------------------------------------------------------------------------------------------------------ | :----------------------------------- |
54+
| General Meeting | _Thursday_ 13:30 - 14:30 UTC | [Jitsi](https://meet.jit.si/moderated/5a655b3b6f3b4f83cddb13b93ac5408d6de48bf4ce1049f4128aa1c885478d48) | [.ics](/ics/gsoc_2024_weekly.ics) |
5555
| - | - | - | - |
56-
| SPDX Related | *Tuesday* 10:30 - 11:20 UTC | [Jitsi](https://moderated.jitsi.net/d623bb1284a54c83958eff31d2ecce9ed6b894312eda4ed9b400d5963f4e18b6) | [.ics](/ics/gsoc_2024_spdx.ics) |
57-
| REST API | *Tuesday* 11:00 - 11:50 UTC | [Jitsi](https://moderated.jitsi.net/d623bb1284a54c83958eff31d2ecce9ed6b894312eda4ed9b400d5963f4e18b6) | [.ics](/ics/gsoc_2024_rest.ics) |
58-
| CI Scanner | *Wednesday* 10:30 - 11:00 UTC | [Jitsi](https://moderated.jitsi.net/39896aad61bc4a27b9418ee6b78689348c65790e889046069dbe9c8c34110c9a) | [.ics](/ics/gsoc_2024_ci.ics) |
59-
| Scheduler Overhaul | *Friday* 10:30 - 11:00 UTC | [Jitsi](https://moderated.jitsi.net/5444f675f5ce47c788fa4238a6a958c53d3e62804e9243d5b807fbaa81f3120f) | [.ics](/ics/gsoc_2024_scheduler.ics) |
60-
| AI Powered Scanners | *Thursday* 10:30 - 11:20 UTC | [Jitsi](https://moderated.jitsi.net/15ee0bf46cb345e4accc817ed2967b55db216bf57c894c30bd1550ecf3ec3ace) | [.ics](/ics/gsoc_2024_ai.ics) |
56+
| SPDX Related | _Tuesday_ 10:30 - 11:20 UTC | [Jitsi](https://moderated.jitsi.net/d623bb1284a54c83958eff31d2ecce9ed6b894312eda4ed9b400d5963f4e18b6) | [.ics](/ics/gsoc_2024_spdx.ics) |
57+
| CI Scanner | _Wednesday_ 10:30 - 11:00 UTC | [Jitsi](https://moderated.jitsi.net/39896aad61bc4a27b9418ee6b78689348c65790e889046069dbe9c8c34110c9a) | [.ics](/ics/gsoc_2024_ci.ics) |
58+
| Scheduler Overhaul | _Friday_ 10:30 - 11:00 UTC | [Jitsi](https://moderated.jitsi.net/5444f675f5ce47c788fa4238a6a958c53d3e62804e9243d5b807fbaa81f3120f) | [.ics](/ics/gsoc_2024_scheduler.ics) |
59+
| AI Powered Scanners | _Thursday_ 10:30 - 11:20 UTC | [Jitsi](https://moderated.jitsi.net/15ee0bf46cb345e4accc817ed2967b55db216bf57c894c30bd1550ecf3ec3ace) | [.ics](/ics/gsoc_2024_ai.ics) |
6160

6261
### Photo
62+
6363
Photos to come soon.
6464

6565
Thanks for being part of the community. 💚

docs/2024/rest/index.md

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,28 +3,30 @@ sidebar_position: 1
33
title: Introduction
44
slug: /2024/rest/
55
---
6+
67
<!--
78
SPDX-License-Identifier: CC-BY-SA-4.0
89
910
SPDX-FileCopyrightText: 2024 Divij Sharma <divijs75@gmail.com>
1011
-->
1112

12-
## Author
13-
14-
[Divij Sharma](https://github.com/dvjsharma)
15-
16-
## Contact info
13+
## Authors
1714

18-
- [Email](mailto:divijs75@gmail.com)
19-
- [LinkedIn](https://linkedin.com/in/dvjsharma)
15+
- [Divij Sharma](https://github.com/dvjsharma)
16+
- [Email](mailto:divijs75@gmail.com)
17+
- [LinkedIn](https://linkedin.com/in/dvjsharma)
18+
- [Valens Niyonsenga](https://github.com/valens200)
19+
- [Email](mailto:valensniyonsenga2003@gmail.com)
20+
- [LinkedIn](https://www.linkedin.com/in/valens-niyonsenga-947440228/)
2021

2122
## Project title
2223

2324
REST API Improvements
2425

2526
## What's the project about?
2627

27-
In recent years, FOSSology's REST APIs have expanded significantly, enhancing user accessibility, flexibility, and automation. However, the development is not yet complete, prompting some users to resort to mocking WebUI access solely for information retrieval. With the development of FOSSology's new [React UI](https://github.com/fossology/FOSSologyUI) also underway, robust support for REST APIs becomes imperative.
28+
In recent years, FOSSology's REST APIs have expanded significantly, enhancing user accessibility, flexibility, and automation. However, the development is not yet complete, prompting some users to resort to mocking WebUI access solely for information retrieval. With the development of FOSSology's new [React UI](https://github.com/fossology/FOSSologyUI) also underway, robust support for REST APIs becomes imperative.
29+
2830

2931
This project aims to finalize the development of FOSSology's REST API by exposing any remaining endpoints, enhancing and upgrading existing ones to V2, increasing test coverage, and improving documentation. The approach involves a comprehensive review of each module to ensure the availability and exposure of required APIs for frontend consumption. These efforts will streamline development workflows, enhancing the overall usability of the FOSSology platform and facilitating the development of the new React UI.
3032

@@ -33,11 +35,22 @@ This project aims to finalize the development of FOSSology's REST API by exposin
3335
This project involves the following tasks:
3436

3537
1. **Exposing New API Endpoints:**
38+
3639
- Identify and expose any remaining endpoints required for frontend consumption.
3740
- Ensure that all endpoints are RESTful and adhere to the OpenAPI specification.
3841
- Update documentation to reflect the new endpoints and their usage.
3942

4043
2. **Upgrading Existing Endpoints to Version 2:**
44+
45+
- Develop a REST API guideline which will provide a solid set of rules to follow.
46+
- Upgrade existing endpoints to V2 based on the guideline, also ensuring backward compatibility.
47+
- Update documentation to reflect the changes and versioning.
48+
49+
3. **Increasing Test Coverage:**
50+
- Study each endpoint and its functionality to identify potential edge cases.
51+
- Write unit tests for all existing and new endpoints.
52+
53+
More specific details about each task can be found in the [Task Details Table](https://docs.google.com/document/d/158BZBZ5owLtI-SqD1MIduMy4bR3XLuwm4aDLynoFZAA/edit?usp=sharing).
4154
- Develop a REST API guideline which will provide a solid set of rules to follow.
4255
- Upgrade existing endpoints to V2 based on the guideline, also ensuring backward compatibility.
4356
- Update documentation to reflect the changes and versioning.
@@ -46,4 +59,4 @@ This project involves the following tasks:
4659
- Study each endpoint and its functionality to identify potential edge cases.
4760
- Write unit tests for all existing and new endpoints.
4861

49-
More specific details about each task can be found in the [Task Details Table](https://docs.google.com/document/d/158BZBZ5owLtI-SqD1MIduMy4bR3XLuwm4aDLynoFZAA/edit?usp=sharing).
62+
More specific details about each task can be found in the [Task Details Table](https://docs.google.com/document/d/158BZBZ5owLtI-SqD1MIduMy4bR3XLuwm4aDLynoFZAA/edit?usp=sharing).

docs/2024/rest/updates/_category_.json

Lines changed: 0 additions & 4 deletions
This file was deleted.
Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
---
2+
title: Community bonding
3+
author: Divij Sharma
4+
---
5+
<!--
6+
SPDX-License-Identifier: CC-BY-SA-4.0
7+
8+
SPDX-FileCopyright Text: 2024 Divij Sharma <divijs75@gmail.com>
9+
-->
10+
11+
# Community Bonding
12+
13+
## Introduction meeting
14+
15+
*(May 7,2024)*
16+
17+
This was the first meeting of the community bonding period for GSoC '24. Mentors and contributors introduced themselves, and the general meeting time and platform were decided.
18+
19+
## Meeting 1
20+
21+
*(May 9,2024)*
22+
23+
This was the first general meeting after the introduction meeting. Mentors discussed the importance of communication and the need for regular updates. The contributors were free to ask any questions they had.
24+
25+
## During community bonding week 1
26+
27+
*(May 9,2024- May 15,2024)*
28+
29+
### Activities
30+
31+
* I created an unofficial communication group with fellow contributors to get to know each other better.
32+
* I discussed the project and the tasks that need to be completed during the coding period with the mentors.
33+
* I clarified some of my doubts regarding the project timeline.
34+
35+
### Work done
36+
37+
* I was already familiar with the code-base because of my previous contributions to FOSSology. I started working on upgrading the REST APIs to version 2.
38+
* I fixed some minor bugs in the following of my uplink PRs related to the upgradation:
39+
- [feat(api): Upgrade User & Group APIs to Version 2 ](https://github.com/fossology/fossology/pull/2711)
40+
- [feat(api): Upgrade Folder, License & Obligation APIs to Version 2](https://github.com/fossology/fossology/pull/2712)
41+
42+
## Meeting 2
43+
44+
*(May 16,2024)*
45+
46+
We discussed the progress made during the first week of community bonding. Mentors asked if contributors were able to set up their development environments and if they faced any issues. Everyone gave a brief overview of the tasks they were working on.
47+
48+
## During community bonding week 2
49+
50+
*(May 16,2024- May 22,2024)*
51+
52+
### Activities
53+
54+
* I had calls with fellow contributors to help them set up their development environments.
55+
* I had a discussion with my colleague [Valens](https://github.com/valens200) about how we shall manage our tasks.
56+
57+
### Work done
58+
59+
* I continued working on upgrading the REST APIs to version 2.
60+
61+
* I finalized the work on a new endpoint to retrieve user copyright findings and also upgraded Jobs and Report APIs to version 2.
62+
- [feat(api): New endpoint to retrieve user copyright findings ](https://github.com/fossology/fossology/pull/2717)
63+
- [feat(api): Upgrade Jobs and Report APIs to Version 2 ](https://github.com/fossology/fossology/pull/2736)
64+
65+
66+
## Meeting 3
67+
68+
*(May 23,2024)*
69+
70+
We discussed the progress made during the second week of the community bonding period. Mentors asked if contributors faced any issues while installing the project and encouraged us to make small contributions. We also decided on the time for project-specific weekly meetings.
71+
72+
## During community bonding week 3
73+
74+
*(May 23,2024- May 29,2024)*
75+
76+
### Activities
77+
78+
* I helped few of my colleagues in setting up their development environments.
79+
80+
### Work done
81+
82+
* I continued working on upgrading the REST APIs to version 2.
83+
84+
* I upgraded the Search, Copyright & Admin APIs to Version 2.
85+
- [feat(api): Upgrade Search, Copyright & Admin APIs to Version 2 ](https://github.com/fossology/fossology/pull/2744)
86+
87+
## Meeting 4
88+
89+
*(May 30,2024)*
90+
91+
We discussed the progress made during the third week of the community bonding period. Mentors gave general updates followed by weekly updates by contributors. We had a session on how are we supposed to present and maintain our work during the coding period through the documentation.
92+
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
---
2+
title: Week 1
3+
author: Divij Sharma
4+
tags: [gsoc24, rest]
5+
---
6+
7+
<!--
8+
SPDX-License-Identifier: CC-BY-SA-4.0
9+
10+
SPDX-FileCopyrightText: 2024 Divij Sharma <divijs75@gmail.com>
11+
-->
12+
13+
# Week 1 meeting and activities
14+
15+
_(May 30,2024)_
16+
17+
## Attendees:
18+
19+
- [Divij Sharma](https://github.com/dvjsharma)
20+
- [Gaurav Mishra](https://github.com/GMishx)
21+
- [Samuel Dushimimana](https://github.com/dushimsam)
22+
- [Shaheem Azmal M MD](https://github.com/shaheemazmalmmd)
23+
- [Soham Banerjee](https://github.com/soham4abc)
24+
- [Valens Niyonsenga](https://github.com/valens200)
25+
26+
## Discussion:
27+
28+
- **Who should be doing what?**
29+
30+
- Discussed project responsibilities with my colleague [Valens](https://github.com/valens200) and mentors.
31+
- We decided that currently I will focus on the REST API Version 2 upgrade and OAuth 2.0 implementation, while Valens would work on adding test cases for the current REST API implementation.
32+
33+
- **REST API Version 2 updates**
34+
35+
- I mentioned that the work on the REST API Version 2 upgrade is almost complete and suggested we can start looking for any further improvements.
36+
- Mentors suggested I should review the code and look for any possible improvements based on my proposed guidelines. [(REST API Guidelines)](../../API-guidelines.md).
37+
38+
- **OAuth 2.0 architecture discussion and needs**
39+
- [Gaurav](https://github.com/GMishx) explained the various modes of authentication we aim to have in the FOSSology project. These are:
40+
- Token based authentication
41+
- Authorization Code Grant (Web Application)
42+
- Client Credentials Grant (Machine to Machine)
43+
- I cleared my doubts regarding the OAuth 2.0 implementation and its significance in the project. I also got a rough vision of what needs to be implemented and what is already implemented. [(Reference Material)](https://github.com/fossology/fossology/wiki/OpenID-Connect-authentication-configuration)
44+
45+
## Activities:
46+
47+
- Tested the REST API Version 2 on a local instance and noted down the improvements that can be made.
48+
- Researched on OAuth 2.0 and how it can be implemented in the project.
49+
- Did minor improvements in the following PR:
50+
- [feat(api): Upgrade User & Group APIs to Version 2 ](https://github.com/fossology/fossology/pull/2711)
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
title: Week 2
3+
author: Divij Sharma
4+
tags: [gsoc24, rest]
5+
---
6+
<!--
7+
SPDX-License-Identifier: CC-BY-SA-4.0
8+
9+
SPDX-FileCopyrightText: 2024 Divij Sharma <divijs75@gmail.com>
10+
-->
11+
12+
# Week 2 meeting and activities
13+
14+
*(June 6,2024)*
15+
16+
## Attendees:
17+
18+
- [Divij Sharma](https://github.com/dvjsharma)
19+
- [Shaheem Azmal M MD](https://github.com/shaheemazmalmmd)
20+
- [Valens Niyonsenga](https://github.com/valens200)
21+
22+
## Discussion:
23+
24+
- No major updates since the last meeting.
25+
- Discussed the improvements that can be made in the REST API Version 2.
26+
- Discussed the implementation of OAuth 2.0 in the project.
27+
28+
## Activities:
29+
30+
- **OAuth 2.0**
31+
- Researched OAuth 2.0 and its application on production servers. Found the [Auth0 article](https://auth0.com/intro-to-iam/what-is-oauth-2) particularly helpful. Studied various architectural patterns for different flows to determine the best fit for our project.
32+
- Prepared a draft outlining the implementation details, focusing on two scenarios:
33+
34+
- **For the API**:
35+
- Create an endpoint to add new clients, accepting `name`, `clientId`, and `scope`.
36+
- Another endpoint to configure FOSSology, accepting `appName`, `clientId`, `clientSecret`, `clientClaim`, `redirectUri`, and `discoveryUri`. The `discoveryUri` will be used to fetch other required endpoints.
37+
- Once these steps are completed, FOSSology will be configured to use OAuth 2.0. Users can obtain a token from their authorization server to access the FOSSology API.
38+
39+
- **For the Web Application**:
40+
- Implement the Authorization Code Grant flow for the frontend. This requires a login page where users can log in and receive a code, which can be exchanged for a token to access the FOSSology API.
41+
- Researched libraries to implement this flow on the frontend.
42+
- On the server side, implement a mechanism to verify user credentials received from the server and issue a token to the user.
43+
44+
- **REST API Version 2**
45+
- Reviewed the code and identified areas for improvement.
46+
- Found the following things which we can look into:
47+
- Status Codes: Particularly 204 (no content)
48+
- Adding pagination to all necessary endpoints
49+
- Using model classes for all major/minor responses
50+
- Test coverage
51+
- Authentication workflow
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"label": "Divij Sharma",
3+
"position": 2
4+
}
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
---
2+
title: Community bonding
3+
author: Valens Niyonsenga
4+
---
5+
6+
<!--
7+
SPDX-License-Identifier: CC-BY-SA-4.0
8+
9+
SPDX-FileCopyright Text: 2024 Valens Niyonsenga <valensniyonsenga2003@gmail.com@gmail.com>
10+
-->
11+
12+
# Community Bonding
13+
14+
## Introduction meeting
15+
16+
_(May 7,2024)_
17+
18+
We had the introductory meeting opening the community bonding for GSoC'24. All members, including mentors and contributors, introduced themselves and discussed more about the general meeting time and platform decision.
19+
20+
## Meeting 1
21+
22+
_(May 9,2024)_
23+
24+
After introductory meetinThis was our initial general meeting following the introductory session. The mentors emphasized the significance of maintaining communication and providing updates. Contributors were encouraged to ask any questions they had.
25+
26+
## During community bonding week 1
27+
28+
_(May 12,2024- May 18,2024)_
29+
30+
### Activities
31+
32+
- Discussed with mentors more about the project and the tasks that need to be completed.
33+
- Got in touch with fellow contributors, sharing ideas on how we were going to approach our respective projects.
34+
35+
### Work done
36+
37+
- I set up the project's development environment.
38+
- Cleared some doubts and asked questions to understand the project better..
39+
40+
## Meeting 2
41+
42+
_(May 30,2024)_
43+
44+
- Mentors asked for any updates from contributors.
45+
- Mentors asked to update the documentation tool before joining the next call.
46+
- Mentors explained about the GSoC tool documentation tool, different rules for the code, and documentation.
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
---
2+
title: Week 1
3+
author: Valens Niyonsenga
4+
tags: [gsoc24, rest]
5+
---
6+
7+
<!--
8+
SPDX-License-Identifier: CC-BY-SA-4.0
9+
10+
SPDX-FileCopyrightText: 2024 Valens Niyonsenga <valensniyonsenga2003@gmail.com>
11+
-->
12+
13+
# Week 1 meeting and activities
14+
15+
_(May 30,2024)_
16+
17+
## Attendees:
18+
19+
- [Valens Niyonsenga](https://github.com/valens200)
20+
- [Gaurav Mishra](https://github.com/GMishx)
21+
- [Samuel Dushimimana](https://github.com/dushimsam)
22+
- [Shaheem Azmal M MD](https://github.com/shaheemazmalmmd)
23+
- [Soham Banerjee](https://github.com/soham4abc)
24+
- [Divij Sharma](https://github.com/dvjsharma)
25+
26+
## Discussion:
27+
28+
- **Who should be doing what?**
29+
30+
- I had discussion with mentors and my colleague [Divij Sharma](https://github.com/dvjsharma).
31+
- Divided responsibilities with my colleague [Divij Sharma](https://github.com/dvjsharma).
32+
- We took a decision that I will be focusing on adding test cases for the current REST API implementation while Sharma would focus on REST API version 2 upgrade and OAuth 2.0 implementation.

0 commit comments

Comments
 (0)