Skip to main content

Questions tagged [repository]

A repository provides a storage mechanism for digital products. May refer to [version-control] like [git] or [svn]. An application specific tag should be used with this tag in order to identify the specific repository management interface that is being used unless the question is general in nature. See also: [repository-pattern]

Filter by
Sorted by
Tagged with
0 votes
1 answer
249 views

Is IRepository allowed to know about database entities?

I am trying to apply Robert Martin's Clean Architecture on my .NET project. In one of chapters about boundary, it talks about that database interface should reside in business logic component rather ...
Afshar's user avatar
  • 223
0 votes
2 answers
151 views

Is it a good idea to have a fork of a library's public repo in my solution?

My company's project uses an open source library, of which I have made a fork for some customizations. My idea is to clone this fork into my solution and to keep pushing my changes into it, as well as ...
Frank Z.'s user avatar
1 vote
1 answer
280 views

Git Branching and Merging Strategy for Feature-Oriented Release Process

We have multiple developers contributing to a project, using Git as our repository. We have a QA branch that matches our QA environment and a master branch that matches production. Features can be in ...
Lisa S's user avatar
  • 21
1 vote
2 answers
148 views

Specific get cases - Repository vs Service

I have a custom repository for each entity/module (I'm working with NestJS). I know that this is a lot of repeated code and I may refactor it in order to use a generic repository later, but currently ...
Thiago Dias's user avatar
0 votes
2 answers
199 views

How should we set up our git structure?

this is a robotics team with some questions. Here's our current setup, using GitLab: Currently, we have a main branch as well as a separate branch for each of our programmers. When they want to start ...
1082 X's user avatar
  • 11
0 votes
1 answer
77 views

Communicating unpredicted Failure from Repository implementation to Applicaiton Layer

My application follows Clean Architecture wherein the Application Layer wraps the Domain Layer. I try to adhere to DDD more-so as a "guiding light" than a strict rulebook. Within the Domain ...
John Hall's user avatar
  • 163
3 votes
3 answers
1k views

How to implement Repository if only part of Entity properties are needed?

From many articles and answers on DDD Repository pattern, I got the feeling that a Repository should only CURD an Entity (Aggregate Root) as a whole. Following this convention, we always need to query ...
zwcloud's user avatar
  • 131
-1 votes
1 answer
428 views

Right using monorepo for ts-node scripts

I have a repository with various tools/scripts written with ts-node and used in many projects. Initially, it contained several automation/analytics scripts, one package.json file at the root, and one ...
Dem0n13's user avatar
  • 99
3 votes
1 answer
187 views

Composite repositories: minimizing dependency injections

I have an application with dependency injection that consumes a REST API. The API calls are abstracted into entity-specific repositories. Some of the repositories are: HttpNotebookRepository, ...
Amal K's user avatar
  • 101
1 vote
4 answers
315 views

Storing both a compiled service for a Docker container as well as the container in a repository. Good practice, bad practice or no precedent?

This has erupted from quite a turbulent meeting between two senior developers, a lead developer and an engineering lead, and after 90mins reached no resolution. We create Spring Boot Java services ...
Crazy Dino's user avatar
3 votes
2 answers
1k views

Is it good design to have a repository update multiple entities?

I'm building a web application using Laravel. I use the repository pattern as my data layer. Imagine there's some entity like Product and a product can be assigned to a ProductCategory. The Product ...
user2190492's user avatar
1 vote
3 answers
361 views

Is there any value for a repository to return an iterator rather than a list?

I see a pattern where the get method from a repository returns an Iterable, even if the list is composed already: def get() -> Iterable[type]: my_list = [list] for x in my_list: yield x I'...
Claudiu Creanga's user avatar
-1 votes
1 answer
1k views

Best practice for git repo locations

I started my first job as a dev about 3 months ago, at a very small company where I'm (currently) the only developer, and I've been setting them up with git. Their codebase is a bit all over the place,...
confused_nomad's user avatar
3 votes
1 answer
447 views

Should repositories return self persisting entities?

In domain driven design A repository is a collection like "interface" that hides data source access. It furnish add, remove and retrieval method just like a collection would. It does it ...
Ced's user avatar
  • 589
4 votes
3 answers
973 views

Are repositories async?

Repositories in ddd should give the illusion of an in memory collection. and A Repository is essentially a facade for persistence that uses Collection style semantics (Add, Update, Remove) to supply ...
Ced's user avatar
  • 589
-4 votes
2 answers
566 views

How can I use data from another remote repository without including it in my repository?

I currently have a CI workflow for tests that use data present in my repository. However, since this data is very large, I would like to move it to another remote repo and somehow give my CI tests ...
Aditya Tomar's user avatar
3 votes
1 answer
513 views

Releasing a project for multiple languages and package managers

My friend is building a small open-source project with a few convenience functions. He'd like to release both JS, PHP and Python versions of the package to npm, packagist and pypi. The main part of ...
Anna's user avatar
  • 157
0 votes
0 answers
238 views

Implementing the Repository/UnitOfWork pattern using Azure.Data.Tables "TableClient"

I currently have a generic Azure repository AzureRepository<TEntity> store internally a list of table transaction actions like so. private readonly IList<TableTransactionAction> ...
Reap's user avatar
  • 183
1 vote
3 answers
835 views

Repository w/ MVVM Pattern: Data Format Check, Where/When, Best Practice?

TL; DR Where/When to check data format in MVVM + Repository Pattern is the best practice? Any suggestion or theory? The Scene Our team is working on an Android Project. We have a MVVM+repo structure: ...
Samuel T. Chou's user avatar
0 votes
6 answers
270 views

Is it necessary to understand the requirements of a change in order to perform an effective code review?

Can an effective code review be performed without first understanding the intent behind the code?
dangerousdave's user avatar
6 votes
3 answers
1k views

Mixing server and client code in monorepo

To date, we have implemented a multi-repo approach in which each project, or for larger projects, each tier, has its own repo. Code is written in Typescript, Javascript, C#, PowerShell and T-SQL. ...
TimTheEnchanter's user avatar
3 votes
1 answer
590 views

Setting up tests and a continuous integration pipeline in a polyrepo environment

In the past I've mainly worked with monorepos, specifically a Vue.js app that was served by a rails backend. Setting up E2E/integration tests in the CI was simple, because all the required parts were ...
Johannes Stricker's user avatar
0 votes
1 answer
3k views

How to organize multiple microservices in a GitHub repository?

I am setting up a Github repository for a project that will have multiple Microservices. I have created a sub-directory for each microservice under One Repository. ProjectRepository \Services ...
Jasper2000's user avatar
0 votes
0 answers
137 views

How much should we archive for reproducible builds?

A few alternative twists on the question title to contextualize further: What to archive of the "sources" for a given software build? Should I include all transitive packages in my ...
Martin Ba's user avatar
  • 7,627
2 votes
2 answers
2k views

DDD - How to decouple two often used together aggregate roots

Context I'm currently developing a notification system with DDD which needs to be able to send the same notification to multiple users. For example, a group of party goers might all be notified about ...
Luis Pinto's user avatar
0 votes
3 answers
528 views

Are Git repository and software repository same things?

What I've read A Git repository is the . git/ folder inside a project. This repository tracks all changes made to files in your project, building a history over time. (Source) Repository: A collection ...
johnn5's user avatar
  • 27
2 votes
2 answers
8k views

Error handling for repository: exceptions or wrapping return value?

The question is about a desktop application I'm creating in C# and WPF. As very common I'm using the repository pattern in my Data Access Layer for my CRUD operations. All data comes from the ...
user2190492's user avatar
9 votes
2 answers
11k views

Should appsettings.Development.json be added to the repository?

Lately I got in a discussion with my colleague whether the appsettings.Development.json should be added to the git repository or not. My considerations are: when a developer clones a repository to his ...
Frits's user avatar
  • 410
-3 votes
1 answer
1k views

How to filter and add paging, if we must not expose IQueryable at Repository pattern?

In many discussion I learnt that was undesirable (forbidden) to expose IQueryable from Respository pattern. What is the best practice then for server-side filtering and paging?
Estevez's user avatar
  • 103
-4 votes
1 answer
49 views

Controlling and managing separate git repos on Azure DevOps for code security

My company is about to onboard some junior devs for the first time, and we want to limit their access to just the presentation layer. As it stands, everything is in one Git repo. The current plan is ...
Liaoo's user avatar
  • 95
2 votes
1 answer
165 views

How to model an action that involves more than one model?

I'd like to start by saying that I'm new to DDD and I'm creating a hobby system to practice some concepts, so this question might be trivial, but not so much for me. I have the following scenario: I ...
Vinicius's user avatar
3 votes
1 answer
7k views

Repository Pattern with Services Layer - Good Practice?

This is my first time I am using repository pattern and applying a layered architecture in a project. I have followed the article found here. The complete code found on the article can also be found ...
Subliminal Hash's user avatar
1 vote
1 answer
2k views

DDD Aggregate in PHP — how to retrieve the root?

Status quo I created an aggregate, let's call it Foo. It has two entities within itself, let's call them Foo & Bar. You can mutate things by calling the aggregate's public methods. E.g. $foo->...
nkamm's user avatar
  • 69
3 votes
5 answers
678 views

Should the Model be able to persist itself? When?

I might start by saying that I am aware that usually there's a Repository layer bookRepository.persist(book) that abstracts the interaction with the database, but something about using the model ...
Carlos Coelho's user avatar
-2 votes
2 answers
111 views

Software Architecture: Repository Data grabs all the Data

We have the current software pattern below. Sql Server Db --> Repository --> Domain Layer---> Dto Layer The Dto layer filters sensitive data, and brings only required domain data to client ...
user avatar
-3 votes
1 answer
716 views

how to manage build and deployments from Multi repos using versions

Consider you have two repos A, B. Let say repo A has some infrastructure code - not needed to be updated always- but it has the code for the service we want to deploy as infra. On the other hand, ...
Mulder's user avatar
  • 17
-2 votes
6 answers
206 views

Why don't packages formally specify (and repositories verify) their contracts

So, most software depends upon third-party libraries, to some extent or another. Specifications of such libraries' behaviour usually takes the form of human-readable documentation. We write ...
user365547's user avatar
1 vote
0 answers
47 views

Optimal package structure - Command Line Interface

I have an ongoing project where the directory structure currently is a mess (github Directory) and I would like to strucure it to eventully create a python package out of it. Below I have outlined a ...
MisterButter's user avatar
-3 votes
1 answer
165 views

Proper way to organize Small Functions in PHP

I have a bunch of small utility PHP functions that I made to solve different scripting problems. Functions like UUID() and trackUserActivity() etc. There are tons of these functions and increasing ...
Abdul Jabbar's user avatar
7 votes
3 answers
5k views

Domain Driven Design - Updating and persisting aggregates

I'm trying to wrap my head around the best possible solution in the following situation: When updating part of an aggregate, could be any part of the aggregate so either the root or any other entity, ...
ExcellentAverage's user avatar
14 votes
5 answers
4k views

What kind of logic can Domain Objects realistically contain?

I have been struggling with this concept in the context of web applications ever since I first read about it. The theory states that the domain objects should encapsulate their behaviour and business ...
Ted Chirvasiu's user avatar
0 votes
1 answer
528 views

where to call repository update/add methods?

I have a domain service and i need to create an aggregate inside it, because the logic for create this aggregate involves another aggregates and calls to repository to check some business rules. Is ...
arthhhdev's user avatar
1 vote
1 answer
602 views

Clean Architecture: are repositories always needed?

I'm trying to apply Clean Architecture to a mobile Android App, but I still have some doubts about how to manage API calls. Currently, the classes are structured like this: View -> ViewModel -> ...
Rod's user avatar
  • 148
2 votes
0 answers
301 views

Changing entities in Clean Architecture

I'm modeling the "Domain" Layer of "Clean Architecture" for an application that gets its data from an XML file when starts. The XML file looks like: <?xml version="1.0" encoding="UTF-8" ?> <...
trofinao's user avatar
2 votes
4 answers
406 views

How to ensure that developers see only the project modules they are working on?

This is my first time PM experience. I have created a developer team and we want to work on an Angular-NodeJS project. I have defined some tasks and divided the project into the different modules/...
user3486308's user avatar
2 votes
3 answers
260 views

How to keep everyone on team in sync with repo?

This is probably a very basic question, but I have never worked on a team before and I'm not sure if there is an obvious answer or if I'm too bad at googling. Regardless, I can't find a clear answer ...
Lobs001's user avatar
  • 137
2 votes
1 answer
212 views

Correct approach to DDD?

I'm wondering if I'm using the correct architecture in my application. After calling an endpoint in my API, I'm currently going through the following flow: Api.EmployeeController.Update(Api....
bimaw24064's user avatar
3 votes
1 answer
468 views

Should I use Repositories or wrap that logic in an additional service layer in my Controllers

I am building a Loopback4 app just for learning; I have a scenario where I have to check for a couple of things before sending that request to the database, so my entry point is my Controllers Method, ...
hazimdikenli's user avatar
11 votes
2 answers
512 views

Is it bad to have many contributors in a code repository?

Is it a bad thing to have a large number of contributors in a code repository? My current company has a really large repo. This repo has over 40 contributors. And there's a debate about whether or ...
Allen Zhang's user avatar
1 vote
1 answer
600 views

Git strategy for separate teams in one project without access to eachother source

We have one project and separate teams which work on separate modules. What we need is a strategy that allows our teams to work on one project but without access to each other source codes. one ...
Hamid's user avatar
  • 119

1
2 3 4 5 6