Uploaded image for project: 'Forge'
  1. Forge
  2. FORGE-838

RestPlugin should support the right semantics for entities with non auto-generated Ids

XMLWordPrintable

    • Icon: Feature Request Feature Request
    • Resolution: Unresolved
    • Icon: Major Major
    • 3.x Future
    • None
    • Java EE
    • None

      Currently, the generated REST resources contain a @POST method for creating new entities and a @PUT method for updating an existing entity.

      This set of semantics is appropriate for auto-generated Ids where the Ids would be created by the server, and cannot be specified by the client.

      However, for JPA entities that do not contain a @GeneratedValue annotation, these semantics may not be unsuitable. It would be preferable to use only a @PUT method that is used to create and update the entities. This is primarily because the client gets to decide the resource/entity identifier, and hence, also the location of the resource.

            Unassigned Unassigned
            vineet.reynolds_jira Vineet Reynolds (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: