adoptium / adoptium.net

Adoptium Website
https://adoptium.net
Apache License 2.0
21 stars 118 forks source link

Update /members page to use Eclipse membership API plugin #1350

Open autumnfound opened 1 year ago

autumnfound commented 1 year ago

To better enable ease of use of the site and reduce the need for manual updates, the Eclipse Foundation webdev team introduced a JS plugin that will fetch members of a working group on page load. This system uses data from our membership applications to provide accurate members lists.

Embedded in the solstice-assets project, this functionality can be enabled by linking the source JS and adding a div with class eclipsefdn-members-list. A filter for the working-group can be applied by using an attribute of data-ml-wg on the before mentioned div with a value of adoptium for this working group.

Examples of places where this is used is on IoT and ECD Tools working group sites.

gdams commented 1 year ago

hey @autumnfound, I’m a little conflicted about using this API, for starters the logos that are served by it are often png or jpg and do not have a transparent background. It also offers us far less control over that page. Is there a rest endpoint we can use to query the members list? I'd feel a little more comfortable about using this approach and handling the templating on our side.

autumnfound commented 1 year ago

the logos that are served by it are often png or jpg and do not have a transparent background.

That is unfortunately more of a side effect of what the organizations typically provide us. The images being used in the plugin are the same that would be provided by the raw API and are often not provided with transparency.

Is there a rest endpoint we can use to query the members list? I'd feel a little more comfortable about using this approach and handling the templating on our side.

Yep, there are 2 options for you depending on how much data you need/want to display.

  1. https://membership.eclipse.org/api/organizations?working_group=adoptium, the standard call that provides all data about organizations, scoped to those with active membership in adoptium. This is what is used by the plugin currently, as it provides data about levels as well as the baseline data for an organization. This is likely the call you should/would use.
  2. https://membership.eclipse.org/api/organizations/slim?working_group=adoptium is a custom slimmed-down version that only provides the name, logo, and Eclipse Foundation member ID. This probably doesn't provide you with enough info as it doesn't include the website for the organization, and is more for linking within our site and providing data for form fields.
xavierfacq commented 1 year ago

I can take a look at this point (using the API) if you want. You can affect me to this issue.

gdams commented 1 year ago

I can take a look at this point (using the API) if you want. You can affect me to this issue.

I'm not convinced this is a direction we want to take right now. I'll have a think and let you know