ServiceInterfaces
Jump to navigation
Jump to search
What Makes A Good Service Interface?
- Follow REST in terms of Create/Read/Update/Delete separation
- POST: Create
- GET: Retrieve
- PUT: Update/change
- DELETE: Delete/remove
- Need to think hard about how data will evolve
- Identify abstractions that will shift (trade data) and decide how you'll deal with that
- In general, data format ownership should be federated - placed with the relevant expert teams
- URL structure is worth very careful thought
- For return data
- Give a choice of XML or JSON
- Preserve full exception information - ensure the format supports this
- Design guidelines
- Be consistent - if a concept appears more than once, ensure it's expressed the same way in each place
- Be stateless (this is simpler and more scalable)
- Don't make the operations too granular - remember call overhead
- Be testable - if you can't validate, you can't evolve or change the system