0
votes
0answers
2 views

Standard Rails way of implementing customisable site functionality

We have a Rails web application that allows users to purchase access to combinations of our sites functionality. The exact business scenario is rather complex but a SSCCE would be as follows: ...
0
votes
2answers
23 views

Definition of portable C

I have been having a huge and heated argument with someone on a slack group - the debate is this : My argument Portable code is that which compiles with various compilers and runs exactly the same ...
0
votes
0answers
9 views

Mocking non-copyable objects

I find myself often in the situation where I want to mock a non-copyable object, for example a DbHandle handle. I was going back and forth looking at different design choices, and I settled on the ...
0
votes
0answers
9 views

Slow throughput - still worth using a dedicated message queue?

Here are some requirements for a queue: Every few days add ~100k tasks with various priorities Workers will pull tasks at typically less than 10 / second Tasks need to be completed ~3 times by ...
0
votes
0answers
11 views

Indexing Algorithm That Avoids Duplicate Lookups On An Uncontrollable Dataset

How to index a massive, randomly selected, uncontrollable, constantantly changing dataset? Imagine you want to index all of the snow particles in a giant snowglobe that is constantly being shaken. ...
0
votes
0answers
23 views

MVVM with DI, view model location and shared service data

I have a couple of questions regarding MVVM view models. I have 3 view models in my scenario, which I have put together a shorter sample below. I was looking for a nice solution for 3 views working ...
-5
votes
0answers
24 views

Get Property of a class or subclass by string

Is there a c# method that return the instance property of a class if I Know a string? In detail: I know that string "Vehicle.Car.Bentley.Horsepower", where Vehicle is the main class and the other ...
0
votes
0answers
11 views

REST MVC Confusion For An Enterprise Appplication Architecture

I already have experience working with MVC based web apps and started reading recently about REST. But went into confusion when re-thinking about how existing web app not using any kind of framework/...
1
vote
0answers
44 views

finding the hidden reference causing a memory leak

Here's a pretty problem. I recently had a memory leak in a java program where one huge object was not collected, even though it "should" have been collected when the whole complex graph of objects ...
3
votes
3answers
98 views

What are the potential tradeoffs for lower down Cyclomatic Complexity

Since high Cyclomatic Complexity is harmful, and it would be beneficial to lower it down by creating sub functions. However, it might lead to a long calling queue and lead to some super nested ...
-2
votes
0answers
23 views

Develop a VR Workspace

Whenever I work on large projects, I surround myself with whiteboards. I can spread out my ideas and work on multiple parts at once. I find my organization with this method is much better than with ...
1
vote
3answers
92 views

What are advantages of XML over S-expressions(-ish) notation?

I would like to ask a question about XML and S-expressions(-ish) notation. S-expressions are pretty old; they are also really simple. We could consider two forms that are equal in meaning, different ...
0
votes
0answers
6 views

Simulate gesture [migrated]

If you are on a non touch screen is there a way for mouse the simulate a finger to test for gesture recognition? I am on .NET writing a Universal Application. I want to test for swipe without ...
0
votes
0answers
36 views

Should I back-merge every day in a large project?

I work on a large project (C++, C#) in areas that can have a lot of churn. I'm in the habit of getting latest sources multiple times a day. Every now and then this results in an awful back-merge. ...
0
votes
0answers
26 views

BigDecimal for Calculation with and Display of Stock Shares and Prices?

I'm receiving flat files with the stock price and number of held shares for an account. One file contains the price and shares to 6 decimal places. The other file contains the price and shares to 12 ...
0
votes
1answer
11 views

Viewing local changes to website on separate device

I'm trying to figure out how to do something, and I can't quite seem to get it to work. Let me describe the situation: Using a hosts file, we redirect the resources (CSS/JS/etc) of a website, let's ...
3
votes
1answer
104 views

Avoiding hard-coded format strings

In C, we like to use #define or const globals to avoid hard-coding values and strings. How can we avoid hard-coding strings that need to be formatted? Consider, for instance, building a filepath to ...
0
votes
0answers
22 views

Proper way of empting deques with higher priorities with a threaded removal

I'm developing a producer/consumer system with three deques (each for one priority level, from max to min); first deque has major priority, so it must be read before others: once empty, others deques ...
1
vote
1answer
31 views

Do Non-Functional Requirements for Security make sense for defining SDLC?

I recently had engaged in a security discussion with my companies cyber security risk lead, discussing security controls and standards they would be holding the project to. The expectation of the ...
-2
votes
0answers
16 views

Neo4j Browser and Android application [on hold]

i'm building an android game with android studio and I had to download the entire wikipedia dump to extract links and page titles to use them in my game. Since the database is huge (192M links) I ...
2
votes
1answer
66 views

REST API design with big (detailed) and small objects

We're facing the issue that we often have classes with lots of properties. But we don't need them for most API calls. So we end up having multiple versions for basically the same business object. E....
0
votes
1answer
25 views

When is cloud BlobStorage used?

Let's say we have an app deployed to Azure. App has external files not bundled with it, files which are required for app to operate. They are seperate but are essentially part of the software. ...
1
vote
0answers
30 views

MongoDB design schema

Objective Get a good schema capable of making searches easy depending on the hierarchy. Background I am coding a database for a webervice that will return information about items for a game called ...
-4
votes
0answers
54 views

Is there great practical collection of rules for Front End? [on hold]

I'm going to create some kind of "standards" of Front End development (from simple "PSD to HTML" tasks to entire single page applications). It should be overall and legible, now I have some basic ...
-2
votes
0answers
17 views

Use of cordova plugin RF ID scanner

How can i use RF-id scanner plugin to read the data? $scope.callScan = function() { try { rfidscanner.radar(winScan, failScan); } catch(err) { alert("Error: " + ...
-1
votes
0answers
16 views

What to do after bundling my application [on hold]

As of right now I'm trying to deploy my web application, written in angular 2, tested in plunker, to tomcat. I've been searching arround but I've seen practically anything that seems like a reasonable/...
-2
votes
0answers
22 views

how to check if session is destroyed or created in php? [on hold]

i try this but does not work out <?php $_sesstion start() if(SESSION_id()) { echo $_SESSION['email']; echo ""; echo $_SESSION['password']; echo ""; echo "Welcome"; ...
1
vote
1answer
38 views

SQL queries in integration tests

Current situation I have a situation that I find frustrating: the integration tests in my project (a RESTful API) contain both API HTTP calls and SQL queries. Whenever an API call is made that writes ...
1
vote
0answers
17 views

How to handle unit tests with collaborators and side effects?

We're in a project that has quite a lot of code and while in general we have a good test coverage and things work out pretty well, I noticed that our tests grew more and more complex over time up to a ...
0
votes
2answers
106 views

Simulating objects in Functional Programming

In FP vs. OO, from the trenches, Michael Fogus says: Whenever I write some code to deal with data about people then functional programming seems to work best. Whenever I write some code to ...
1
vote
2answers
48 views

Handling exception types according to the current “layer” of appplication

Imagine this simple application use case, say, for fetching data from outisde of the app. These steps represent the "depth" of the layers, from top to bottom. UI touch event ViewModel handles said ...
0
votes
0answers
23 views

How to setup a template to create a bunch of code samples for customers which vary slightly?

Our company sells (electronic) devices which can be controlled from a pc. To make it easy to write a program or script we provide a programming API. We provide samples which show the customers how ...
0
votes
0answers
24 views

DDD: Where to place domain event handlers?

Could you tell me your opinion that which layer is the right one to place domain event handlers in DDD? For example, I have application service to add a new contract and I'd like to send an email ...
0
votes
1answer
67 views

Constructor Chaining vs Similar ones

I have the following constructors: public Class1() { this.Variable = new Variable(); } public Class1(Variable vari) { this.Variable = vari; } Which can be rewritten as: public Class1() ...
2
votes
3answers
83 views

Prefer self documenting code over cyclomatic complexity?

I'm interested in which approach to prefer. Consider some code which retrieves a translation for some text. It has to respect these constraints: Return translation only if the text will be used on a ...
-3
votes
0answers
50 views

Measuring how I spend my time while Programming [on hold]

My team leader has an excel sheet where he tracks time. How we plan to spend our time in 4 categories. How we actually spent our time in these categories. I want to have a program running and record ...
1
vote
0answers
54 views

Java redeclare inherited Interfaces?

While working on a small class called FractionNumber I found asking myself if I should implement an interface that I am already implementing. Sounds stupid I know but bear with me. My class ...
-4
votes
0answers
22 views

Best Sites to learn Java [on hold]

What are the best sites to learn Java Spring
2
votes
2answers
75 views

How do I know if I have to care about thread safety?

I don't know much about how computers work internally, so I also don't know much about multithreading, and when it takes place. I know it is important in databases or web applications and such, where ...
0
votes
3answers
55 views

Convincing Client to return open source work

(Not sure if there was a relevant stack exchange site for this, I saw a few ones related to open source in companies and figured this was similar, but different enough to warrant a new question). We ...
1
vote
1answer
18 views

ASP.net using Resource (resx) for Configuration

Let me start with the fact that I'm prepared for this question to be closed as opinion based, but I am going to attempt to phrase it in such a way to keep it less based on opinions. The Short Version ...
0
votes
1answer
31 views

Read/Write third party SQL Server database

One of my customers has a licensed software for business management and uses a SQL Server as database server (The database is open and I can run queries). They have a need that the current software ...
-3
votes
2answers
124 views

What is well written code? [on hold]

Is code that runs fast but written with a bad and hard to understand syntax, good code? Is code that runs slowly but written with a good and easy to understand syntax, good code?
4
votes
0answers
53 views

In an enterprise architecture, where is Service Locator most appropriately used, and why?

I'm trying to implement the Service Locator pattern. In the below diagram is my references between projects (.net projects), each box represents a project. The arrows indicate the dependencies. I ...
-3
votes
0answers
41 views

I'm trying to write a program to compare one number to another [on hold]

I'm a student just learning Python and I'm hoping someone out there can take a look at what I've got for comparing one number to another. Here's the actual assignment: For your assignment you must ...
-3
votes
0answers
23 views

Not getting output in alphabetical order in listview and also how to set phone call feautre at every item in the listview? [on hold]

I am trying to pull the contact numbers from phonebook to a listview in my android app. But even after making changes in the 'query()' the problem is still the same that is names in list are not in ...
2
votes
3answers
72 views

Does it make sense to validate data taken from the database?

This is intended to be a general language-agnostic question. It is written around a weird example simply because I could not find a better way to ask. Also, the "pseudocodes" provided look like a ...
2
votes
1answer
69 views

Unique Identifiers for classes - Java with Spring

My use case requires me to implement multiple validators which implement the interface: public interface Validator { boolean validate(Object o); } Based on the business group of the Object o, a ...
-3
votes
0answers
34 views

List Every Possible Equation to get a Certain Number [on hold]

I'm not a very experienced programmer and I've come up with a problem. I have a set of 6 numbers. 280581172 - 978 - 2406 - 121 - X (unknown) = 842 The right combination of the 5 numbers result in ...
-2
votes
0answers
70 views

Text file - editing in C++ [on hold]

I have some lines of text in a word doc. Each line has the format of an article, like: Author(s). Title. Journal, number of the Journal (Year), pages I want to put this data in Excel but in way such ...

15 30 50 per page