Tag Info

Hot answers tagged

11

I'll give you some tips, regarding CRUD applications, since I don't have much experience in games or graphically intensive apps: Business logic usually involves rules the owner of the business has learned or decided over years of operation, like for example: "reject any new credit if the client hasn't yet finished paying the last one", or "we don't sell ...


8

LLVM backend is the primary sane way of doing this. If you lower LLVM IR to assembly or microcode, you can roll from there and just use the numerous LLVM frontends to convert higher languages like C++ into LLVM IR. In other words, LLVM was explicitly designed to support this scenario. The full stack goes like this: Frontend (e.g. Clang for C and C++) - ...


7

However, the purpose of this is not to be a package manager, but instead a standard to follow when you want to implement a system that silently, automatically updates your software in the background. I'll look through apt and rpm! The problem is that what you want to do is building a package manager whether you like it or not. Your current ...


5

First if you are concerned about recent (last 5-10 years, since Nahalem?) Intel x86, then your architect is a little off. Each core has their own 128K L1 cache split (64K data / 64K code). Above that, each core has its own L2 cache which basically acts as a buffer between the L1 and L3 cache. Each socket has its own L3 cache (up to 20MB, I think). The L1 and ...


5

It sounds like you're recreating the Configuration Management class that the .NET framework already provides. One thing that I've seen done is to provide a wrapper class around the ConfigurationManager so that a default value can be specified in case the requested configuration parameter isn't present or isn't readable in the configuration file. Using the ...


5

how can I best allocate work in initial sprints to catch the (probably inevitable) architectural issues in the solution as early as possible? By not mistaking quality of planning with quantity of planning. The entire point of agile is that planning is inadequate. Business people don't really know what they need until they can have customers try it out. ...


5

The first mistake that often gets made is that people don´t look beyond the stories in the current sprint. While it is correct that those stories are not in scope now and might change or be removed at a moments notice, completely ignoring them when making high-level design decisions is a nice route to chaos. When making high-level design decisions, you must ...


5

The ideal situation is to have a reliable connection to a single server so you can verify in real time that the presented ticket has not already been admitted to the event. As you pointed out, this is not always possible. A couple of nontechnical workarounds: Use assigned seating. Holders of duplicate tickets would have to sit on each other's laps. ...


5

Sounds like you have 3 major categories of data you are trying to store: General job data (job id, job requester id, job receiver id etc) State transitions (job started, job finished) State-specific job data (optional) job-related events (price changed, job receiver user reassigned etc) The key is to separate event-like data from everything else. Schema ...


4

Using native types (int, Guid, etc.) instead of types which express the intent (Price, ProductIdentifier, etc.) has two drawbacks: The type change is cascaded all over the code base, making it particularly painful. For instance, switching from smallint (short) to uniqueidentifier (Guid) is not only painful at database level (how do you transform ...


4

How about a hybrid of the two? A large table with a JobID and state (and perhaps other information common to all jobs and states), with other tables to manage the additional state information. That reduces (or eliminates) the duplication of data, but keeps things more manageable.


4

It sounds like most of your work may be in the UI layer. Changing the display format for business reasons, does not imply any business logic. The change is a change to the view logic. Being able to change the format implies some business logic possibly involving persistence of the preference. Persisting the format to a cookie, could also be implemented ...


3

The first question you need to answer is whether you intend to create a truly generic data access framework, or if you want it tailored to the particular project you're working on. A generic framework has the benefit of being portable and fairly loosely coupled to the underlying DB + schema, but at the cost of pushing schema level information further up in ...


3

As GlenH7 has already stated, given the constraints you have listed in the question your problem is effectively unsolvable. Assuming "it can't be done" is not an acceptable answer we're left with having to change the constraints. One option you mentioned involved getting the mobile devices to preload the entire set of tickets. Your concern was that fraud ...


3

The original poster said: However, the purpose of this is not to be a package manager, but instead a standard to follow when you want to implement a system that silently, automatically updates your software in the background. While you can write an auto-upgrader it is hard to get it right without the package-manager ability to check inter-package ...


3

The core idea would be to find the difference between the set of files currently installed on someone's computer and the newest set of files that should be installed on that person's specific computer; and (once these differences are determined) download whatever new files are missing and discard whatever old files are obsolete; hopefully in an "atomic" way ...


3

The only thing you can do to help reduce the impact of a change is to split your overall project up into many components, so while a major change will impact several of them, many will not be affected. eg if the customer decides they need a new button that sends data through the middletier to be stored in a new column in the DB, you're going to have to ...


2

So lately I've been thinking that semantically the id is any unique identifier; the fact that it happens to be in the integer or the guid format is an implementation detail and exposing the fact in the type is a leaky abstraction. Thinking about it, exposing it as a string or a dedicated Identifier type has some advantages, it makes things easier to mock, ...


2

Generally, this is not a good set up, because it's not DRY ("Don't Repeat Yourself"). If it were me, I'd work very hard to figure out how to have one well tested script which can generate the feeds needed by the individual users. Perhaps the script would get per-user information from the database.


2

While views shouldn't contain business logic, they still can contain basic conditional logic, loops, etc. Since your website is “very heavily based on whether an event has occurred or will occur”, this is definitively a case where you'll have two views, not one. What questions could I ask myself to help me determine the best approach to take to this in ...


2

Yes, the Keys are the name or identifier of each property. You may add a changeValue method. This pattern is also known a the Dynamic Object Design Pattern. Example (Pseudocode): void Example() { KeyValueList MyControl = new KeyValueList(); MyControl->put("id", "MyControl"); MyControl->put("x", 34); MyControl->put("y", 125); ...


2

Go for the second solution. Your AccountRequestValidator uses the db information and some rules to determine of the request is valid or not. Then use a "response" object, but don't create one yourself if you use a language that has already implemented that for you like Scala or Haskell. This type is usually called Either. It should throw an Exception if it ...


1

It's not uncommon to do what you described. In fact, when you create a new database for your user, you basically creating a new file for that user. So, it just adding a file to the set of per user files. The choice of when to do the work begs explanation though. Doing the sign up process in batch periodically can create load spikes on the servers. It's ...


1

The biggest change is that the web front end (the part that runs in the browser) has gotten more sophisticated. There are many frameworks that provide enriched functionality at the client; Angular is just one of them. You can look here to find out more about what frameworks are available and what functionality they provide. There is the notion of a Single ...


1

If I may rephrase your question, you are asking "what happens to my system if something breaks?" Well, the short answer is that your system no longer functions properly. This happens all the time in complex systems. The degree to which you experience degraded functionality will depend upon what broke and how important it is. For example, when the space ...


1

Writing a NetworkClient specifically for the Core class does cause a dependency. Alternatively you can create an integration layer that abstracts the interaction of the two. For the sake of argument, call it a Service. The Service is neither implemented in the Core or NetworkClient. Typically the Service has knowledge of transporting a resource (e.g. some ...


1

Advantages: The display knows nothing about the business logic. You can't display something you know nothing about. Trying to invert control so the business logic calls some sort of display API just turns part of the business logic into display logic and intertwines the two. Then your business logic will break if the display API or display logic ever ...


1

When faced with a similar challenge several years ago, I went with DocBook. There were translators available for generating PDF, Word, HTML and other output formats. I had a number of difficulties with this approach. DocBook itself is very much oriented to producing books. Other document types are a specialization, but you need all the cruft. No such ...


1

You might want to consider using a noSQL database for this specific data. This way you can just put your object in a record, no matter what the 'columns' are. Depending on the chosen database system (and implemented solution), you would be able to 'overwrite' a record with different data if you want. Of course, you can also save your historic data and just ...


1

Determine a master responsible for each piece of data It seems very odd that both applications would need to change the same data. Instead, can you divide the data between the two applications so only one of the applications has the responsibility to change a specific piece of data? For example, the call center application itself could handle changes to the ...



Only top voted, non community-wiki answers of a minimum length are eligible