Questions tagged [design]

Questions about problem solving and planning for a solution through software design.

Filter by
Sorted by
Tagged with
0
votes
0answers
13 views

Using Decorator Pattern For Debugging

So I keep being asked to add new metrics and log certain debug information to my current project. Now, as one would expect, this has start cluttering the code too much. From what I have read and seen ...
-1
votes
1answer
23 views

Frontend development: pattern libraries and different frontend technologies

We are setting up a pattern library. It's use is on the one hand to document and display our UI elements in a web view. On the other hand, it should also be the place where components are built. The ...
-3
votes
0answers
36 views

Architecture of a real-time collaboration application [closed]

I would like to build an application similar to Google Docs that allows for real-time document collaboration and presentation. In Google docs, nearly everything is real-time; from document creation to ...
1
vote
1answer
51 views

async notifications delivery

i have some back end service that is in charge of sending notifications to my end users via mapping between some identifier to their real web sockets. currently the service works in a sync way, ...
1
vote
0answers
70 views

How to design the interface method for the following case?

I am making a Snmp agent. In order to pass information to this Snmp agent I need to periodically extract data from two different sources and there can be more sources in future. I was designing the ...
1
vote
1answer
56 views

Instant Messaging with WebSocket

I am trying to develop an Instant messenger using WebSocket. I have multiple instances of my servers running (say server1 , server2). Two users(say userA , userB) who wants to chat with each other. ...
1
vote
1answer
32 views

Determining the service calls within the API based on the each consumer request

Currently, I have a rest API service which serves to many different consumers. One of the endpoints of API is for retrieving an order. Inside a single application, I am making 5 different service ...
-2
votes
0answers
38 views

Questions about the state of ICR (Intelligent Character Recognition) [closed]

I'm looking for a little advice on a project I am considering. It's in the realm of OCR/ICR and I'm wondering how accurate ICR has gotten? There are obviously commercial solutions within Azure and ...
-2
votes
1answer
56 views

In a tennis scoring program, what would be a good approach for storing and presenting both standard games and tiebreaks?

In a tennis match, each game has the possible scores of Love, 15, 30, 40, or Advantage. This could be modeled as a dictionary [0: "Love", 1: "15", 2: "30", 3: "40", 4: "Advantage"] or enumerated type ...
0
votes
0answers
28 views

What to Use In Abstract Factory Producer to Choose Concrete Factory? [duplicate]

So to create a concrete factory that extends from an abstract factory class, I usually create a 'producer' class to determine what abstract factory to use. For example: public abstract class ...
2
votes
2answers
86 views

DB design while designing the system

Recently we had a discussion if rough DB schema (high level tables and columns) design should be part of system design phase or not. We have two confronting approaches in the company. Let's assume ...
0
votes
1answer
59 views

How to keep components modular/independent in a layered architecture?

Lets say we have a layered architecture where A->B->C are three different layers. Function calls are passed from A to C and data is passed up from C to A. I think in this case A will have a reference ...
1
vote
3answers
229 views

Feature toggle: How to toggle without spreading same toggle all over the code?

Considering a feature needs changes at many places in different modules of the software: UI, business logic, backend, etc. What is a good approach to do so? We are using dependency injection and ...
-3
votes
0answers
19 views

modelling reusable react components with state stored in redux [closed]

I want to model a component in react, who's state is stored in redux, but I want to be able to make multiple instances of that component. The best I can come up with is to encapsulate all the ...
2
votes
0answers
49 views

Global variables and common block management in Fortran

Background The high level overview of my situation is described here. I am breaking it apart into smaller, specific questions, such as this one, regarding extensive use of global variables in a ...
5
votes
5answers
249 views

How to formally figure out the best design based on the informal user's description of their needs?

I am to write a piece of software to a friend of my uncle's, but I don't exactly know all the elements that are needed to fulfil the user's needs, so I can't begin to formulate a design yet. Since the ...
3
votes
1answer
119 views

How to modernize large legacy Fortran program? [duplicate]

Problem Background Recently, I joined a government agency as a software engineer/scientist/analyst. Previously, worked in software industry - gained 3 years of software engineering experience at ...
0
votes
0answers
21 views

What would be the best way to dynamically download an external dependency at runtime? [duplicate]

I have a library that depends on a PDB being present for a file present on the running OS. This PDB is hosted officially on the Microsoft servers, and the version needed will change between OS updates ...
1
vote
1answer
28 views

Deploying a Customer Facing Enterprise App

I have a customer-facing enterprise app. (like AWS). Customers specify config on the app and relevant infrastructure is spun up along with my software on it. My CloudOps team, like the AWSCloudOps ...
-2
votes
0answers
69 views

Seeking advice on technologies for NoSQL application

I have a basic level of C++, beginner familiarity with DB concepts, and dabbled with MySQL. My goal is to create a program that will provide me with a deeper understanding of programming and use of ...
6
votes
4answers
290 views

Exposing implementation details to tests

I have created a class that implements behavior which is difficult to test without some intimate knowledge of internal state. I'd like not to clutter the class's public API with accessors for this ...
-4
votes
1answer
139 views

Where to put the server in my Messaging System UML diagram?

I try to design a client application for a messaging application. The client can send and receive messages, the client can connect/disconnect. My problem is that I don't know how to incorporate the ...
0
votes
2answers
150 views

Alternative to mass Try Catch blocks for my logic

Currently I'm working on creating something with the following general structure. I want to call 4 different APIs in sequential order (the results of one are needed for the next one). If one throws an ...
1
vote
1answer
39 views

Is it a common pattern to put create/update/archive as one process?

Traditionally it's assumed that we should treat create read update delete as separate concepts. However, I have noticed that the following pattern seems more usable for certain contexts [create, ...
0
votes
1answer
69 views

Refactoring and simplify this infrastructure building code [closed]

I have a piece of code (a Facade) that creates every single infrastructure component on aws. private void synthesizeStack() { Deployer<Vpc> vpcDeployer = new VpcDeployer(this); Deployer&...
2
votes
1answer
46 views

What's the prefer way when validate a “set” semantic input JSON array parameter in a blog website, silently ignore it or report an error?

I am developing a blog website, for each post, it has a list of tags, just like stackoverflow. There is no doubt that in the server side, i will expose a api like blog/edit to the client side, and ...
-3
votes
1answer
52 views

Customizing module per client

let's say I have 3 customers A, B and C. I have application (whatever what this application is) I have front-end (let's say in angular2) and back-end (in Spring). On the beggining I have one common ...
-3
votes
1answer
21 views

Angular FormBuilders and Unit Testing Practice

What is the unit testing best practice of testing Angular Forms and Formbuilders? Should I validate the formbuilder testing every member, by patching values onto it, test min/max validators by ...
0
votes
1answer
111 views

Inline HTML elements don't allow setting “width” - why is that?

In HTML/CSS, inline elements, such as <span>, do not support explicitly setting their width via the width CSS property. This is confusing to many developers, as questions like "Setting the ...
1
vote
0answers
34 views

Handle multiple similar structured XMLs in a Java project

We have a case scenario in our project where we are provided with a set of XSDs. These XSDs we converted to Java Pojos with the help of JAXB. After this we were suppose to update few values in the ...
1
vote
2answers
91 views

Basic advice on structuring python project [closed]

I've been using python for several years as a non-developer writing scripts to help business processes. I'm in a new position (still non-developer) and would like to adopt more rigorous coding ...
2
votes
1answer
135 views

Is this SRP violation?

Consider I have a class which represents a tree element. An element can be changed, inspected children elements can be added to it (say trough the add() method). But also I have a class which contains ...
0
votes
0answers
88 views

How to design a fast way to `unarchive` file using python?

Assuming the following scenario: A python application that receives file and process that file trying to understand what the file format( any type of data/compressions/archives/packages/mounts/etc ),...
3
votes
1answer
128 views

Factory/Strategy Pattern for objects that require different pieces of data

I'm facing some difficulty with designing a factory and/or strategy pattern for building out EmailTemplates. IMO this seems like the design pattern to go with, but I feel like the path I'm going down ...
4
votes
4answers
163 views

Would it be possible to abstract multi-threading ability for programs not originaly designed for such?

Would it be feasible to provide (or further) multi-core threading ability for programs that weren't originally designed for such? And doing so by creating a "virtual" CPU core (or for i7's with ...
5
votes
7answers
402 views

Fail-fast design vs. limiting constructor logic

In any programming task, my preference is to write fail-fast code. That doesn't seem to be too controversial. However, I've also seen many developers say that constructors should do as little as ...
3
votes
2answers
222 views

Am I using namespaces wrong?

I'm obsessed with organization - it's probably the real reason why I enjoy coding. So I namespace everything. But I'm just curious if I'm doing it wrong by being redundant. Consider this, which I ...
0
votes
1answer
41 views

Double way parent child relationship in Django

I am building an app to register and update children information, this information is to be provided by their tutors. Every child can have multiple tutors, and a tutor can be a tutor for multiple ...
3
votes
0answers
95 views

Technical architecture of platform on .Net Core

I'm designing a platform that will run robots developed by others. Basically anyone could implement a IAutonomousAgent and register the implementation on the platform. At runtime, the platform will ...
1
vote
1answer
102 views

Independence axiom and ideal design explained

I am studying a book about software design called: Nonfunctional Requirements in Systems Analysis and Design which talks about the Axiomatic Design Methodology. This methodology has two axioms. One ...
-1
votes
1answer
180 views

Is it logical to use dependency injection in .net core library project? [closed]

Earlier, we serve with web service but we decide to use dll methods. Because served products are on same machine with common database. So we start to create a library with .net core. This library will ...
1
vote
3answers
106 views

Multiple functions assuming value or check value in each function

Let's say I have an object A with a public method bool Foo(arg). Foo is potentially a complex algorithm with nested rules (if's). I don't want Foo to have all the code, I want several intermediate ...
0
votes
1answer
84 views

Handling Failed Rollbacks

To give an arbitrary example, let's say that I'm storing two objects, Item and Box, in the same database. These objects have a one-to-one relationship. Item has the following properties: ID (string)...
6
votes
1answer
189 views

Is it practical to pass function pointers to a separate class to avoid additional includes?

In my program I've included the header for an external library (GLFW) in my Main class. Everything I need to use that library for can be handled in my main class, with the exception of two sneaky ...
-3
votes
1answer
84 views

Should vanilla solutions be avoided in Spring web applications?

I am making a Java and Spring webapp that scrapes data from a web and then publishes it through an API. Some of the raw scrapped data is in the form of Set<SomeObject> which I then convert to a ...
4
votes
3answers
72 views

Designing interpretable/maintainable python code that use pandas DataFrames?

I am working with/writing a good amount of code in python using pandas dataframes. One thing I'm really struggling with is how to enforce a "schema" of sorts or make it apparent what data fields are ...
1
vote
1answer
78 views

How to keep user inputs consistent with assumed inputs to slow computations at the backend?

Background: I'm writing a clinical trials simulator. The user defines future trial options, eg a trial with 100 placebo patients, 200 treatment patients, "optimistic" outcome scenario, etc. There can ...
1
vote
1answer
60 views

Sequence diagram: explicitly show websocket creation?

I am trying to draw up a sequence diagram to show how my web client will interact with my backend over a websocket connection. I am using a websocket middleware to manage the stream connections. ...
-1
votes
0answers
68 views

Application Design For Given Scenario

Given the below scenario, how should you architect this application to take advantage of modern standards/technology? You are tasked to build out an application where users can login to view data ...
0
votes
2answers
90 views

How to increase difficulty of intercepting resources downloaded from developer console

I have a web application that allows user view our data that front-end in JavaScript fetches the data via a Restful request to back-end, then render it in the application. The size of each data can ...

1 2 3 4 5 86