Skip to content

[BI-1609] Add configuration to enable/disable PUT/POST /variables endpoints in Breedbase #95

@timparsons

Description

@timparsons

Update BreedBase to allow for the POST /variables and PUT /variables endpoints to be enabled or disabled based on a configuration property.

Jira story: https://breedinginsight.atlassian.net/browse/BI-1609

Techspecs

  1. Update sgn.conf to have two new configurations:
    1. brapi_post_variables with a default value of 0
    2. brapi_put_variables with a default value of 0
  2. In lib/SGN/Controller/AJAX/BrAPI.pm update the POST variables method to check the value of the brapi_post_variables
    1. if true, continue with the rest of the method
    2. if false, return a 404
  3. In lib/SGN/Controller/AJAX/BrAPI.pm update the PUT variables method to check the value of the brapi_put_variables
    1. if true, continue with the rest of the method
    2. if false, return a 404
  4. In lib/SGN/Controller/AJAX/BrAPI.pm update the serverInfo method:
    1. include POST /variables in the response if brapi_post_variables is true
    2. include PUT /variables in the response if brapi_put_variables is true

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions