Questions tagged [crud]

Create, Read, Update, Delete. Fundamental operations on data stores.

CRUD stands for Create, Read, Update, Delete. These four operations form the foundation of data editing applications.

54 questions
190
votes
6 answers

Difference between REST and CRUD

I learned REST and it feels a lot like CRUD (from what I have read about CRUD). I know they are different, and I wonder if thinking they are similar means I don't understand them. Is it that REST is a "superset" of CRUD? Does it do everything CRUD…
Jesse Black
  • 2,415
  • 3
  • 16
  • 15
31
votes
7 answers

Is it possible for business logic not to creep into the view?

I've developed for several web application projects for the last 3 years, both personal and at work, and I can't seem to figure out whether it's possible for at least some business logic not ending up in the view layer of the application. In most…
vdaras
  • 453
  • 4
  • 8
14
votes
8 answers

Are there examples of non CRUD approaches?

I'm a programmer but also have worked as an archivist. As archivist it's a lot about keeping data. I often get into arguments with colleagues when it comes to operations on data. I don't like the U and the D in CRUD too much. Rather then update a…
Pieter B
  • 12,867
  • 1
  • 40
  • 65
12
votes
3 answers

CRUD API: How do you specify which fields to update?

Let's say you have some kind of data structure, which is persisted in some kind of database. For simplicity, let's call this data structure Person. You are now tasked to design a CRUD API, which allows other applications to create, read, update and…
Heinzi
  • 9,646
  • 3
  • 46
  • 59
10
votes
3 answers

Is discoverability for developers a problem when using SOLID principles?

I do line of business apps where the all the other developers are used to doing basic CRUD apps or are focused solely on making pretty/functional interfaces and I am getting the following a lot. "With the way we use to do it Employee would have all…
ElGringoGrande
  • 2,913
  • 22
  • 20
5
votes
3 answers

When to derive user ID from authentication token vs. validate against?

I am using JSON web tokens, but this authentication token can be any token from which a unique user can be derived. I am designing a REST API that allows CRUD operations on resources owned by specific users in our domain. This ownership is…
Mario Ishac
  • 394
  • 2
  • 12
5
votes
4 answers

How to do BDD for CRUD?

I want to understand how Behavior-Driven Development (BDD) can be applied to building CRUD applications. I have read a lot on the subject but I just don't get how I'm supposed to apply it. I learn best by example, so I built a mini CRUD application…
Gudradain
  • 444
  • 5
  • 12
5
votes
2 answers

GIS-based data visualization and maintenance tool

Background Looking to leverage an existing GIS system for exploring organizational data. Architecture The following figure represents a high-level overview of the system's desired features: The most basic usage would be as follows: The user visits…
Dave Jarvis
  • 743
  • 6
  • 28
4
votes
1 answer

CRUD without an ORM

I am putting together an web app with relatively complex but standard database relationships. I notice that anytime I use an ORM, in python/ruby/php etc, in general, a lot of queries are generated. This is stating the obvious. ORM's typically…
user974407
  • 211
  • 2
  • 6
4
votes
1 answer

Architecture design for Web API with single endpoint

Scenario: I have a situation where I need to refactor a Web service with a single API endpoint that uses complex logic to insert, update and fetch data from a database. The clients use one call, and depending on the data transfer object they send,…
4
votes
3 answers

What are the pros and cons of implementing this requirement in different layers?

I have a CRUD app for s. They are persisted in a database. There is a new requirement: keep track of the s that have been created since the app was opened, so that the user can see what he/she has done. I see three ways…
user39685
3
votes
2 answers

Is this approach to website design adequate or am I making a mistake?

I'm not conversant with this topic, and therefore I watched a tutorial about a one-page dynamic PHP website (quite educational in my opinion) in which the creator designed the following pages. For each and every ADD, DELETE and EDIT page, there are…
3
votes
1 answer

CRUD is too simplistic for my usecases, how would you handle the repository pattern when using MediatR and EF Core?

I have a .Net 5 Web API project and use MediatR to encapsulate my business logic into commands and queries since I don't like to have a single CRUD service handling everything related to a specific resource because my usecases are too complex. For…
Olaf Svenson
  • 197
  • 4
3
votes
0 answers

Designing CRUD Messaging communication

There are endless resources on creating CRUD for REST resources but I can't find much on doing the same for Messaging. Given two services A and B where A receives incoming requests that initiates the creation of the resource R. When A receives the…
span
  • 415
  • 1
  • 4
  • 12
3
votes
1 answer

Authorization server implementation - CRUD vs CQRS

I want to make simple authorization & authentification server (with proper audit logging). I used to see on my job or in many examples classic CRUD approach for this purposes. But now I'm thinking about try to use CQRS (+ ES maybe) approach for my…
1
2 3 4