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

learn more… | top users | synonyms (1)

2
votes
4answers
555 views

Should every front-end developer understand the basic aspects of design?

I'd say that we're developing software in a world where the front-end of an application is probably the most important. The increasing ability for a user to access and interact with software almost ...
1
vote
1answer
48 views

Polymorphism on repository interface for local and remote operations

I'm in the process of designing a facade ApiClient class that would abstract some CRUD operations between a local database and a remote one (through a REST web app). Said ApiClient class depends on 2 ...
1
vote
1answer
1k views

Erlang chat app design?

I have a chat app made in node/socket.io. Scalability factors have made us choose Erlang/Ejabberd/xmpp and it will replace node/socket. I have a few questions: Currently using MySql for chat ...
2
votes
1answer
67 views

Which approach for coding a 'texture atlas'?

For a game project, I have a couple of textures coming from multiple sources and I need to pack all these within a single texture atlas. Example for a racing game circuit, there are textures for : ...
2
votes
1answer
123 views

Should I use the State Design pattern for only two states? Also, what if one object's state is affected by another state?

If you only have two states for an object, is it worth it to still use the State Design pattern? The context is a multi-player, turn-based game environment where there are Game "Tables" that a player ...
13
votes
1answer
846 views

How to verify the Liskov substitution principle in an inheritance hierarchy?

Inspired by this answer: Liskov Substitution Principle requires that Preconditions cannot be strengthened in a subtype. Postconditions cannot be weakened in a subtype. Invariants ...
57
votes
5answers
4k views

Why were Java collections implemented with “optional methods” in the interface?

During my first implementation extending the Java collection framework, I was quite surprised to see that the collection interface contains methods declared as optional. The implementer is expected ...
3
votes
1answer
220 views

On Developing Web Services with Global State

I'm new to web programming. I'm more experienced and comfortable with client-side code. Recently, I've been dabbling in web programming through Python's Google App Engine. I ran into some difficulty ...
3
votes
1answer
190 views

Minimize useless tweaking of a numeric app [closed]

I'm developing a numeric application (nonlinear optimizer), with a zillion knobs to tweak and rising. It's not my first foray into this domain, but this time there are even more variables in the code ...
4
votes
1answer
111 views

Azure table storage and SQL

I am in the middle of an architectural decision that down the line will be important. I have a system where I use ATS (Azure Table Storage) as the store for simple and very little data. It's not ...
-3
votes
1answer
132 views

What should be kept in mind when writing a garbage collector? [closed]

I would like to learn the important concepts behind garbage collector design. My priority is conceptual clarity, not runtime efficiency. In particular, I would like to know: What data structures are ...
-1
votes
1answer
24 views

How to help you client into making better requirements for you? [duplicate]

One of the most difficult and critical part of a project is to get good requirements from your client (internal or otherwise). I understand by 'good requirement' one that is not so high-level that's ...
2
votes
1answer
136 views

Upload files from mobile device to Amazon S3 architecture

I have an iOS app that communicates to a REST API I developed. I am using Amazon S3 for storage of image and audio files. Right now I am able to upload/download the files directly from the mobile app ...
4
votes
1answer
287 views

Social network notification system

Background I am working on an app for a client that includes some social networking features. I was originally developing the mobile front-end, but circumstances have left me in charge of developing ...
3
votes
3answers
383 views

Use interface or abstract class?

Now the title might seem like the question has been asked before but let me explain my situation and you'll see why I am asking this question. Let's consider this interface : public interface ...
22
votes
7answers
2k views

Does functional programming ignore the benefits gained from the “On the Criteria To Be Used in Decomposing Systems into Modules” (data hiding)?

There's a classic article named On the Criteria To Be Used in Decomposing Systems into Modules that I just read for the first time. It makes perfect sense to me, and is probably one of those articles ...
5
votes
2answers
238 views

Top-down vs Bottom-up approach when designing a class library

I am designing a class library to represent western equal temperament music theory concepts for the purpose of composing notated music with code (I realize there are other libraries and programs for ...
28
votes
4answers
4k views

TDD - Outside In vs Inside Out

What is the difference between building an application Outside In vs building it Inside Out using TDD? These are the books I read about TDD and unit testing: Test Driven Development: By Example ...
68
votes
11answers
5k views

Advice on designing web application with a 40+ year lifetime

Scenario Currently, I am apart of a health care project whose main requirement is to capture data with unknown attributes using user generated forms by health care providers. The second requirement ...
22
votes
7answers
18k views

What is the difference between “data hiding” and “encapsulation”?

I'm reading "Java concurrency in practice" and there is said: "Fortunately, the same object-oriented techniques that help you write well-organized, maintainable classes - such as encapsulation and ...
0
votes
5answers
360 views

Should we always DRY? Any edge case examples of when not to? [closed]

I've only ever been working in higher level languages such as C# and JavaScript. A couple of moments ago someone asked this question on SO. Now I'm curious to know, for some of the lower level ...
2
votes
2answers
4k views

How can I separate the user interface from the business logic while still maintaining efficiency?

Let's say that I want to show a form that represents 10 different objects on a combobox. For example, I want the user to pick one hamburguer from 10 different ones that contain tomatoes. Since I want ...
4
votes
1answer
146 views

Dealing with class optional dependencies

I am wondering how are you guys handling an optional class properties. Let's say I have a product that can bud doesn't have to have a color property. Is that really the best way of doing that? Should ...
14
votes
8answers
8k views

Feature vs. Function [closed]

Often I hear PMs (Project Managers) talk about feature and function. And I'm just so puzzled to differentiate them. Sometimes I think of a feature to be equivalent to a user story. Something like "As ...
3
votes
0answers
37 views

Seeking opinions on using device tree for I/O definition

I've been working ELLCC, a clang/LLVM based development tool chain targeting ARM, Mips, Microblaze, PowerPC, and x86 targets. The tool chain is pretty complete and runs on Linux, Windows, and Mac OS ...
4
votes
2answers
117 views

Is it considered good practice to declare base interfaces without mutators, supplying mutatators in a sub-interface

I asked a question on StackOverflow on how to properly implement an ImmutableMap that abides by the SOLID principles. Due to Java's Map interface containing put and putAll, it violates the interface ...
2
votes
1answer
92 views

Should I consider uncertain future requirement while development? [duplicate]

I have one text box across multiple pages which is used to enter multiple customerids (as comma separated) . But in current page due to some subsequent implementation difficulties we make it as ...
3
votes
2answers
176 views

Is embedding URLs as query parameters in URLs an acceptable REST API design pattern? [closed]

We are designing some resource oriented web services. Service B needs to be able to make calls to Service A passing in a reference to a resource in service B that service A will use when formulating ...
0
votes
0answers
68 views

Should a 12Factor App persist config in the DB?

The 12factor approach to config is The twelve-factor app stores config in environment variables...they are a language- and OS-agnostic standard. I've worked on many (rails) projects where ...
3
votes
3answers
261 views

Can a the kind of load Uber handles be served from just one server?

http://techcrunch.com/2013/12/04/leaked-uber-numbers-which-weve-confirmed-point-to-over-1b-gross-revenue-213m-revenue/ This article says that Uber does about 1M requests a week. Which is about 1.65 ...
1
vote
1answer
256 views

How to develop custom functions on top of Ejabberd? [closed]

I'm developing a real time chat app. After searching around for a while, I found Ejabberd and Erlang is a good option. The question is the Ejabberd is not providing all the functions I need. I need ...
4
votes
3answers
709 views

How to show someone of the power of model-view-controller design pattern?

I've been working with a friend on a project that we've taken over, and I've realized that we have a big problem implementing the model-view-controller design pattern due to the way that the project ...
9
votes
2answers
401 views

Should HTTP Request/Response objects be immutable?

I think it's safe to say that most web applications are based on the request/response paradigm. PHP has never had a formal abstraction of these objects. One group is trying to change this: ...
1
vote
3answers
53 views

Clarification on Acquire/Release Semantics in multithreaded programming

In an attempt to fundamentally understand any concept, I try to understand the meaning of the words within the context it is being used. Currently, I am trying to fundamentally understand the whole ...
0
votes
2answers
171 views

Storm topology to handle “dating website”-like workloads

suppose im writing a dating website, similar to okcupid. there are profiles, and i need to compute the (N^2) "match" table - given every 2 profiles whats the match between them? I was thinking this ...
2
votes
4answers
225 views

Which design pattern for a single class accessing an object representing a data structure?

Which design pattern should I use when I have a class representing a data structure (aka C-style struct) and I wish to have only a single class to be able to access it. I was thinking of simply ...
1
vote
2answers
193 views

Dependency injection vs dependency lookup in a layered architecture

Given a layered architecture, where the business logic is isolated in a package from all other layers, like persistent storage, user interface, interfaces for various (vendor) remote services, etc, I ...
1
vote
1answer
45 views

What's the best way to store class/type info in a plugin system in your software?

There are lots of applications like 3ds Max, Maya, etc that allows you to use plugins, where even the default nodes are created as plugins. This is all good but if the developer changes the ...
3
votes
1answer
73 views

Consistent snapshot

Suppose process A has a consitent snapshot of some entities. And it is constantly receiving updates for this enteties. Now client B connecting to A and it should receive the consistent snapshot of ...
16
votes
5answers
4k views

What are the best resources for learning about concurrency and multi-threaded applications? [closed]

I realised I have a massive knowledge gap when it comes to multi-threaded applications and concurrent programming. I've covered some basics in the past, but most of it seems to be gone from my mind, ...
-1
votes
1answer
66 views

Pathfinding in a 3d world with obstacles?

What are some methods for pathfinding in a 3d world? Object X needs to move from Point A to Point B but it might have to avoid things like asteroids, planets or gas pockets that makes the object ...
0
votes
1answer
159 views

Full screen command line app that user cannot close in any way [closed]

All I'd like user to see is a "full screen" command line interface running my program. Users can enter certain input when prompted to, but they shouldn't be able under any circumstances to stop the ...
2
votes
1answer
93 views

Ambiguity of seemingly clear method names in APIs

(The question is language-agnostic, but to illustrate the point, I wrote the examples in C#.) Say I'm trying to model the behavior of "components" that communicate via "ports". I might model this ...
1
vote
1answer
118 views

Does Go implicitly discourage getters and setters and encourage direct member access?

As the title says, is accessing public struct fields more idiomatic in Go than getters and setters? Wouldn't that lead to violation of data encapsulation, also public fields in other OO languages like ...
2
votes
2answers
168 views

Archive Without Adding Dependencies [closed]

We're going back and forth on this problem and I'd like to have oppinions: We have a library calculating stuff and some module with GUI logic using it. We want to add some kind of archiving to the ...
-1
votes
1answer
73 views

How to make variables inherent to an object or system [duplicate]

How can one make variables inherent to an object or system? For example, when creating a web browser, each option that is created for the user to have control over (i.e. how a window opens, if ...
2
votes
3answers
284 views

Repetitive code over multiple classes. Best way to centralize code?

I'm working with 3D arrays that I flatten into a 1D arrays with the following index calculation: index = x + WIDTH * (y + DEPTH * z) I'm starting to notice that I'm using the calculation all over ...
2
votes
1answer
106 views

Is it OK to deprecate methods that need to be public due to the packaging model but are not to be used outside the codebase in Java?

I am currently working on a semi-large project that has several packages. There are 3 main packages, a "client" package, a "server" package and a "common" package. There are two jars, one for the ...
0
votes
0answers
330 views

Online stores service design [duplicate]

I am designing an online store service app with rails. Everyone who wants to make his/her own store can do it with this app by just signing up and choosing a domain. I want to make it as SaaS as it ...
8
votes
6answers
906 views

Many small requests vs. few large requests (API Design)

I'm currently working on a project with an organization as follows: Client - Gets data from the main server via REST api. Server - Requests data from various other servers via third-party APIs ...