Questions tagged [architecture]

0

votes
0

answer
3

Views

Using Post for Each API Call , even for get Resource.?

HY i was working with backend Architecture using http methods like standards get for getting resource, post for adding some resorce put for update and delete for deleting resource. but someone insisted me to change all methods to post, with this logic that this is not secure way to call get , de...
Ghazanfar Ali
0

votes
0

answer
3

Views

Documents and books about designing system update and software update

As a software engineer, I am working on a project to design a system update. The system is like an operating system eg, windows, ios. I am looking for documents and books talking about how to design a software update or operating system update, design pattern, best practice or principles we should f...
icedoing
1

votes
3

answer
163

Views

DDD solution structure

I'm trying to create a nice a Solution structure for a new DDD project. I Created a "Core" project, where I added the Entities, ValueObjects and the repositories Interfaces then I added an "Infrastructure" project that contains the implementation of the previous IRepository. Now, since my db will be...
Davide Quaglio
1

votes
2

answer
97

Views

Clean Architecture: How to reduce complexity when writing application business rules?

Let's assume we have the following "Create User" scenario: Users can signup to the application using Facebook, Google+ or LinkedIn; The backend should retrieve some basic profile information in order to register the user(email, firstName and lastName); Users are registered with a "client Id" (Just a...
Tom Melo
1

votes
1

answer
29

Views

How to add Navigation Architecture while using tabs

I have an application that implements a Bottom Navigation Layout. It contains 4 tabs. The first tab is the NavHost. This tab has an inner View Pager that contains 2 tabs (fragments). However how can I connect the inner View Pager on the Navigation Graph? Below is the image of the application itself:...
Andrea
-1

votes
0

answer
6

Views

Single responsibility and methods

I think I might answer my own question here but lets say I understand the SRP on the method level to mean that a method serves one role. If I have methods that each individually cover one specific role in my class, but a method that uses lots of those methods to accomplish one role like a save() wou...
Anden
1

votes
0

answer
5

Views

How do data caches route the object in this example?

Consider the diagrammed data cache architecture. (ASCII art follows.) -------------------------------------- | CPU core A | CPU core B | | |------------|------------| Devices | | Cache A2 | Cache B2 | with DMA | |-------------------------| | | Cache 1 |...
thb
0

votes
0

answer
3

Views

Multiple applications on web server is consider Microservice or SOA

I'm preparing for an interview which will contain architectural questions. While I was studying, I was thinking about my past experiences. In my previous job, we put most of our applications (about 8~10) on a single tomcat instances, since we didn't have to worry about scaling. All applications wer...
Gabriella E.
0

votes
0

answer
2

Views

Schema changing DB - which method is better?

I am planning to develop a website which users can customize many items on, so considering three plans. Could you tell me which method is more common? Let's assume we will make a web app for handling all processes of producing toothbrushes. { "toothbrush set": { "toothbrush": { "head": ["dyeing", "a...
Kang Andrew
1

votes
2

answer
2.1k

Views

aws + serverless + webpack => cannot find module xxx in prod

I want to create a package to deploy on AWS using serverless and webpack. In serverless.yml I want to declare all the resources (mainly DynamoDb tables) and the functions. I want to use external node.js libraries. The folder structure is: |- serverless.yml |- webpack.config.js |- package.json |- src...
Costin
1

votes
1

answer
1.2k

Views

Room; Store integer array to a separate table?

Using Room ORM, I have declared an entity EQPreset using @Entity annotation. The entity contains an array int[]. It gives following error: error: Cannot figure out how to save this field (int[] arr) into database. You can consider adding a type converter for it. Normally saving EQPreset instance to...
Shoaib Anwar
1

votes
1

answer
204

Views

Dependency from Gateway to Framework in Clean Architecture

Let's imagine I would want to implement an ASP.NET application based on Uncle Bobs Clean Architecture. As far as I understood it: Asp.Net itself would be in the framework circle An Asp.Net controller would be in the gateways/interface adapters layer my business logic would be in the usecases/entitie...
plainionist
1

votes
2

answer
1.5k

Views

Repository to return LiveData when Room doesn't have it and instead fetches from REST API

I am looking for recommendation in handling below use case w.r.t. LiveData handling: ViewModel invokes Repository for LiveData (e.g. products catalog). Repository checks from LocalDataSource(Room) first but if data not available, invokes RemoteDataSource(REST API). Questions: 1) As per below commen...
birender
1

votes
1

answer
362

Views

Service layer pagination, paged results (where to put logic?)

I want to implement paging in my Web API, but from what I saw most paged results contain URLs or links to self, next, previous, last, first. I'm not sure where to put paging logic, as the service layer can't generate URLs. And I don't want to couple my service layer with ASP NET Core. How can I acc...
Konrad
1

votes
2

answer
241

Views

Can we make android.app.Service as lifecycle aware compenent

all I get from the new Android Architecture Components is, if we make the component lifecycle aware then depending on the activity lifecycle the LifecycleObserver will react to the events. That reduces a lot of boilerplate code that we write in onCreate,onStop or onStart etc. activity or fragment li...
bash
1

votes
2

answer
2k

Views

Android Repository pattern

I have couple of questions about Repository pattern: If I'm using only offline database for example Room with LiveData is there any use of Repository pattern? If my app is offline right now, but will be connected to remote db in the future should I implement repository pattern or it's not going to b...
kosas
0

votes
0

answer
5

Views

ANdroid WorkManager doesn't trigger one of the two scheduled workers

I have two periodic workers scheduled in my app where one worker repeats after 24 hours and another in 15 minutes. Initially on fresh install things work as expected, but after some days I got an issue on 2 devices(out of 5). The 24 hour worker is triggered properly but the 15 minute one isn't trig...
Prasad Pawar
1

votes
2

answer
202

Views

Method must be called from main thread,currenty inferred thread is worker

I am trying to change the wallpaper of Android every 15 minutes or something like this. A user can choose the time and I am running a periodic work using Workmanager. PeriodicWorkRequest periodicWorkRequest = new PeriodicWorkRequest.Builder(SomeWorker.class, 15, TimeUnit.MINUTES).build(); WorkManag...
This Guy Codes
1

votes
2

answer
244

Views

Testing LiveData using PowerMockRunner

My local unit tests use LiveData all the time. Normally, when you try to set a value on MutableLiveData you get java.lang.RuntimeException: Method getMainLooper in android.os.Looper not mocked. because local JVM has no access to Android framework. I fixed that using that: @get:Rule val rule = Instan...
Michał Powłoka
1

votes
2

answer
198

Views

Navigation Arch Component: Passing placeholder param for deeplink

I am trying to implement a deeplink functionality using the new Navigation Component API v1.0.0-alpha05 but running into an issue. Using Android Studio 3.3 Canary 7 Portion of my navigation_graph.xml AndroidManifest.xml contains: I am testing my deeplink with adb shell am start -a android.intent.act...
liminal
1

votes
2

answer
303

Views

DDD Ports and Adapters with Onion architecture, what goes where?

trying to figure out some concepts and haven't been able to understand What is a use-case in the Ports and Adapters architecture ? What an implementation of a use-case would look like ? What is a use-case concern ? Where does it fit in the Infrastructure or Domain, it says it goes in the Applicat...
MCR
0

votes
0

answer
5

Views

Periodically get updated OkHttp response using Android Architecture: LiveData and update Map markers

I have made a transport application that shows bus locations. I am currently trying to refactor my code so that I can smoothly animate markers (bus locations) and have seen that LiveData could be useful for cleaning up my code. I am using OkHttp to make my requests, a repository to return a mutableL...
atmalone
1

votes
1

answer
1.3k

Views

When is data stored to register on load instruction in MIPS Pipeline

I understand that in a MIPS Pipeline, for a load instruction, data is read from cache at the 4th stage of instruction, which is the memory access stage. In case of other instructions (apart from load/store), the stage is responsible for writing data in result register to write back register and then...
Amrith Krishna
0

votes
0

answer
2

Views

Published and waiting for response on a topic with RabbitMQ / EasyNetQ - how to get only yours?

When a publisher expects an answer to a message, how to ensure it will get only relevant answers (to its own messages) when you scale it out? We have a client process that publishes a message for a server process to answer. Additionally, we have a "listener" process that just needs to consume both t...
PeterLi
1

votes
1

answer
1.7k

Views

What's the best architecture for a medium-sized, high traffic web site? [closed]

I'm starting a new project (non-corporative) and I want to know how would be a great architecture nowadays. What I'm planning for now is to use: ASP.NET MVC 4.0 SQL Server 2008 or 2012 EF 5.0 under .NET 4.5, with Dapper Implementation of Repository pattern (this one http://code.google.com/p/ef4prs/...
eduardobr
1

votes
1

answer
459

Views

User interface depending on business logic layer breaks dependency inversion principle? [closed]

Dependency Inversion Principle states: High-level modules should not depend on low-level modules. With that in mind, my old: UI -> Business Logic Layer -> Data Access Layer became UI -> Business Logic Layer
Rodrigo Lira
1

votes
2

answer
315

Views

Rails3 Admin UI frameworks

We will soon be rewriting a 5 year old rails app, with a very unsound code foundation, from scratch in a brand new Rails 3 app with all the new hotness. The current app has a substantial custom admin UI backend which depends on now admin frameworks at all. Just some base controller classes and some...
Alex Wayne
1

votes
3

answer
121

Views

Demo and live systems - code versioning strategy

Our company has a client/server product which we want to give the client out to customers to try out, against a test server with dummy data where all users default to a single dummy account. To summarize the product, in a real world situation the server would be deployed on the customer's hosting en...
Dale
1

votes
2

answer
733

Views

MVC / Repository Pattern - Architecture

I have a project in which I am using NHibernate and ASP.Net MVC. The application is intended to allow users to track certain data and then produce views of statistics based upon the data entered. The structure of my application thus far looks something like this: NHibernate Layer: Contains Repositor...
Ant P
1

votes
3

answer
4k

Views

What is the difference between “initial scope” and “requirements”?

Thanks for taking the time to read this in advance. I am writing an intermediate submission report for a project that I am re-engineering and my tutor wants a page summary, list of requirements (with justifications), an initial scope and a suggested architecture. The main report will include analysi...
wilcode
1

votes
1

answer
283

Views

GPU architecture customization? [closed]

I'm doing a project concerning some CUDA acceleration on GPU and finished some software level optimization my calculations, and also I've found out that some changes in GPU architecture may help the optimization of the project even further. Now my question, is there an efficient way or existed emula...
Tony
1

votes
1

answer
594

Views

Architecture for stateful MVVM application with self contained client-server code and IoC container

I have an application which has multiple screens and talks to a WCF web service. I am using SimpleInjector for my favourite IoC container, and Caliburn Micro for MMVM with WPF. I have a separate class implementation of ITransportClient that controls the connection to the web service and sends and re...
g18c
1

votes
2

answer
770

Views

Database structure for a system with multisite - Database & PHP

The system I'm working is structured as below. Given that I'm planning to use Joomla as the base. a(www.a.com),b(www.b.com),c(www.c.com) are search portals which allows user to to search for reservation. x(www.x.com),y(www.y.com),z(www.z.com) are hotels where booking are made by users. www.a.com's...
Techie
1

votes
3

answer
461

Views

validate each incoming request

I have two base classes RequestBase and ResponseBase, for request and response respectively. All types of requsets and response derived from these classes. The RequestBase contains ClientKey and AccessToken fields. Also, I have the AuthenticationService service. [ServiceContract] public interface I...
user1260827
1

votes
1

answer
1.1k

Views

Output of Environment.GetEnvironmentVariable(“PROCESSOR_ARCHITECTURE”) and OperatingSystem.Platform on Windows RT

I'm writing a cross-platform application and I really need some basic info about the system. Not just for switching it (I could use compile variables, since I have the same code linked in platform-specific projects). So don't tell me that knowing the platform and architecture info is useless: Window...
Salaros
1

votes
1

answer
203

Views

How to manage the source code that runs on different customer's systems?

We have an application which is implemented for our own company. By time, the application has been purchased by various companies. For each company, we created a new TFS Branch in source control. And each one has been changed for specific customer requirements. That's why the source code has many ve...
Ahmet Altun
1

votes
3

answer
67

Views

Should classes be grouped by functionality type or by model?

I know the title probably isn't too clear because I probably don't have the right terminology, but an example should make it clear. Suppose I have an app with posts and comments, what would be the best practice as far as grouping those into namespaces/packages of the various ways. If there's no bett...
Rocket04
1

votes
1

answer
262

Views

Which fields does immediate take in mips architecture?

If we compare R-type and I-type instructions of MIPS. Then if we look at it and tell that in I-type instructions which fields of R-type and converted to immediate then which fields will they be? The fields in R-type which are used to store immediate in I-type are rd, shamt and function. So should we...
Rana Tallal
1

votes
2

answer
1k

Views

Entity Framework code first in data access layer

I am using N-layer architecure in my project. In the data access layer I use Entity Framework code first. When I fill an object in the DAL, dispose the context and transfer the object to the business layer, the navigation properties become null. I have no problem if I don't dispose the context, but...
Mohsen

View additional questions