Fix Spec project working group elections
Now that we are using the Java version of the committer paperwork API, I noticed this morning that Spec projects elections are failing.
This is mostly due to a miscommunication on my part, the API is expecting an int (Term ID. Example: 1234) and the PMI is giving a string (Name of the working group. Example: Jakarta EE). @malowe is going to update the API to be able to recieve a string rather then an int to unblock this issue.
That bneing said, the bigger issue here is that the eclipse_api_committer_paperwork table on API is storing the term ID and the reason why the PMI gives a string is because the term id is different on both websites (accounts and pmi). So then accounts can retrieve the term ID based on the name of store that value. The java API does not have the ability to fetch a term ID since it does not have access to the drupal database.
I think the solution here would be to create a new column to the eclipse_api_committer_paperwork table to store the unique string ID of each working groups. For example, the Jakarta EE working group ID is jakarta-ee
.
This is the same id we store in the following API endpoint: https://api.eclipse.org/working-groups/
The working group ID is retrievable from both the PMI and accounts since this data is stored the the Working Group ID field in each taxonomy terms.
Here are the actions items:
Java
-
Update the endpoint to accept and store a string rather then an int in the eclipse_api_committer_paperwork table
PMI Drupal
-
Replace the WG name for the WG ID in the body of the POST
Accounts Drupal
-
Fetch the WG taxonomy term by WG ID rather then by term ID
API Drupal
-
Create a new column in the eclipse_api_committer_paperwork table to accept the WG ID (string)
/cc @cguindon