instruction stringlengths 34 36.1k |
|---|
The Development Team is responsible for creating/updating the definition of “Done”.
According to official Scrum framework, WHEN is it most appropriate for a Development Team to create/update their definition of “Done”?
WHEN is it most appropriate for a Development Team to initially create the definition of “Done”?
WHE... |
Lets say I have a JavaScript class that takes a whole lot of settings in the constructor, and then only have one method that the user of the class might want to call multiple times. Here's an example:
class Doer {
constructor(settings) {
this._settings = settings;
}
function doIt(params) {
... |
Imagine a system that has a large number of servers. Each of them has a number of settings:
Some specific to the server
Some specific to the region
Some common across all of them
Maybe you can have some custom groupings, like this group of servers is for reading only
etc.
Current practice I have in mind is a simple p... |
We recently had a company (netsuite) come by and mentioned how their e-commerce software was open source. When I asked if I could see the source code, they mentioned I had to either:
Get with a training specialist (and not see the source code).
Buy the software to view the source code.
Could you even consider this... |
I worked for a client a number of years ago (who I won't name to protect the guilty) that would periodically have information like the following in their View logic:
if (client == "a") {
// ...
}
else if (client == "b") {
// ...
}
else {
// ...
}
Their platform was ColdFusion (yeah, don't laugh) and this was ... |
TDD and general best practices around writing tests say that we should test the behavior and not implementation.
Hypothesis:
In that context, EasyMock.expect().andReturn() should never be used because expect().andReturn() will fail if the expected method is not called on the mocked object.
Instead, expect().andStubRet... |
Here is the framework
We have an SQL database in which our database model lives in. On the other side, there is a bunch of code using and filling that database.
Here is what we want
We want to put both, the database model and the software code, under version control to be able to go forth and back within
different ve... |
In my application users compute some engineering data (physical quantities like lengths, and weights).
Currently the core formulas work on and assume English system, but user can select English or Metric system to work in. If English is selected, no special provisions are required, everything is done in English.
But i... |
Recently I've had an argument with a teammate that I was "not consulting them before reverting" because it makes them "look like an idiot". (For context, this is a university project, and the revert was over code placement.)
This makes me wonder: What is the norm for informing the committer that a revert needs to be do... |
I believe I have learned some/many/most of the basic concepts underlying functional programming in JavaScript. However, I have trouble specifically reading functional code, even code I've written, and wonder if anyone can give me any pointers, tips, best practices, terminology, etc. that can help.
Take the code below. ... |
I am trying to learn ways of DDD and related subjects. I came up with an idea of simple bounded context to implement "bank": there are accounts, money can be deposited, withdrawn and transferred between them. It is also important to keep history of changes.
I identified Account entity and that event sourcing would be g... |
I have some categories that users can favorite and track, the actual category names and details are stored in the DB but the items belonging to each category are fetched via api.
When a user adds a category to its favorite list I call the api fetch all the items belonging to the category, and store the actual category... |
I'm struggling with Object Oriented Programming.
From a conceptual point view, are instance methods contained in objects (like instance variables are)?
I am picturing objects like this:
|
EDIT 2017/02/13 - Check the repo as it is now. The first example is solving with SRP in mind, but later on introducing other principles of SOLID.. I should've explained that better.
I'm trying to get a good example down of a violation and how to solve the SR principle. I want to be sure however it is good, and that I'... |
I have a question related to relationships between aggregates in Domain Driven Design.
I have the following situation: I have an aggregate (questionnaire) which has some children (questions). The questions are entities, but because they are inside the questionnaire aggregate they can have local identities (i.e. questio... |
I have 3 types of users who might login to my website: Admin, Instructor, Student.
I already have tables for Students and Instructors , and each one has its unique properties .
Now I want to create the login page. Many tutorials use role-based authentication in similar cases, but In my case , I have already created ... |
During development with MVC I figured out this Architecture (based on Symfony Framework but I need to apply it more generally on MVC Pattern base software):
In other words each model is a Facade of my business Logic. Usually is in this Form:
<?php
//Namespace definition
class SomeModel
{
public function __construct... |
I am trying to check if my array A has an instance of object B at the current position, since it is an array that can contain two types of objects (B and C). I do not want to use instanceof, so I'm wondering what other alternatives I have?
if(A[i] instanceof B)
|
Javascript is a single threaded language but when developing point-and-click adventure games, it's often advantageous to have 2 "threads" running, the rendering/logic thread and the game scripting thread.
The rendering/logic thread runs every game-loop to render the scene and move the characters around and so forth.
Th... |
My current project is to implement a kind of WinMerge clone to compare two files.
I am using C++ with the Win32-API (WTL, ATL, that stuff), and I already designed an UI for this. However, I am now sitting here, thinking about a design on how to manage the whole file comparison and the data flow.
Following problem:
I ha... |
My application is a Java program that controls a robot (which is essentially a raspberry pi hooked up to a lot of devices). There are many devices on the robot that have semi constant address values or pin numbers. Currently in our codebase you'll see a lot of static constants defined like:
static final long SLEEP_DURA... |
This is the problem: I am designing a framework that is basically getting chemical compounds, perform operation with them (or among them) and return results.
At the moment I have a class that holds all the operations(like mix, centrifugate, separate, heat up and so on). I create a sequence basically by hand, including ... |
I've been looking at ways to monitor for changes in things like price and availability on e-commerce sites via visiting browsers, with three constraints:
the sites often don't have much ongoing development effort behind them, so the solution needs to be simple to implement
there should be minimal impact on how quickly... |
Coming from Python, if C does not have array bounds, how does it know where a[1] starts?
int a[3][3] = {{1, 2, 3}, {4, 5, 6}, {7, 8, 9}};
b = a[1][1];
|
Usually on Symnfony framework I use the provided depedency Injection container and on Controller I load the models as a service. To be more In detail on a current project I am having the following services.yml:
# Learn more about services, parameters and containers at
# http://symfony.com/doc/current/book/service_conta... |
Now I'm trying to understand Actor model. I know main concepts like everything is an actor etc. I see a lot of words like "it's very good from performance point of view", "no locks because there is no shared resources and messages are immutable". But I still don't understand some points:
In case of old school CRUD app... |
I'm currently working with the following abstraction.
public interface IFileRepository
{
void Save(string identifier, byte[] content);
Task SaveAsync(string identifier, byte[] content);
string GetUri(string identifier);
}
Application services would use this interface to save files on a... |
I have a class constructor that needs to perform a couple checks. It is checking a file for the occurrence of a few tags. I use a function that checks for the tags and returns a boolean value depending on whether the tag was found. If the tag was not found it calls return, stops executing the constructor and sets the a... |
Earlier today I was working on a simple program from a textbook.
Although I solved the question with confidence and a clear robust solution, the solution wasn't perfect as it had steps which were redundant.
The more I optimized and tried to make it perfect:
The code became more:
- Unreadable
- Buggy
I became:
- Le... |
Imagine an engineering type web application where there is a screen that displays around 100 of unique data values. The user can "page through" the screen by clicking Right/Left arrows, and the screen is updated with the next page of 100 values. When the right page is found based on some specification, user can save t... |
What is the best practice way to restrict access to particular resources based on ownership. For example, if Adam created several posts (collection: /posts). And I want Adam to be the only user able to GET these, how can I restrict another user, Eve, from retrieving Adam's posts from the data store?
I can force a user ... |
Recently I started working on a project where a very old monolithic application is being migrated into microservice-based architecture.
The legacy codebase is very messy ('spaghetti code') and often an apparently-simple function (e.g named as "multiplyValueByTen") later reveals itself as "thousands of lines of validati... |
Theory is, that classes which strongly know and use each other should be in the same package (using package visibility for functions that are not used by the rest of the application), thus forming a concise, understandable interface. [Well-known classes (accessed from almost everywhere, such as loggers) should go to th... |
Well, recently I found a problem about licensing.
I have an open source project on GitHub, recently I need some codes which using GNU GPL, but my project is using GNU LGPL, so that's the problem.
So how can I use these code? I don't want to change my license. Ask for permission from the original developpers or?
|
Interface is used to implement more than one class but it doesn't have any code inside its methods... however the method that is called works with its respective function. Also, it gets very confusing when it is used in design patterns like facade. example: in case of PHP framework Laravel.
|
I'm trying to check my understanding of the kappa architecture. The main point I am trying to resolve is how, if at all, one unifies the processing of data under analysis and other pieces of data, such as a user changing a setting which could later affect data analysis.
For example, suppose IoT data of electrical usag... |
I noticed some strange behavior when working with submodules in Git, which is maybe not so strange to anyone with more experience than I. Well, what I am noticing is that whenever I make changes to any of my submodules, those changes seem to stage some sort of a change for a commit by the main repository that's contain... |
I want to ask for a review of my big data app plan. I haven’t much experience in that field, so every single piece of advice would be appreciated.
Here is a link to a diagram of the architecture: My architecture overview
Our app is webanalytics app. I know that already there are many of them however, we use it to analy... |
I'd like some advice on how to approach this problem. I have a database of ~3000 pictures of people. Their names are built into the filename but there is no standard format. Here are some common name formats: MarySue-042; henry higgins03; J. H. Doe; Jones, Peter; and M N Shyamalan, MD. Some have middle names and some ... |
When we mean e-mail payload, are we talking about the whole message provided after DATA command or just the Body part of the message (without headers like From, Subject, Message-ID etc)?
S: 220 smtp.server.com Simple Mail Transfer Service Ready
C: HELO client.example.com
S: 250 Hello client.example.com
C: MAIL FROM:<ma... |
Although this question takes a very narrow, concrete form, I'm more interested in the conceptual underpinnings of justifying an approach, and how I can apply it to the next problem.
Setup
I'm writing a tool that takes a list of AWS accounts and optionally, for each account, a blacklist of S3 buckets. The tools goes thr... |
The code listed below is intended to calculate some rotation data which will later get used in my rendering code.
renderer.cpp:
rendered_image renderer::common_tasks(render_info const& info) {
//info.radius is a float, info.min_image_size is an int calculated by taking the minimum
//of info.image_width and info... |
I am having trouble understanding the purpose of everything I am trying to do here. I have web api, mvc, and angular2 project linked by authentication provided by identityserver4
As in, why would I make a web api?
Does the user that connects to my MVC application communicate for information directly with the WEB API a... |
I am working on a large scale application that has both a web portal and a mobile application so therefore I need to develop an API..
I have decided to go with the following structure:-
Sailsjs (this will be the front end, everything inside the application itself)
lumen (this will provide the oauth client and also a ... |
I would like to track, for each backlog item, which event originated it. For instance: "Original briefing", "Meeting Jan", "Meeting Feb" ...
Using scrum, what is the correct way to track the origin for each backlog item?
I'm using visual studio online to manage my scrum project.
|
For context, I'm building a GTK+ application in C where a subclass of GtkApplicationWindow creates and displays a subclass of GtkToolbar and a GtkNotebook (a widget with multiple pages that can be displayed alternately by a member function). There are radio buttons on the toolbar to switch among the pages.
Should the t... |
I have been assigned to think of a layered microservices architecture for Azure Service Fabric. But my experience mostly been on monolithic architectures I can't come up with a specific solution.
What I have thought as of now is like...
Data Layer - This is where all the Code First entities resides along with DBContext... |
Imagine I have a set of choices having different set of values but also the chance to input a free value (usually a number)
e.g.
<select name="choiceA">
<option value="One">
<option value="Two">
....
<option value="Nth">
</select>
or
<input name="freeNumChoice type="number"/>
Not all combinations ar... |
In my project I have specified 5 sublayers for my DBAL:
Database Layer ( the database itself)
Database Connection Layer ( \PDO and a class that handles the database connections)
Database Request Layer( classes that actually query the database )
Database Model Layer ( All classes that represent 1 Database table each an... |
I was reading the Wikipedia article on Actor model and came across this line-
...bridging the chasm between local and nonlocal concurrency.
What is this "non-local" concurrency and how is it different from "local" concurrency?
|
I got a problem with lazy loading in combination with a foreach loop.
I'm working on a code first asp.net backend for a website, and sometimes I want to gather information spanning multiple tables/models.
For example, take this:
public class Foo
{
[Key]
public Int32 Id { get; set; }
public virtual Bar Bar {... |
I'm designing a simple scala wrapper library over a java library in order to make it more idiomatic scala. The problem I faced with is that all operations from the java library could throw an exception, which is RuntimeException, but very similar to IOException. So I'm wondering if it's a good idea to wrap all of them ... |
I am developing an small application, just to practice DDD. Afaik. invariants are the umbrella term of validation related to domain. So for example if I want to have only ucfirst names, then that is an invariant and I need validation in the property setter to make sure that this invariant is protected and make only the... |
Overview
I'm developing a number of .NET Core applications and I've met my current sprint commitments early. Until my next sprint begins, I'm using the slack to look into setting up a CI pipeline for my projects (this hasn't been hugely necessary as I'm the only person working on these projects, but it would be helpful... |
We have a fairly complex Gruntfile.js that performs numerous things to process a bunch of EPUBs. It's part of our CI process being run regularly on Jenkins. Sometimes we want to notify the person who initiated the build of things that occurred - not errors but rather warnings (the task can continue but something abnorm... |
This is a question I see a lot. Most people say UDP is always better for real-time games than TCP. My understanding is that TCP tries to re-send packets over and over til the other side gets them whereas UDP doesn't care.
Most of the things I've read is that UDP is a must for any realtime game and TCP is terrible. But ... |
In Steven Skiena's The algorithm design manual Edition 2, he talks about dynamic arrays on page 67, which results in them having same Big-Oh as normal arrays. I don't understand how. This is what book states
Half the elements [in final array] were moved once, a quarter twice, and so on, so total movements M is given b... |
I'm setting up a microservices architecture, and am confused about how gRPC can loosely-couple services (compared to a pub-sub message service like Kafka). Doesn't the request go directly to the server, and not through a pub/sub system? While gRPC supports asynchronous requests, should I still use pub/sub as a buffer... |
I am learning to create simple Unit tests to eventually (and hopefully) start to do only TDD; for now I am trying to write tests for code already written to see what might cause problems. This is one of them.
Let's say I have this simple class (with Typescript-> Javascript):
class PrivateStuff {
greeting: string;
... |
We are in the process of slowly splitting out a monolithic application to smaller services and one of the debates we are having is how to manage dependencies. The challenge we have is that service A has a dependency on B. A pulls its dependencies from the release Nexus repo.
The problem is B is built and the dependenc... |
I have an application that has an SQL command timeout 3 minute. What would be the impact if query finishes processing in 1 minute?
|
I am new to NoSQL and have always heard of "key-value" DBs like Cassandra or Riak and expected their tables to literally have two columns: a key-col and a value-col. I just started working at a new shop where the senior engineers chose Cassandra as the main datastore and setup their own Cassandra cluster themselves. Ba... |
Application background
A short description of what the application should do
I'm developing an application which analyses DNA sequences. The user will load a certain file containing a DNA sequence. Then the user can click on a button to search for ORFs (parts of the DNA sequence with specific features). These ORFs can... |
I am redesigning an existing SQL Server-backed web application. This application is used for tracking subjects (names, addresses, phone numbers, etc...) and related data (assessment information, court information, school information, etc...). One of the requirements is that certain users should not be allowed to see ... |
I am trying to explain the benefits of version control to a colleague (recent graduate with little software experience), but he doesn't think it is useful in his case.
I explained you commit every time you write a new function, fix a bug, or generally add anything useful to your code. The stuff he is working on started... |
I am building a WMS with the following basic requirements:
Each Item can be in multiple Locations.
A Location can contain multiple Items.
For each Location / item combination, I must be able to track:
QtyOnHand, QtyReserved, and QtyAvailable.
One Location can contain another Location.
The basic required behaviour of ... |
With Doctrine annotation processing engine for PHP, and Annotatons being used for Doctrine Entities and for Zend Form, and possibly other things, and use in other languages as well, it looks like Annotations are here to stay.
Example Annotations for Zend Form:
/**
* @Annotation\Filter({"name":"StringTrim"})
* @Anno... |
I was going through old code and noticed one pattern that repeats itself all over the place - dynamic dispatch.
While I don't see any problem with the implementation itself, I was wondering if there are other ways of handling dynamic dispatch.
To bring an example - consider a scenario where at run time I'm going to get... |
Up to now, I was considering MySQLi functions in PHP one example of DAL. And I initiated a simple project to publish in an article with the title "starting with PHP and DAL and MySQL"
But when I made a search for some topics to add in my article I "discovered" two things:
The website PHP.net don't list MySQLi in there... |
I have an active record based ORM with soft deletes (Laravel Eloquent to be specific) in an SQL database.
The 'soft delete' behavior that is built in to the ORM is:
If the record is not deleted, then deleted_at is null. When a record is soft deleted, the deleted_at field is populated with a timestamp.
The ORM uses the ... |
Consider a greenfield development situation where cloud tools are being considered vs. in-house solutions, in the vein of AWS SQS vs. self-hosted Kafka, ECS vs. Mesos-Marathon, Lambda/Azure Functions vs. Whisk vs an array of custom APIs/services.
All else being equal (financial cost, technical expertise, etc.), how can... |
I have several backend services (REST+SOAP) that have to be consumed by a SPA (Single Page Angular2 App).
As JWT (JSON Web Token) is not feasible for me for the moment, security is done using CAS Central Authentication Service ( single sign-on protocol ).
In order to avoid CORS (Cross-Origin Resource Sharing) and to ha... |
I have a class Item that has a non-default constructor and doesn't have a default constructor. There is no default constructor because I don't want to have Item objects with some strange default values around.
class Item {
int a;
public:
Item(int a) : a(a) {}
}
Another class User uses Item class and has a... |
I recently read the Building Maintainable Software book by Joost Visser and feel there is something they haven't discussed.
The title hints as much, I do not know if following the guidelines have anything to do with field/attributes.
The relevant guidelines:
-Write short units of code
-Keep your codebases small
Can I... |
Many java DI frameworks (Spring, CDI amongst others) implements some kind of qualified injection through user-designed qualifiers annotations.
interface Engine { .. }
@Powerful
public PowerfulEngine implements Engine { .. }
public class Car {
@Inject @Powerful
private Engine engine; // will inject a Powerful... |
I have ecommerce webapplication, that can connect to multiple storage systems. Currently I am using nuget to deploy it.
I would like to split my application into parts (per storage system), because it takes long time to build and debug it (all referenced assemblies are scanned for DI). There will be only one storage sy... |
For example if I have a constant, like generated password size, then where should I put that constant if the random password generator is implemented in the infrastructure? I guess this should be a domain service, but I guess I cannot put the constant in the service interface. Or can I?
I ended up with this:
namespace ... |
I have one method which stores some value in to the row set and then these values update in the database in caller method.
Is it good practice to put it under system test?
updateStatus(documents) {
Iterate over the documents {
Row row=rowset.egtRow(index);
update the status in row.
}
}
|
I'm a computer science student at some college out there but i'm a little confused with using the SRS and various diagram such as activity diagram or use-case diagram. I know the objective of the SRS is to minimizes the time and effort required by developers to achieve specific goals and to reduce the development cost ... |
I made a tiny wrapper for fluent precondition assertions in c#.
Now basically in all public / contract methods i assert the values this way:
Precondition
.For(()=>Model)
.NotNull();
Precondition creates a ValidationRule Instance on which I have the given validation methods.
Now this happens ver... |
Let's say I need to implement an application which requires email confirmation for new users. When a new user registers, an email which includes a confirmation key is sent to his email address. When he consumes the key, his registration is complete.
The confirmation keys are generated at registration (and associated wi... |
Abstract
I'm working on a REST interface to a graph database (Titan/Gremlin-Server, but this shouldn't matter) that has a strong sense of type for vertices and edges. I'd like to design a REST API to perform CRUD operations while enforcing some type information.
Overview
The purpose of this database is to model the fl... |
I am a Python programmer primarily who uses pylint for linting source code. I am able to eliminate all of the warnings except one: Invalid name for a constant. Changing the name to all caps fixes it, but am I really supposed to do that? If I do it, I find that my code looks ugly as most of the variables are constant (a... |
We will be building a system with the UI in javaFx that will be deployed to 2000+ machines (minimum is 2000, but it will be more - can reach 5000 machines).
For other reasons/limitations it must be installed on the machine, so we cannot do it with a web browser interface.
The 2000+ machines will be in different geograp... |
I have an application in which users can rate items from a list by whether they like or dislike them (users may also choose not to rate an item).
There are millions of items which can be rated by users in this positive/negative/unrated way. I am looking for a solution to what sort of database and database design would ... |
Our company will purchase a large and very complex piece of source code for satellite communications.
It is coded in C++ and we will code additions to it, also in C++, linking our code with the purchased code into a single executable unit.
Is it necessary that we use the same compiler and same compiler version as w... |
I am building a series of web apps connected to a single point of authentication. Basically, a user tries to access a site, if not authenticated they are redirected to the central auth system's login page. Once they successfully login, they are redirected to their app. From then on, if they access any other app they wo... |
I apologize if this is a little vague, but I'm curious about what most people use for naming conventions for classes that access a webservice. Typically on my team we create separate projects for BLL (business rules), Model (DTOs and ASP.NET model classes), and Data ( typically Db and WS I/O ).
My question is in regar... |
and sorry if the question seems a bit naive.
I'm currently reading tutorials about Kafka & Spark and there's something I can't figure out : how to exploit / expose the data Spark received.
Here's what I'm trying to understand :
A lot of events <=> Kafka broker <=> Spark receiver <=> Map/Reduce/Transform/Aggregate/MLear... |
I want to find out what part of "loosely coupled" code it is im failing to understand.
Say I have an object Person im using in both my client and server code. If I change a certain field in Person from type int to int[]. What I've found is that there will be a huge ripple effect in my code almost everywhere I've used t... |
I have in my relational database three tables like this: Route -> RouteStore -> Store. So I can modify which stores can be part of a route every certain time (adding or removing) and I need to keep a history of these changes. Someone I know suggested formatting the data into a text format (JSON this case) and save it i... |
Given an array A of N positive integers (N <= 20), we have the following operation. For any two consecutive non-equal elements, we can replace the larger number by the absolute value of the difference between these two numbers. We keep using this operation until all elements are equal. Find a way to make all elements a... |
Let's say I have an interface such as
Public Interface CarManager {
Car getCar(String model);
}
And I have a lot of legacy classes that implement this interface.
But now I have a new requirement where I still need to implement this interface, yet the getCar method would now require a new signature such as
Publi... |
Here is a scenario:
User submits a story. As as a user I want X so that Y and Z.
Story does not make in the sprint, and then the next sprint, and then the next, etc.
I am noticing stories lingering on the backlog for months while others are submitted and added to a sprint in short order. I see a risk that users watch... |
I noticed that the Airbnb Android app sends such an intent to open a map app at a particular latitude/longitude:
geo:0:0?q=77.77%2C88.88
From my simplistic point of view, they should use the standard Geo URI scheme instead:
geo:77.77:88.88
Is that ?q= syntax a kind of de-facto standard?
Is it a trick that solves issu... |
I am overviewing a structure where a mapping table of student enrollments is done. I am wondering whether an additional column (class_category_id) to the mapping table would become a problem or a noticeable advantage. That additional key would be used to filter very often.
Here's a simplified structure of the database:... |
I need to rewrite old ASP.NET web forms VB application to new ASP.net mvc in c#.
Problem is that most of the old application logic for data inserting retrieval is written in stored procedures, which got messy over time, as old team was adding tons of stored procedures, which are doing the same thing, but contained sma... |
We are starting a new project, from scratch. About eight developers, a dozen or so subsystems, each with four or five source files.
What can we do to prevent “header hell”, AKA “spaghetti headers”?
One header per source file?
Plus one per subsystem?
Separate typdefs, stucts & enums from function prototypes?
Separate s... |
Problem
We have a number of different customers getting a number of different price files, each customer can then also have different styles of pricing files for example customers can have just two columns, product and price. Some customers can have up to 20-30 fields each of these fields can exist in different tables ... |
This page on JS Promises says it is a software abstraction. What is a software abstraction and why is the JS Promises called software abstration?
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.