title: why are transaction monitors on decline? or are they?

text: http://www.itjobswatch.co.uk/jobs/uk/cics.do http://www.itjobswatch.co.uk/jobs/uk/tuxedo.do Look at the demand for programmers (% of job ads that the keyword appears), first graph under the table. It seems like demand for CICS, Tuxedo has fallen from 2.5%/1% respectively to almost zero. To me, it seems bizarre: now we have more networked and internet enabled machines than ever before. And most of them are talking to some kind of database. So it would seem that use of products whose developers spent last 20-30 years working on distributing and coordinating and optimizing transactions should be on the rise. And it appears they're not. I can see a few causes but can't tell whether they are true:   1. we forgot that concurrency and distribution are really hard, and redoing it all by ourselves, in Java, badly.   2. Erlang killed them all.   3. Projects nowadays have changed character, like most business software has already been built and we're all doing internet services, using stuff like Node.js, Erlang, Haskell. (I've used RabbitMQ which is written in Erlang, "but it was small specialized side project" kind of thing).   4. BigData is the emphasis now and BigData doesn't need transactions very much (?). None of those explanations seem particularly convincing to me, which is why I'm looking for better one. Anyone?


title: "Accept the human condition" is one of lean software development values. Can you elaborate?

text: The Lean Software and System Consortium 2011 conference, which took place last week, stated the vision and values of lean software development. Here are the six values of lean software development as photographed by one of the attendees. Number 1 is " **accept the human condition**." While I can sense the humanistic and maybe even anti- _Taylorist_ mood in this statement, I'd like to ask the experts to explain this principle and how to apply it in our daily work.


title: Does it make me a bad programmer if I dislike the Agile methodology?

text: I like the small iterations. I like the unit tests. I like code review. What I don't like is the starting off with little or no documentation. Am I alone in this? Do I simply have a misunderstanding of the process? Any thoughts would be appreciated.


title: Why do people disable JavaScript?

text: I asked a question yesterday Should I Bother to Develop For JavaScript Disabled?. I think the consencus is: Yes, I should develop for JavaScript Disabled. Now I just want to understand why users disable JS. It seems many developers (I guess people who answered the questions are developers) disable JS. Why is that. Why do users disable JS? For security? Speed? or what?


title: License for academic use only?

text: I'm developing a software package and would like to make it (and the source) available for personal, academic, or educational use, but _not for commercial use_. Is there such a license? Ideally, it should be reciprocal, so that if someone publishes a modified version, they'll have to grant the same rights. Alternatively, would it be possible to modify the GPLv3 in such a way that it forbids commercial use and grants rights only to non-commercial users?


title: Offline data transaction processing capabilities in a context of poor internet connectivity

text: We have a core banking product developed with ASP.NET with C# using Microsoft SQL Server 2008 database. Product is hosted on a centralized server and works well at all locations (bank branches) where connectivity is good and stable. We need to implement this solution at a region where connectivity is always an issue. Since it is a core-banking solution, there should not be any service lapse to the customer because of technical issues (viz., connectivity). How to design the architecture for this and ensure that there is no transactional issues at any given point of time, and at the same time the centralized database contains the latest data from all branches?


title: Am I approaching learning Java correctly?

text: (Originally Posted on Stackoverflow) I'm sorry if this question is not appropriate for stackoverflow, I know this is not a technical question, but I feel like it is relevant. I have always been interested in programming, I have messed around with many programming languages and different game engines, making simple apps and things like that. I have been doing Java for a little over a year. Because of school, I did Java mostly on-and-off. I would do it for a month or so then pick up 6 - 8 weeks later... anyway, my point is I know the basics of Java quite well. This is because every time I jumped back into java, I would always recap from the beginning. I understand I know hardly anything. That being said I really want to learn more about the language and get better at it. I am tired of doing System.out.Print() statements, I feel like I have done almost everything I can do with them. I have also done basic work with GridLayouts and Swing. Since school is out I have been doing a lot of Java, at least a few hours a day. I have been following along with these tutorials. http://zetcode.com/tutorials/javagamestutorial/ The first 3 or so tutorials I completely understand, but after that it gets a bit difficult. I am not here to ask a specific question about code. But I would like to know the opinion of an experienced Java programmer. Am I approaching this the correct way? What is the best way to learn the most Java? I feel like it's gotten to the point in the tutorials where I am not befitting from them like I was in the beginning. Should I stick with what I am doing? Attempt to memorize the code? Could someone point me to somewhere else that I could learn? I have never taken a class on programming, I will be a senior in high school.


title: Why do large websites use different languages for the backend and frontend?

text: My understanding from small MVC applications is that you have the front end, which deals with HTML, JS, jQuery, etc, and you have the back end, which consists of your controllers and models. However, when I talk to developers from large companies, they often mention having a frontend tier and a backend tier. So sometimes, I might hear that they have a frontend with C# and a backend with Java. Why would any company want a backend and frontend in different languages? Does this help the large website scale better? When people say that their frontend is built in C#, does this mean that they are using a framework for the frontend (like .NET) and an additional framework on the backend (such as Spring)? Or does it mean something entirely different?


title: Is sending password to user email secure?

text: How secure is sending passwords through email to a user, since email isn't secured by HTTPS. What is the best way to secure it? Should I use encryption?


title: Should web service response use a base class or generic class?

text: In my RESTful WCF web service I have something like the following response object.               public class WebResponse<T>     {              public bool Success { get; set; }             public T Data { get; set; }                 public string ErrorMessage { get; set; }     }          This way I can capture any errors that occur during the request to the web service. It also separates the data object from the response object. Another way this could be done is with a response base class like this.               public abstract class WebResponseBase     {             public bool Success { get; set; }             public string ErrorMessage { get; set; }     }          public class CarResponse : WebResponseBase     {             public string Manufacturer { get; set; }             public string Make { get; set; }     }      I personally prefer the first method as it gives me a clear separation of the data and the response/error status and allows me to easily return lists/arrays etc. without having to create multiple classes. Are there any benefits to using the base class? Are there any limitations to using the generic class?


title: Effective implementation of "array" of type Int X String -> String in .NET or in general

text: The question in general is: is there a more effective way of implementation of table with structure like `Dictionary<int, Dictionary<string, string>>`? The reason I am asking this is because I have made few performance tests and it does not perform well for data with > 5M rows. Now, I dont really need this amount of data but I was wandering if there is a more effective way. It could also help performance for smaller tables with thousands of rows. Last but not least I am interested in what _COULD_ be done to improve it. What I have thought of is to use string[][] and have some method transform string rows/column to numbers. That would however require a quite significant rewrite of my work so far. Is there something simpler? I need rows to be able to handle gaps. Background on my project: I have a home brewed structure of objects that represent a table along with some additional functionality that I need. I have table called T, and it stores data (rows) in `Dictionary<int, TRow>`. Each TRow has another `dictionary<string, TCell>` that represents the row data, in which TCells are indexed by column names. TCells is basically a wrapper around simple string. Table and each row has a Schema definition (column -> {INT, DOUBLE, STRING, BOOL, ...} that is parsed when getting data from the table by methods like .getBool( int row, string column ) etc. Each object (T,TRow,TCell) has quite a lot of helper methods that I use, so they are not a simple wrapper with get methods. EDIT TO ANSWER FOLLOW-UP QUESTIONS: The table is meant for general purpose. No special focus on reading/writing only. The table is often initially loaded from result-set produced by stored procedure in database and then only read from - but not exclusively. The composite key is an interesting idea, but that would break my T, TRow, TCell structure I am afraid. The Dictionary INT X STRING -> STRING is only a simplification, as written in my last paragraph the table T has Dictionary< int, TRow> and TRow has Dictionary< string, string >. The reason I need to keep Table, Row and Cell broken up is that sometimes I work directly with rows, e.g. some method can return a single row etc. Any ideas please? Or there is nothing better :/.


Does the structured programming definition only consider imperative programming? By this I mean does the definition of structured programming automatically exclude functional programming (in the most common usage, by which I mean not necessarily pure-functional programming, but something like Clojure). Structured programming, at least from the definitions that I've found seem to really be saying: "good programming shouldn't use goto, and should be modular". Which doesn't necessarily exclude functional programming, while most definitions seem to begin with "... is a subset of imperative programming". I'm looking for a bit of clarification I think. BTW, I have read "What's The Difference Between Imperative, Procedural and Structured Programming?" which is a pretty good historical description.


title: Best Practises in Android Resources Naming

text: There are a lot of android resources types: layouts, strings, drawables and so on. I understand that readability of it's names is important but can not create a table of rules how to name them in the best way. Are there any best practices on that?


title: Simple way to deploy Winform application to website

text: First of all, I know there is no perfect answer to my question. It is a bit personnal, but I'm sure many programmers face the same dilemma when they get from regular desktop applications to client/server web applications: what is the "best" language/framework to use? There are a lot of great solutions out there, all having more or less the same advantages and features. So, I would like an advice based on my needs and background. I'm fairly experienced with VB and PHP, and I have some Javascript and C# knowledge. I currently have a perfectly functionnal C# Winform app that I would like to deploy to my website. The application uses the user's webcam to recognize a game card through a perceptual hashing algorithm and displays details of the best matched card from a MySQL database. Here's how I'd like the web version to perform:   * the server sends a recordset of the whole datebase's cards ID/hash matches to the client   * the client "scans" his card with his webcam and creates a hash   * the client searches for a match between this hash and the ones in the recordset   * the client returns the best match to the server   * the server displays information of the card from the database My objectives :   * limit (if possible) the need for the user to install 3rd party software (flash, java, activex or other plugins)   * create a solution that integrates well in a Windows/Apache/PHP environnement   * create a solution that is, ideally, cross-platform   * using a language/framework combination on which it's simple to write, debug and maintain code So far, I'm eyeing Python on Eclipse or Javascript on Visual Studio. I read interesting stuff about Ruby on rails, but the learning curve might be a bit steep for me. I don't mind learning a new language and coding the app again from scratch, but I'd like as much as possible to use the skills and code I already have. Any thoughts? Thanks!


title: Is c# actually a multiplatform language?

text: C# (and the .net platform in general) is looking like it's becoming a good option form multi-targeting apps :   * official MS .net framework : full blow windows development, asp.net dev, Windows phone Dev, etc.   * mono and all its derivated : monotouch, monodroid : the rest of the world. This tools are today RTM.   * Does it means that C# is becoming a good language for targeting the most popular platforms : desktop, web and mobile ?   * Is it still better to use the "native" language of target platforms (objective C, Java, etc.)   * Is it only a screen of smoke and only marketing language ? Please note that I'm actually conscious I won't able to copy/paste the code between platforms. But I'm sure the lower layers of applications (models, business, etc.) can be reused, but I know I'll have to adapt the higher layers (Gui, etc.) to the platform. My goal is more focused on required skills than technical code sharing. [edit] I **am** a c# developer in a company that massively use c#. That's why I talked about c# in a plan to expand the range of target platforms in my company.


title: find second smallest element in Fibonacci Heap

text: I need to describe an algorithm that finds the second smallest element in a Fibonacci-Heap using the Operations: Insert, ExtractMin, DecreaseKey and GetMin. The last one is an algorithm previously implemented to find and return the smallest element of the heap. I thought I'd start by extracting the minimum, which results in its children becoming roots. I could then use GetMin to find the second smallest element. But it seems to me that I'm overlooking other cases because I don't know when to use Insert and DecreaseKey, and the way the question is phrased seems to suggest I should need them.


title: Should I allow my client to self host?

text: I'm just starting out as a web designer. I'm trying to build up a portfolio for my own website. I'm concerned about designing a site and handing it over to the client. Once I do this I could lose access to the site. They can change the login information and they may not need to me manage it. If the client changes anything on the site that compromises my design work, it will reflect my business. My business' name will be on the homepage of the website. Is this a valid concern?


title: What will be the better way to access information from another object

text: I have a `page` Object, which has `Paragraph` and `Image` object Collections And each `paragraph` has only `image_id(s)` that are assigned to a paragraph. All other information about image is stored in `Page->Image` Now from the `paragraph` object I want to access the `image` information where paragraph has only `image_id` and all other information about the image is in `Page->Image` object. What will be the better way to access this info? Should I pass the `page` object in every `paragraph` constructor or something else? I also can't change the class structure, as it is written by someone else.


title: How do you do technical interview when you can't commnicate with the interviewer?

text: I just had a developer technical interview last night. As similar to so many technical interviews, it ask me to solve and implement an algorithms within a period of time (1 hour). But when interview begin, he start with introducing his life and to long 13 years career life for like 15 min or more (1/6 of my problem solving time gone). Then I notice I really having troubles understanding his English, thus every question or explanations he said, I have to repeatedly ask him to repeat and explain many times. Turns out he gave up explain one question and ask another one. At the end it turns out I couldn't have enough time to do the algorithms implementation even I got the concept to implement. I did tried to briefly explain how my concept and implementations should be, but at the same time I really concern is he really understand my explanation(English). I feel I am pretty much fail this interview, but I don't want to repeat this situation again. So what will be the best way to get him communicate properly with me, so it won't waste so much time to repeat the same explanation? And not letting him think I have no idea how to implement the algorithms? A side question, how can I cut his long introduction?


title: C++, how many years experience?

text: As a little background, I've been programming for a long time now using various languages, systems, etc. I've come across the old problem of a recruiter wanting to know "how many years experience" I have of C++. I'm a little stumped as I've bounced around it many times over a number of years. I don't think I can just add up the months/years. I'd put myself somewhere around the 3 - 5 year mark. I know it's a bit of a wide range, but I'm not really sure, with newer standards and libraries, the older stuff probably becomes deprecated. So, I wanted to ask your opinion. What would you expect a C++ programmer with (i) 3 years, and (ii) 5 years experience (mainly on Unix/Linux systems) to be able to do? Perhaps, more importantly, what would be the difference you would expect to see between a programmer of 3 years compared to 5 years (and above)? I know this is all a bit vague and the correct answer is, "it depends". But if anyone has a good opinion, I'd love to know.


title: Shared hosting for a PHP application

text: I was reading Essential PHP Security and chapter 8 talks about problems with hosting your PHP app in a shared hosting environment. Some of the problems he mentions are: **\- Exposed source code and File system browsing.** > a web server must be able to read the source code in order to execute it. > Since the web server is shared a PHP script written by another developer on > the server can read arbitrary files. An attacker can also create a script > that browses the file system. **\- Exposed session data and Session injection.** > By default, PHP stores session data in /tmp which is writable by all users, > so Apache has permission to write session data there. A simple script can > allow other users to read, add, modify, or delete sessions. It's like everything is exposed and vulnerable if I used shared hosting this way. My questions:   1. Considering the book was published 8 years ago, are they problems still occurring or were they mitigated somehow in the last few years?   2. Why would one opt for shared hosting if it going to cause these huge security concerns?   3. I understand that shared hosting is cheap, but there must be a safer alternative to it and cheaper than dedicated hosting?   4. In case a customer ask me to develop an application that will be hosted on a shared hosting, is there a full proof way to develop a secure application or is it just a recipe for disaster?


title: Calculate reachability of one point from another

text: I have an array which stores a set of positive x coordinates in sorted way, say `arr={1, 4, 5, 9, 12, 45}` etc. And I have a maximum distance `k` which I can go from one point to another point let `k=3`. Now, given two points `x` and `y(arr[x]<arr[y])` I need to determine if I can reach from `x` to `y`. I will be able to reach `y` from `x` if distance between every two hop is less that or equal to `k`. Here suppose `x=1 y=4` then I can go from 1->2 then 2->3 but since distance between 3 and 4 is greater than 3 I can't go so in this case I can't reach. But if `x=1` and `y=2` then I can reach. It can be simply solved with O(n). I have created a for loop from `arr[x]` to `arr[y]` and for each pair of points I check if distance between them is less than or equal to `k`. But I want better algorithm. I am thinking of doing something like binary search. Can anybody please suggest a good algorithm?


title: How to improve the code writing effort?

text: Code needs to be written to file, on way or another. While all programmers should strive to write no more code than necessary, this "small" portion needs to be written nevertheless. What tips do you have for improving the code writing effort? Usage of IDEs? Different keyboards or character layouts? Minimal usage of mouse? Code generation tools? What else can you think of?


title: Is Java Plug-in still relevant?

text: When I challenged Chrome development team about their decision to block every version of the Java Plug-in by default (http://code.google.com/p/chromium/issues/detail?id=84001). They answered that Java Plug-in is not widely used anymore. Google is also officially stating this: https://www.google.com/support/chrome/bin/answer.py?answer=1247383&hl=en-US. I'm aware that Applets as a tool for design purposes (banners, menus, etc) is outdated, and I must admit that it has been a while since I developed something serious that used the Java Plug-in (I had some fun with JavaFX and Web Start draggable applications for learning purposes, but that's pretty much it). Still, Java Plug-in accounts for a important part of my surfing experience (I'm the sad type of grownup still playing games such as Runescape. My bank use a Java Applet for the security keyboard and several sites I often visit uses Applets for things such as file uploading and authentication). My question here is: Do you guys think that client-side Java web applications are still relevant? Please disregard Desktop and Server Side applications... We all know how popular Java is (http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html). This question is specifically about Java Plug-in.


title: Why is it so hard to recruit for compiler[-related] jobs?

text: Last week, a few colleauges and I were participating in career fairs at three major universities (two here in the US and one in England), where we were trying (without much success) to recruit for several compiler positions, ranging from internship, to entry-level, to more senior, for our team. To our surprise, 80% of the students that we talked to responded somewhere a long the line of "I want to build Ansroid apps", when asked what they were interested in doing. (And the other 20%? "iPhone apps"! ) Some even expressed openly that they did not "want to build a compiler, ..., it's boring"; they said and I quoted. So what is it about mobile apps that is so appealing to (young ?) "developers" these days? And by the same token, why is compiler such a"boring" topic to them? ( I don't necessarily think these two are mutually exclusive. One can certainly build a compiler for a mobile phone, but that's beside the point) What can we do, if anything, to attract more talents, or even just interested candidates?


title: Is it good to have an interface plenty of methods which belong to different concepts, just to preserve the Liskov's Principle?

text: I'm currently studying a course based on Software Design and I had a discussion in class with my professor and some classmates about a problem represented by the next scenario: **Scenario** > _Imagine we have a graphic application which lets us plan the interior > design of our future house using a perspective from top. We are able to add > or remove some elements like furniture and change their position, but > obviously, we can't move the walls of the house because it was already > built._ **Solution 1** To solve this problem, some of my classmates proposed a solution that could be expressed using the following UML diagram: ![UML diagram for Solution 1](http://i.stack.imgur.com/nV7Ne.jpg) As you can see, they agreed on the use of a common interface called "Drawable" which represents the graphical objects displayed on the UI. The general class "App" manages a list of Drawables, and each of them has a set of methods. This interface is implemented by different classes such as Furniture, Wall or Window. The thing is that a Furniture object could be moved, but not the Walls nor the Windows. So, a Furniture would implement the 'move' method defined in Drawable. In contrast, Wall and Window simply will write it empty. At this point, other classmates and I complained about this decission because the design does not require to fulfill with the constraints (like moving or not Drawable objects, depending on their nature). This way, the design will allow some new objects could be moved, although they probably shouldn't be. However, the professor said this design is good because it's flexible and transparent for the App class, because this class doesn't know what kind of instance is managing. _Extended case_ In addition, we could think on an extreme case where we add several methods to the Drawable interface, such as 'sell', 'open' and 'lend'. Using the same approach described above, we will have an interface which could be able to do anything, like Superman. Therefore, I believe this is a bad design solution due to we are mixing behaviors which belong to different concepts (Movable, Sellable, Openable, and so on). Also, we are allowing a Wall object could implement the 'sell' method, which completely does not make sense... but my professor still insisted on his point of view and he didn't see the problem. **Solution 2 (based on the extended case)** Other people suggested we could add those interfaces (Movable, Sellable, Openable) and each of them would inherit from the Drawable interface. That way:   * A Wall would implement Drawable directly   * A Furniture would implement Movable and Sellable   * A Window would implement just Openable The next diagram summarizes this approach: ![UML Diagram for Solution 2](http://i.stack.imgur.com/xvqVi.jpg) [Edit: The Drawable's move method should be removed, this is a mistake because it is now placed into the Movable interface] **Questions and Doubts** Finally, once you can figure out the problem, could you help me and answer these questions, please?   1. Aren't we breaking the _Single Responsibility Principle_ with this super-mega-god-interface?    2. Are both approaches valid against the _Liskov's Substitution Principle_? I think it's broken in the first case because the post-conditions are broken due to some methods don't do anything. Anyway, in the second approach I'm not sure as well because of the interfaces inheritance tree   3. Maybe, another alternative could be the definition of basic Drawable objects (with 'click' and 'draw' methods). Thus, we may take advantage of some kind of mechanism like the Decorator pattern in order to add behaviors dynamically. But how?   4. If we use a language without interfaces such as JavaScript or Python, how can we deal with this problem?


title: How can I prepare for an interview over TeamViewer and Skype?

text: I am in big dilemma what to do or not... Tomorrow have an interview on TeamViewer and Skype for a web developer position in PHP. They want to take my technical interview there, so I think they will give give me a PHP program to write. The thing is that PHP has vast variety of functions so its not possible to keep all the functions in mind or on finger tips: Google is really needed. I am aware about how to solve problems, but it may be the case that I don't know the exact syntax for questions they ask. So what should I do in this case? How can I convince them that I know how this can be accomplished but the exact syntax is not coming immediately to mind? Also, what type of question might they ask? _Some thing about me so that may be you can give your advice accordingly_ Am a junior web developer who has 14 month experience in PHP. My skills : PHP, Mysql, Magento, Wordpress, CSS, HTML, Javascript...


title: Matrix Pattern Recognition Algorithm for a 2D space

text: I have a picture that I elaborate with my program to obtain a list of coordinates. There is a matrix represented in the image. In an ideal test I would get only the sixteen central points of each square of the matrix. But in actual tests I have some noise points. I want to use an algorithm to extrapolate from the list of the coordinates the group formed by 16 coordinates that best represent a matrix.   * Example of found points:   ![](http://i.stack.imgur.com/HhriV.png)   * Example of desired result:   ![](http://i.stack.imgur.com/WfCHq.png) How to do this? Note: The matrix in the image can be rotated a little too, so a rotation- independent algorithm would be great.


title: What did Rich Hickey mean when he said, "All that specificity [of interfaces/classes/types] kills your reuse!"

text: In Rich Hickey's thought-provoking goto conference keynote "The Value of Values" at 29 minutes he's talking about the overhead of a language like Java and makes a statement like, "All those interfaces kill your reuse." What does he mean? Is that true? In my search for answers, I have run across:   * The Principle of Least Knowledge AKA The Law of Demeter which encourages airtight API interfaces. Wikipedia also lists some disadvantages.   * Kevlin Henney's Imperial Clothing Crisis which argues that use, not reuse is the appropriate goal.   * Jack Diederich's "Stop Writing Classes" talk which argues against over-engineering in general. Clearly, anything written badly enough will be useless. But how would the interface of a well-written API prevent that code from being used? There are examples throughout history of something made for one purpose being used more for something else. But in the software world, if you use something for a purpose it wasn't intended for, it usually breaks. I'm looking for one good example of a good interface preventing a legitimate but unintended use of some code. Does that exist? I can't picture it.


title: I'm having trouble understanding these exercises wording

text: Exercise 1-20. Write a program detab that replaces tabs in the input with the proper number of blanks to space to the next tab stop. Assume a fixed set of tab stops, say every n columns. Should n be a variable or a symbolic parameter? Exercise 1-21. Write a program entab that replaces strings of blanks by the minimum number of tabs and blanks to achieve the same spacing. Use the same tab stops as for detab. When either a tab or a single blank would suffice to reach a tab stop, which should be given preference? could you paraphrase these for me. thanks


title: Tuple: toople or tuh-ple?

text: I hear it's another Europe vs. America dispute, just like with "router". Some other time I hear tuh-ple is specific to Python (and possibly some other languages too) while in mathematics and CS it's "toople" on all continents. What do you know about this?


title: Have unit test generators helped you when working with legacy code?

text: I am looking at a small (~70kLOC including generated) C# (.NET 4.0, some Silverlight) code-base that has very low test coverage. The code itself works in that it has passed user acceptance testing, but it is brittle and in some areas not very well factored. I would like to add solid unit test coverage around the legacy code using the usual suspects (NMock, NUnit, StatLight for the Silverlight bits). My normal approach is to start working through the project, unit testing & refactoring, until I am satisfied with the state of the code. I've done this many times in the past, and it's worked well. However, this time I'm thinking of using a test generator (in particular Pex) to create the test framework, then manually fleshing it out. My question is: have you used unit test generators in the past when commencing work on a legacy codebase, and if so, would you recommend them? My fear is that the generated tests will miss the semantic nuances of the code-base, leading to the dreaded situation of having tests for the sake of the coverage metric, rather than tests which clearly express the intended behaviour in code.


title: Best Development Methodology for One Person?

text: I spend a lot of time working on projects in which I am the sole developer, project manager, designer, QT person (Yes, I know... Bad!), and sometimes I'm even the client. I've tried just about everything for planning projects and managing myself, from just sitting and working freestyle until the project is done however long it takes, to a single-person version of scrum in which I held a progress meeting with myself over a one-man burn down chart every morning (not kidding). For those of you who spend much time working alone, what is the best way to organize yourself, manage large (for one person) projects, and keep productivity as high as possible?


title: Design and Development Methodologies for the single developer

text: At my work, typically the developers here all work separately, we may share projects but often only do so when another isn't working on it (for reference, we're a consulting company. So someone may work on project A one month, then three months late, I may too). What methodologies can we use to improve the quality of the code we produce when there is typically only one developer (at most three) on the project?


title: How to manage the whole project while you are the only resource

text: It's frustrating to handle the whole Project/manage the project while you being the only developer/coder/Programmer in the Project. How can we handle the project? Are there any steps to follow to complete the project with the limited given time?


title: Development methodology for single web developer?

text: > **Possible Duplicate:**   >  Design and Development Methodologies for the single developer I'm a web developer who mostly works with the LAMP stack when it comes to my own projects. Most of the time I just start coding on a project and fixing bugs and adding features as I go along. Often I'll try to use an existing solution such as Wordpress or Drupal. Now that I'm thinking of creating my own web application with businesses as the target group, I feel there's a **need for proper analysis and design**. Something lightweight for a **one person project** and still solid enough to handle requirements, user interfaces, security, etc. If you could **recommend methodologies and literature** I would be grateful.


title: Encrypt and decrypt password for a specific application

text: I have a basic web application where users can login and edit their profile. In the profile they can submit an username and a password for a different application. I'd like to take that password and encrypt it. Later, when I want to connect to that different application I need to decrypt the password. Is there a common pattern for this scenario? Or some other advice you might have? Just in case it matters, I want to connect to JIRA without having the user have to submit his password on every request / login to the page. Thanks, Sven **Update** To make it more clear, I have a web appliction where users can signup/login/etc, this uses a authentication/authorization library (friend) and its all well. However, from my webapp I want users to connect to a jira instance that they can choose and where they have to provide a username/pw combo which I cannot hash, because I need to send them unhashed to the JIRA instance. What I am thinking of right now is to display a login dialog to the user as soon as he wants to request his JIRA instance. There he provides his username/password combo for JIRA and I send a REST request to JIRA from the client side, so no user/password is sent to my server. I get a sessionid back then, which I can use for further requests. What do you think about that approach?


title: Unit testing, factories, and the Law of Demeter

text: Here's how my code works. I have an object that represents the current state of something akin to a shopping cart order, stored in a 3rd party shopping API. In my controller code, I want to be able to call:               myOrder.updateQuantity(2);      In order to actually send the message to the third party, the third party also needs to know several things that are specific to THIS order, like the `orderID`, and the `loginID`, which will not change in the lifetime of the application. So when I create `myOrder` originally, I inject a `MessageFactory`, which knows `loginID`. Then, when `updateQuantity` is called, the `Order` passes along `orderID`. The controlling code is easy to write. Another thread handles the callback and updates `Order` if its change was successful, or informs `Order` that its change failed if it was not. The problem is testing. Because the `Order` object depends on a `MessageFactory`, and it needs `MessageFactory` to return actual `Message`s (that it calls `.setOrderID()` on, for example), now I have to set up very complicated `MessageFactory` mocks. Additionally, I don't want to kill any fairies, as "Every time a Mock returns a Mock a fairy dies." How can I solve this problem while keeping the controller code just as simple? I read this question: http://stackoverflow.com/questions/791940/law-of- demeter-on-factory-pattern-and-dependency-injection but it didn't help because it didn't talk about the testing problem. A few solutions I've thought of:   1. Somehow refactor the code to not require that the factory method return real objects. Perhaps it's less of a factory and more of a `MessageSender`?   2. Create a testing-only implementation of `MessageFactory`, and inject that. * * * The code is pretty involved, here's my attempt at an sscce:               public class Order implements UpdateHandler {         private final MessageFactory factory;         private final MessageLayer layer;              private OrderData data;              // Package private constructor, this should only be called by the OrderBuilder object.         Order(OrderBuilder builder, OrderData initial) {             this.factory = builder.getFactory();             this.layer = builder.getLayer();             this.data = original;         }              // Lots of methods like this         public String getItemID() {             return data.getItemID();         }              // Returns true if the message was placed in the outgoing network queue successfully. Doesn't block for receipt, though.         public boolean updateQuantity(int newQuantity) {             Message newMessage = factory.createOrderModification(messageInfo);                  // *** THIS IS THE KEY LINE ***             // throws an NPE if factory is a mock.             newMessage.setQuantity(newQuantity);                   return layer.send(newMessage);          }              // from interface UpdateHandler         // gets called asynchronously         @Override          public handleUpdate(OrderUpdate update) {             messageInfo.handleUpdate(update);         }     }


title: Work experience instead of education?

text: I wanted to name this topic as "Education vs. Experience", but this topic already exists. I've read that discussion and though what I'd like to ask is related with that topic, the question is quite different. I've started learning programming about 12 years ago. For the last 4 years I'm working as developer in software outsourcing (located in Russia). I'm thinking about leaving Russia and moving somewhere else like Australia (doesn't matter basically). I have a number of examples illustrating the general ability and success stories, but still there's a difference between all these people and my case. I have quite a good technical experience - primary areas are C++ and .NET. I have already participated in 7 projects based on different technologies/platforms (Windows, Linux, Android, Qt, .NET, etc). So, I believe, _I'm capable_ of working as a software developer. Let's just take it - "from technical standpoint, this guy is absolutely OK". The only problem is, I don't have any education. So, here's the question: **In most cases, may I read words like "BS in CS, equivalent, or better" as "N years of experience"?** **Update** : Is there a sense in getting certificates like MCSD (for .NET)? I know there's a separate topic for this question, but still asking for the case when there's no education but there are certificates and experience.


title: Multilayered enterprise application use of JAXB objects

text: I am asked to refactor and maintain an enterprise application. Normally I'm used to using the MVC design pattern. This time however, I'd like to separate everything into layers (multilayered architecture). Something along the lines of (Microsoft Application Architecture Guide, 2nd Edition - October 2009): ![enter image description here](http://i.stack.imgur.com/Pqqq0.png) My data sources are in general XML files. These files are read and written with the use of JAXB, and this resides in the data-layer. Whenever I load a specific XML a "provider" will use JAXB to construct a tree of objects representing the XML structure. These objects/information needs to be used inside the business, service and presentation layer. Per layer the information needs to be treat differently, i.e. business layer will enforce business rules on the objects/information whereas the presentation layer needs additional UI information to have everything shown to the user. I'm looking for your tips / experiences when it comes down to using data sources throughout an multilayered application. Should I:   1. Create some sort of mapping, such that a new object tree is constructed in every layer?   2. Work via the lines of aggregation, such that my data sources can be decorated with extra functionality / information inside an object that lives in another layer?   3. Make the JAXB-objects "fat", with an interface which supports all my needs that come from all other layers? I'd love to hear your thoughts!


title: What's the name of this category of variables (NEW, OLD, etc) in triggers?

text: I need to do some very specific web search, but in order to do that I need to know what's the technical name of the category/type of variables like NEW, OLD, USER ( the could be more ) that you can access from within a trigger in a RDBMS without having to declare them. The question I want to post is "does `<RDBMS>` support `<xxxx>` variables in triggers ?" but I don't know what to put in the `<xxxx>` placeholder. For example, variables like this `:var` in a query are called _bind variables_.


title: API design and versioning using EJB

text: I have an API that is EJB based (i.e. there are remote interfaces defined) that most of the clients use. As the client base grows there are issues with updates to the API and forcing clients to have to update to the latest version and interface definition. I would like to possibly look at having a couple versions of the API deployed at a time (i.e. have multiple EAR files deployed with different versions of the API) to support not forcing the clients to update as frequently. I am not concerned about the actual deployment of this, but instead am looking for thoughts and experiences that others have on using EJB's as an API client.   * How do you support updating versions, are clients required to update?   * Does anyone run multiple versions in a production environment? Are there pro's cons?   * Any other experiences or thoughts on this approach, and having an EJB centric API?


title: Why Garbage Collection if smart pointers are there

text: These days, so many languages are garbage collected. It is even available for C++ by third parties. But C++ has RAII and smart pointers. So what's the point of using garbage collection? Is it doing something extra? And in other languages like C#, if all the references are treated as smart pointers(keeping RAII aside), by specification and by implementation, will there still be any need of garbage collectors? If no, then why is this not so?


title: Is there a need for garbage collection in a stack-based language?

text: What is the need for garbage collection (GC) in a stack-based language? In a language like Forth or RPL (on HP calculators), is there a need for garbage collection? I would think, since output is popped off the stack, that there wouldn't be any need. Am I missing something?


title: Why not free memory as soon as its reference counter hits zero

text: A lot of languages like Java and C# have garbage collectors that free memory when that memory no longer has any reference. Yet they don't immediately free it after the reference counter hits zero but instead every once in a while they check on all the memory to see if that memory has any reference and delete it if it doesn't. What is the benefit of doing that way? The downside to doing it that way is that you lose the destructor as you can't guarantee when it will be called. I would imagine that it is done that way because of performance, but has there been any study that shows that a garbage collector that works like that has a better performance then `std::shared_ptr` found in C++?


title: Design guidelines for this scenario in C#?

text: I have to create a validation system(I don't want to use Data Annotation or any other system) for my C# application using .Net Compact Framework, where I have an `object` which contains many other objects. Many of the properties are dependent on each other means they have some sort of dependencies. I can write a simple `validator` class which goes through all the properties and checks them one by one with lots of `if and else` but I want to design something dynamic e.g. I should be able to specify list of dependencies on a property and specify a method which should be invoked during validation. I mean some design guidelines would be appreciated ? Example ( just for demo purpose ):                   public enum Category             {                 Toyota,                 Mercedes,                 Tata,                 Maruti             }                  class MyBigClass             {                 public Category Category { get; set; }                 public double LowerPrice { get; set; }                 public double UpperPrice { get; set; }                      public SomeOtherObject OtherObject { get; set; }          public List<string> Validate()             {                 List<string> listErrors = new List<string>();                 ParameterInfo pInfo = null;                 switch (Category)                 {                     case Category.Toyota:                         pInfo = ParameterStorage.GetParameterInfo(PTYPE.Category_Toyota);                         break;                     case Category.Mercedes:                         pInfo = ParameterStorage.GetParameterInfo(PTYPE.Category_Mercedes);                         break;                     case Category.Tata:                         pInfo = ParameterStorage.GetParameterInfo(PTYPE.Category_Tata);                         break;                     case Category.Maruti:                         pInfo = ParameterStorage.GetParameterInfo(PTYPE.Category_Maruti);                         break;                     default:                         break;                 }                      if (LowerPrice < pInfo.Min || LowerPrice >= pInfo.Max)                 {                     listErrors.Add("LowerPrice");                 }                      if (UpperPrice > pInfo.Max || UpperPrice <= pInfo.Min)                 {                     listErrors.Add("UpperPrice");                 }                      return listErrors;             }             }                   public enum PTYPE                 {                     RATING,                     Category_Tata,                     Category_Toyota,                     Category_Mercedes,                     Category_Maruti                 }                      public class ParameterInfo                 {                     public PTYPE Type { get; set; }                     public int Min { get; set; }                     public int Max { get; set; }                     public int Default { get; set; }                 }                 public class ParameterStorage             {                 private static Dictionary<PTYPE, ParameterInfo> _storage = new Dictionary<PTYPE, ParameterInfo>();                 static ParameterStorage()                 {                     _storage.Add(PTYPE.Category_Maruti, new ParameterInfo { Type = PTYPE.Category_Maruti, Min = 50000, Max = 200000 });                     _storage.Add(PTYPE.Category_Mercedes, new ParameterInfo { Type = PTYPE.Category_Mercedes, Min = 50000, Max = 800000 });                     _storage.Add(PTYPE.Category_Toyota, new ParameterInfo { Type = PTYPE.Category_Toyota, Min = 50000, Max = 700000 });                     _storage.Add(PTYPE.Category_Tata, new ParameterInfo { Type = PTYPE.Category_Tata, Min = 50000, Max = 500000 });                 }                      public static ParameterInfo GetParameterInfo(PTYPE type)                 {                     ParameterInfo pInfo = null;                     _storage.TryGetValue(type, out pInfo);                     return pInfo;                 }             }      In the above example I have a `MyBigObject` which contains some properties and some other objects and I have a `storage` class which keeps all the limits of properties which will be required to validate a property. As described in the above example I have to get `ParameterInfo` for each property and then compare, I am looking for some kind of automatic way/dynamic way of doing the same.


title: Why is the warranty disclaimer section of a licence usually (always?) shouted?

text: For example, the templates provided on the Open Source Initiative website for the 3-clause BSD License, and the MIT License both include an all-caps warranty disclaimer, though the rest of the license is written with normal capitalisation. Is there some genuine reason for this? Or is it just a tradition to make the warranty disclaimer harder to read?


title: Choosing a database for a framework with both asynchronous and synchronous calls

text: I'm building a framework to work as an all-purpose astronomy pipeline and before I get too far into development I was hoping to run my needs by you all to see if there are any optimizations or pitfalls I'm missing. This is a long one, so thank you to anyone who takes the time to look this over. My main needs are as follows (in order):   1. Cross platform and easy to install without a lot of dependencies. Most of the astronomers I work with are very good at understanding physics and astronomy but are weaker in programming ability and due to time constraints they are unlikely to adopt a new solution to reduce their data unless it's lightweight and easy to install on their choice of OS. If something looks complicated to install or setup then they will likely look for something else or continue using the decades old software they are currently using. I also like using python since a growing number of people in the astro community are using it.   2. Centrally located on a server. Currently most open source solutions for reducing data sit on the users machine. This means each user in a group must download the same data from the server, wasting disk space and time (often file sizes can be O(100Mb) or more). It also means they have to install and setup a variety of programs written by different people and it can take weeks to get one machine fully configured... until the next software update when something breaks and the procedure must be started again. So I want to use a web based solution where the images will all be located on a server that does the majority of the processing and my application is basically just a UI in a web browser to interact with all the nastiness that is open source astronomy command line software.   3. Ability to run both short and long runtime functions. For example, I have a viewer that converts a fits image into a bunch of png tiles and sends them to the client to be viewed on a canvas. This must be done as quickly as possible. Other tasks will run routines like photometry or data reduction that may take an hour or more, depending on the task and dataset. So it is important to be able to have some routines run asynchronously (like building and loading images) while other tasks are queued (like finding all the bright and isolated stars in a given image).   4. Modular structure. I plan on building a basic UI framework in python that can easily be extended by users. This will allow the community to share more of their code and only install the pieces needed for an individual or groups research. Functions essentially become webpages with an image viewer, instructions, and an interface for parameters to minimize the time it takes for new students to learn to use the software.   5. Small group of users. If there are 10 people using a server concurrently that is usually a lot. But if possible it would be nice to have something that scales up rather easily so that larger projects could adapt this for their needs.   6. Processing on multiple cores. While not necessary, our groups server has more cpu's than members of the group. So it would be nice if each user could log in and have their own core to run their jobs without interfering with other users. So what I have begun to develop is a python tornado server with mongodb solution on the server. Clients connect to the server via a web socket and send jobs to be processed. The job server then runs the routine specified by the client and sends the result to the client, or sends a link if an image or large data file is ready to be downloaded. The database is optional but handy (this is the part I'm implementing now). Typically the image files we deal with contain a header with 100 or so keywords. So when a new set of images is downloaded the user can load the headers into the database (this could be 100's of files). For a number of reasons, the user may want to search the files for any one of the hundred keywords, not just a few key indices. When I dump the header data into a cpickle object it's over 100mb and takes a minute or so to load. I'm hoping that mongodb (or some other db with a python interface) is faster and will allow for multiple users to access the data concurrently, but I've learned that databases can be very different and performance can vary greatly depending on the need. An additional function of the database will be to keep track of user accounts and which directories of images they are allowed to see (for example a collaborator from another university may have access to a set of data taken together while other datasets are for internal use only). One thing I've thought of doing is writing a general db api. Since most of the searches will be fairly simple functions could just call a getFiles routine that allows them to input lists of selection criteria and then the user simply needs to add the correct syntax for his/her particular db in the get function. Perhaps this is overkill, but one of the main things I'm trying to combat is the tendency in astronomy to use outdated code and technologies because no one wants to take the time to update them. My hope is that by making this as flexible as possible it can easily change as new tools are available (such as a better suited web server, database, or even more commonly used programing languages, keeping in mind that many of my collaborators still use fortran 77 code written before I was born). I've also considered running multiple job servers, one for tasks that need to be quickly accessed, and anther for jobs with long run times. But it would be nice to have a single server solution. I've put about a month into building the framework so far and unless there is a very good reason to switch web application servers I'd like to stick with Tornado. It's lightweight, easy to use, and seems to meet all of my needs. I just started looking at databases so I'm much more flexible and open to other options here. Thank you to anyone who has read through or skimmed most of this, any advice you have is greatly appreciated.


title: Better and cleanest way to bind a ICommand to a RelayCommand

text: By reading various source code, I see that there is different ways of binding an ICommand to a RelayCommand :   * From the constructor              MyAwesomeViewModel()  {         this._fooCommand = new RelayCommand((x) => Bar(x))      }        * Directly from the command property              private ICommand _fooCommand ;     public ICommand SearchCommand     {         get         {             return _fooCommand ?? (_fooCommand = new RelayCommand());         }     }      Which way is the better from your point of view ?


title: How to manage memory in C interface for C++ implementation considering c++11?

text: I have a library implemented in C++ which has a C interface. This C interface is, for all intents and purposes, the only way to use this library. C++11 seems to discourage the use of raw pointers but neither shared_ptr or unique_ptr are suitable in this case. From what I understand, intrusive_ptr is an option, but I am both unsure of how this differs from maintaining my own ref count (I am new to C++) and wary of wading into boost yet (I am new to C++). How should I handle memory management in C++11 and higher? I only state the spec to make it clear that I am willing to use the features of the latest spec and have no need to maintain compatibility with older specs.


title: Unit Testing with an Optimization Problem

text: Suppose I'm making an algorithm that identifies the subject of a picture. It could be anything that a computer doesn't do that well, but I'm not expecting to get the right answer every time - 80% is fine. Suppose further, that the accuracy of the intermediate steps was also somewhat fuzzy. Is there a way to incorporate unit tests? The option that immediately comes to mind is to add 1 to a tally and every time a 'test' passes, increment the tally. When that finishes, divide by the total and test 'passes/tests > 0.8', but that seems kludgey. EDIT: Thank you all for your kind words and well-reasoned responses. My particular problem, while fuzzy, has nothing to do with pictures, and I'm currently getting about 80% pass. The short term value for me in a testing scheme would be knowing whether small adjustments were more globally beneficial or catastrophic. Long term testing value should be obvious.


title: Models Views and Controllers jobs

text: First, I know there are lot of answers about MVC but I need some more-specific ansewer based on my probably wrong understanding of MVC. I've already read this very good answer (Explain Model View Controller) but I still need some clarification. I need to understand if I've understood how MVC works because I'm using it in a kind of MVC framework I'm developing.   * I have the views that are at the moment just "stupid" templates    * The models that are "things" that fetch data from database (or other sources) and transform them in arrays passed to the views.   * The controllers that are mostly ajax javascript scripts and observers for buttons and other user events and PHP scripts that are called by the Ajax scripts when I need to perform server-side operations like SQL updates, inserts etc. So my "MVC understanding" makes my app works in this way: I open my index that loads the **viewsloader** (model), this one loads the contents calling the **contentsloader** (model) that calls some other script depending by the view the user is requesting.   Then when all the data is loaded in a single array, the **viewsloader** (model) uses it to render the requested view and passes it to the user. Now the user can click some button (for example a "view contacts" button) and under the hood my **contactslistener** (controller) calls the **contactsloader** (model) to load the contacts list, the array provided by the **contactsloader** (model) passed trhough the **contactslistener** (controller) which injects it in the view. * * * I think I have serious problems with the MVC model, looks like the **controllers** are doing too different things. Probably I should put the observers/listeners in the **views** part and use **controllers** just to load contents provided by the **models**.   * Are the **models** dedicated just to data fetching and organization (for example, fetch from database and put it in array organizing it with the right structure)?   * Are the **controllers** thought for handle user events or should I use **views** for this purpose? Should I use them to query the **models** and inject the answers into the **views**?   * Are the **views** just stupid templates or should I put there some business logic like event listeners? Following what I've read I should put the entire interface-side scripts here and put only (client/server)-side scripts in controllers. But in this case I've not idea about what a controller should do...


title: Multi-level paging tables

text: Referring to the image here: ![http://en.wikipedia.org/wiki/File:X86_Paging_4K.svg](http://i.stack.imgur.com/B5cyA.png) From http://en.wikipedia.org/wiki/File:X86_Paging_4K.svg Could somebody please explain something for me? I don't get exactly how this works. As I understand it the page "directory" contains an entity which essentially points to the beginning of the "page table". However, surely all of the entities in the page "directory" would contain the exact same value? Or, does this mean we have 1x page "directory" but N page "tables" (at the same level in the page multi-level hierarchy")? If there are N page "tables" and one page "directory" I get why the PD would point to one of the N PTs. If there aren't then I am really confused.


title: Confused in NoSql data model

text: I've a web application uses `MongoDB` as primary database. This is the first project I do with a NoSql db, I'm trying to create the application model but I'm confused. I know NoSql are non-normalized and it is normal to replicate data avoiding joins (that are not supported) but I'm now thinking at this scenario: I have the `User` class containing email address and the user can change it in the profile page. This email address is displayed in few pages in different environments and I think the right choice is to embed this property in few class documents (ex.: product subscription, invoice, shopping cart, ... ). What if the user change his email address? Have I to trigger multiple updates to change every collection, every document embeds this property?


title: WPF Control Lifeycle and Navigating through Containers to set Focus

text: I wanted to understand a control's lifecycle in WPF. Let me explain my scenario: I have a complex screen containing various container controls hosting forms. Let's say my screen has 3 Accordion Items. In the first Accordion item, I have a TabControl and this TabControl has 4 TabItems. Each TabItem has various Forms containing label-value pairs such as checkboxes, comboboxes, textboxes, RadWatermarkTextBoxes etc.., Now, the user introduces an error in one of the TextBox present in AccordionItem#1 --> TabControl#1 --> TabItem#1 --> TextBox#1 (for example) and then he/she switches over to TabItem#2 within the TabControl#1. Now, when the user switches over to TabItem#2, does the TextBox#1 die? Is it recreated again, when I expand TabItem#1? What exactly happens when a container is collapsed and how can I set focus to an element which is not existing in the view anymore? Let me explain it further in detail ... Now, let's say, the user has introduced various errors in different forms of the TabItems. and has now come out of the AccordionItem#1 and entered into AccordionItem#2. There are lots of errors (the user knows that and would like to correct them later by navigating to them). After finishing all the form filling in all the accordions. He starts looking at the errors before saving. The user needs to navigate and to do this, we have an icon and clicking on this icon, will take us to the next erroneous field, which means I need to automatically open the AccordionItem#1 --> TabControl#1 --> TabItem#1 --> TextBox#1 and set focus to this control, so that the user can start editing it. When the user finishes correcting the error in this field, he/she presses the icon again, and I need to automatically open AccordionItem#2 --> TabControl#2 --> TabItem#3 --> TextBox#4 for example. All these were previously collapsed as we were in AccordionItem#1 previously?! So, I wanted to understand, if something like this is possible or not? I was wondering what kind of a pattern will help us achieve this kind of functionality. When I find an error. Can I store a reference to this element(using its GUID - i.e. x:Name value) and when user clicks on the next error, then raise an event on it, which will propogate up the visual tree letting the parent tab handle it, passing it further and on till I reach the highest level and then pass another event down the line so that each of these parents can then expand themselves come into view and finally setting focus to the errorneous control? Is something like this possible? It is an interesting scenario and probably many developers might have encountered an issue like this when designing and developing huge applications.


title: Tips and recomendations for a phone interview

text: A while ago I asked this question, I got very nice results but now I have a similar situation, but I'm looking for advices and I want to know if you think is possible to tell if you want a developer only with a phone interview. Let's say that you need to perform an interview to a candidate which is not on your country, so in case you'd hire him/her you'd have to provide a relocation package, wait for him/her to get the whole work permit in order and all those stuff, so you'd need to make sure that this person is quite worth it. Let's say that the candidate is applying for a junior developer position as a C#/ASP.NET developer with a small / medium software development company.   * Can you tell in a phone interview if you'd like the candidate?   * Any recomendations for the candidate to impress the interviewer?


title: Career with PeopleSoft

text: I have 3 years of experience writting applications with Java. I am doing my Master's now. Last year, I started working with PeopleSoft systems for my university. I am considering it as my career path from now on. I am trying to determin what thee pros and cons for it would be.


title: Any recommendation to manage an investigation projects?

text: I'm working on an investigation on the NLP field. Since software engineering and software documentation are not the primary concerns of my whole investigation I decided to do it using XP. My question is, can you recomend:   * Any tool you've used to manage XP projects   * Any recomendation/link on how to manage investigation projects I'm very biased with XP because I've used it before, but if anyone has a better methodology you can post it as well


title: Does the expansion of new technologies cause a perceived shortage of skill?

text: Systems programming and desktop application development is a well established field. In recent years, web and mobile development have shown rapid expansion. As a software engineer I understand that _programming is programming_ , and C++, Javascript, and Android APIs are tools that any engineer worth his salt can handle. Unfortunately, there exist recruiters, managers, and companies that don't understand that skill isn't necessarily tied to tools. Also, some companies just aren't interested in providing the ramp-up time required when hiring an engineer with little direct experience with a software tool that is used by their existing development team. Does this combination of increasing demand for applications built with recently established tools/platforms and recruiter/HR figures' juxtaposition of _programming_ experience with _tools_ experience cause a (albeit arguably incorrect) perceived shortage of skill applicable to new technologies? To phrase it differently, given two similarly talented engineers, is the one doing C++ application development less valued in the market than the one with some web applications under his belt?


title: Creating controls dynamically in the code-behind or ViewModel?

text: Right now I'm working migrating an app I made entirely using code behind to MVVM and had a question on where I'm supposed to be creating controls dynamically. Basically I have a web service that returns {#} of items. For each item a button will be created and the item will be assigned to its data context. Now so far I know that I should set the Command to the ViewModel as well as the Command property. Also I know I should call those items in my web service inside of the view model (or model, right now its irrelevant to the question). The part that is questionable is where to create the buttons. I didn't really like the idea of creating buttons in my ViewModel since it was, well, related to the View. Is this correct or should I be creating them inside the ViewModel and then some how pass them back to the View via Messaging?


title: Strategies for removing register_globals from a file

text: I have a file (or rather, a list of about 100 files) in my website's repository that is still requiring the use of register_globals and other nastiness (like custom error reporting, etc) because the code is so bad, throws notices, and is 100% procedural with few subroutines. We want to move to PHP 5.4 (and eventually 5.5) this year, but can't until we can port these files over, clean them up, etc. The average file length is about 1000 lines. I've already cleaned up a few of the low-hanging fruit, however the job took almost an entire day for 2 300-500 line files. I am in a quagmire here (giggity). Anyway, has anyone else dealt with this in the past? Are there any strategies besides tracing backwards through the code? Most static analysis tools don't look at code outside of functions - are there any that will look at the procedural code and help find at least some of the problems?


title: Property-coalescing operator for C#

text: The null-coalescing operator in c# allows you to shorten the code                 if (_mywidget == null)          return new Widget();       else          return _mywidget;      Down to:                 return _mywidget ?? new Widget();      I keep finding that a useful operator I'd like to have in C# would be one that allowed you to return a property of an object, or some other value if the object is null. So I'd like to replace                 if (_mywidget == null)          return 5;       else          return _mywidget.Length;      With:                 return _mywidget.Length ??! 5;      I can't help thinking that there must be some reason for this operator not to exist. Is it a code smell? Is there some better way to write this? (I'm aware of the null object pattern but it seems overkill to use it to replace these four lines of code.)


title: Multiple source files vs. libraries for a single project

text: I write a lot of scientific software, and I originally got into programming with F77. I moved to C++ for my primary programming about 10 years ago now, but I do catch myself using F77 habits. One thing I cannot seem to get used to is library usage. To be clear, I understand why one would want to use one, but for most of the code I write, no one but the end user and the maintainers will ever use the routines I write, so I question the usefulness to me. Okay, so libraries give you a good place to stash reusable code that's easy to follow and maintain. But didn't separate source files already solve that problem for my situation? What advantage would I gain by putting my source files into a library? I can understand executable file size savings with shared libraries, but is that all that important? I have a lot of math routines that are general and could be extracted to a shared library, but should I? Most of them are only called once by a single point in my code, and usually only by a single project, so do I gain anything? Isn't any memory savings gone the moment the symbol is resolved, and the code loaded? Thanks.


title: Organizing projects in SVN

text: I'm fairly new to SVN and I would be interested in hearing about how other people would organize projects in SVN. We have projects that have different types of source files: C#, SQL, and Matlab. In addition to these types of files, we have Excel and Word file reports that we do not intend to put into SVN. So let's say we have a projects directory:               Projects\     Projects\Project1     Projects\Project2     ...      Now for the SVN repository, would it make sense to categorize things by source file type (C#, SQL, Matlab) then project:               SVN\C#\Project1     SVN\C#\Project2     SVN\SQL\Project1     SVN\SQL\Project2     SVN\Matlab\Project1     SVN\Matlab\Project2      Or would it make more sense to categorize things by project first then source file type:               SVN\Project1\C#     SVN\Project1\SQL     SVN\Project1\Matlab     SVN\Project2\C#     SVN\Project2\SQL     SVN\Project2\Matlab      Or maybe there's a better way to do this? Also, what is the best way to indicate in the Projects folders (not SVN) that a project contains files saved in SVN? Like, if I went into a the project folder for Project1 (Projects\Project1) and only saw Excel and Word reports, what would be the best way to indicate that there are other files checked into an SVN repository? Also, how does everyone feel about putting checked out SVN files on shared drives? So for instance, let's say Projects\Project1 contains the following files:               Report1.doc     Script.sql (This is a checked out SVN files in the Projects folder, which is a shared network drive)      In this situation, it would be very easy to see when there are SVN files used with a project, BUT having the checked out SVN file on a shared drive would make collaboration much more difficult. Is this others do to?


title: Is querying KeyValue Pairs efficient compared to two-property objects?

text: I'm working on a webservice and I'm returning JSON. However, I'm returning a `List<KeyValuePair<string, int>>`, since that's all I'm really ever going to be dealing with (property => value) Now sometimes I myself will be calling these functions to aggregate the results, so I end up with something like               List<KeyValuePair<string, int>> myList = resultList.where(o => o.Key =="StringKEY");      and sometimes               List<KeyValuePair<string, int>> myList = resultList.sum(o => o.Key =="StringKEY");      My question is, would it be more efficient to do the following (custom class vs dictionary):               List<MyObject> myObj = resultObjList.where(o => o.Property1 == "stringProperty")      and so on. Is there any benefit to using custom objects? I will not ever need to be adding properties, and in this case I can say there will never be a need for additional properties.


title: Are R&D mini-projects a good activity for interns?

text: I'm going to be in charge of hiring some interns for our software department soon (automotive infotainment systems) and I'm designing an internship program. The main productive activity "menu" I'm planning for them consists of:   * Verification testing   * Writing Unit Tests (automated, with an xUnit-compliant framework [several languages in our projects])    * Documenting      * Code      * Updating wiki      * Updating diagrams & design docs    * Helping with low priority tickets (supervised/mentored)   * Hunting down & cleaning compiler/run-time warnings    * Refactoring/cleaning code against our coding standards But I also have this idea that having them do small R&D projects would be good to test their talent and get them to have fun. These mini-projects would be:   * Experimental implementations & optimizations   * Proof of concept implementations for new technologies   * Small papers (~2-5 pages) doing formal research on the previous two points   * Apps (from a mini-project pool) These kinds of projects would be pre-defined and very concrete, although new ideas from the interns themselves would be very welcome. Even if a project is too big or is abandoned, the idea would also be to lay the ground work so they can be retaken by another intern or intern team. While I think this is good in concept, I don't know if it could be good in practice, as obviously this would diminish their productivity on "real work" (work with immediate value to the company), but I think it could help bring aboard very bright people and get them to want to stay in the future (which, I think, is the end goal for any internship program). My question here is if these activities are too open ended or difficult for the average intern to accomplish and if R&D is an efficient use of an interns time or if it makes more sense for to assign project work to interns instead.


title: Independent projects as a student to show off abilities

text: I'm an inexperienced student (having learned up to data structures and algorithms through various online resources) of computer science, and I'm hoping to get a job as a developer some time after I've gotten a few independent projects done. My question is, how should I choose which projects to work on? I've been looking around stackoverflow-- people usually say to pick whatever you're interested in, but I don't have enough experience to even know what specifically I'm interested in, and possibly more importantly, I don't know what some common beginner project types are. Essentially, I'm at the gap between course work (and the projects entailed in those classes) and real programming, and I don't quite know how to start. If any of you have any ideas, I'd really appreciate it.


title: Software cost estimation

text: I've seen on my work place (a University) most students making the software estimation cost of their final diploma work using COCOMO. My guessing is that this way of estimating costs is somewhat old (COCOMO dates of 1981), hence my question:               How do you estimate costs in your software?      I've seen things like : Cost = ( HoursOfWork + EstimatedIddle ) * HourlyRate That's not what I want, I'm looking for a properly (scientifically) defined cost model **EDIT** I've found some related questions on SO:   * What are some of the software cost estimation methods and models?   * How do you estimate the cost of developing software requirements?


title: Why should an "Order" object have a "Status" property?

text: I always see standard Order classes implemented with a "Status" property, but I don't feel comfortable with that. Isn't the status a property of the fulfillment process instead of the order itself? What about orders that can be subject to different fulfillment processes?


title: Communicating from lower level components to GUI?

text: What is the recommended way for a lower level software component/module to communicate with the GUI? I'm using C++. I have a service layer class that if some conditions occur needs to notify the user, but still continue processing. In the case of an unrecoverable error I understand that I can use exceptions to bubble up to the GUI, but what about in the case of a simple message that needs to be communicated to the user where the lower level component continues executing? **UPDATE** Just to clarify the service layer (aka business logic, compute layer, etc) does not "know" about the GUI nor do I want it to.


title: Library/Framework usage guidelines

text: At my core, I'm a structural, Computer Science sort of programmer (in college I was required to do a lot of programming using C, C++ and even COBOL(!)) and I'm finding more and more conflict with the core fundamentals I developed in my CS degree as opposed to the modern web development world that I'm currently immersed in. One of those conflicts I'm having is the place of libraries/frameworks in web development. I've been discovering and experimenting with several libraries/frameworks for some web application development I've been doing. Some that I've used and/or experimented with include jQuery, jQueryUi, TinyMCE, CodeIgniter, Struts, Spring and GWT. I have a slight fear of using these libraries/frameworks too extensively because of the rapidly changing nature of web technology. It seems about every other minute there's some new library/framework available to use in web development, whether it's a new framework or enhancement to an existing technology. This really rubs against the academic world I was in as we generally spent an entire semester learning the language/concept with the expectation we would later use that knowledge effectively in the workplace. My fear is that a lack of good understanding of a library/framework will lead to me to a dead end path where I will have more problems than the one that I set out to solve initially. Sorry for rambling, but I'm wondering if anyone else has experienced such a fear? I'm also wondering what could be some general guidelines for implementing libraries/frameworks into a web application. i.e. Should there be a limit of how many libraries/frameworks are used when developing a web application? Should a developer spend a week (or 2 or 3...) really getting to know the library/framework before attempting to implement it into their web application? Ultimately looking for answers in the context of libraries/frameworks which (loosely) includes anything that is implemented in a web application outside of the core technology (Java, JSP, PHP, HTML, CSS and JavaScript are core technologies that I personally use).


title: Should we check in Setup Project of Visual Studio

text: From what I understand, the ideal way to prepare builds using Visual Studio is to use a single build machine. That means, while the developers go through development process using their respective machine, the build isn't prepared from any of those machines and a build PC is used instead. Under this condition, is it necessary to check-in(using TFS as example here) the setup project. There isn't any version controlling on that particular project as any required change would be done in the build machine itself, and this isn't of any concern to others.


title: Pointers in C vs No pointers in PHP

text: Both languages have the same syntax. Why does C have the weird `*` character that denotes pointers (which is some kind of memory address of the variable contents?), when PHP doesn't have it and you can do pretty much the same things in PHP that you can do in C, without pointers? I guess the PHP compiler handles this internally, why doesn't C do the same? Doesn't this add unneeded complexity in C? For example I don't understand them :)


title: Large enterprise application - clients wish to use duplicate e-mails addresses?

text: I'd like to know people's opinions, reactions to clients and technical work arounds (if applicable), to the issue of an enterprise application where a client wishes to use duplicate e-mail addresses? To clarify, when I say duplicate e-mail addresses I mean within the same client system, having multiple users that have the same e-mail address. So not just using generic e-mail addresses but using the e-mail address of another user. e.g. Bob Jenkins: bjenkins@myorg.com James Jeffery: bjenkins@myorg.com **Context** To give this some further context, in the e-learning sector it is common that although all staff in an organisation must complete e-learning - they may not have their own e-mail address so they choose to use their managers e-mail address. Albeit against good practice in public sites... it's a requirement we've over and over again where an organisation is split between office based staff and perhaps e.g. staff in a warehouse. **Where problem lies** Mr Steak, good point, the problem lies in password resets and perhaps in situations where semi-personal information could be sent (not confidential enough to worry about the insecurities of email). Perhaps reminders for specific system actions, which would be confusing for the unintended party to see (if perhaps misreading the e-mail's intended recipient) **Possible solutions**   * System knowing the difference between a "for the attention of" and direct to the person e-mails, including this in the body text.   * Using alternative communication such as SMS   * Simply not having e-mails sent to people who are not the intended recipient.   * Providing an e-mail service ourselfs (not really viable for a corporate IT dept) Thoughts?


title: versioning data schema in android internal storage

text: I am using Android's internal storage to hold data for my application and I am trying to find a good way to handle reading data of an older schema. For example, let's say I have serialized and written several instances of class Data to a file               public class Data{         private String text;         public Data(text){             this.text = text;         }     }      and later I read that stringified data back out and cast to (Data). But then say I change Data to look like this               public class Data{         private String name;         public Data(name){             this.name = name;         }     }      now that the property is named differently, when I read out data that was saved in the original schema, it will not easily cast to the new type. What are some solutions to version the data so that I can read out old data and cast it to a new type?


title: Writing a CSS parser in C#. What do you think is the best strategy?

text: I'm in the middle of writing a CSS parser in C#. I'm well under way, but I also have those times where I wonder if I'm taking the best approach. The things I've considered are:   1. Feed the CSS grammar from the W3C into a parser generator and working off that.   2. Hand-code a CSS parser off the grammar.   3. Use a generated tokenizer, but hand-code the parsing of the productions.   4. The reverse of (3) - generate the productions, but hand-code the tokenizer. Without revealing my current approach, I was wondering how others feel about this, and appreciate any comments and guidance from your experience. Part of this is also to see what questions people ask and compare the questions to what I asked myself.


title: How to Recover from Inconsistent Job State without Database Polling

text: I'm working on scaling an application which is currently polling a mySQL database to send async jobs to a background processing system. A state machine is being used to keep track of the entities progress throughout a workflow. For example, we might have three states:   * Scheduled   * Processing   * Complete My plan is to add a messaging queue system to broker the jobs sent to the background processing system. So `Application A` would insert a new entity, then push a message to the queue. `Application B` would consume these messages and route them to the correct background processing job.               def do_work(entity)       # Precondition check       raise "Wrong State" unless entity.scheduled?            # Update state to processing       entity.processing            # ... do work            # Update state to complete       entity.complete     end      Given a job like above, I am having a hard time determining how it would be possible to recover from a situation where there was an error between the `processing` and `complete` event transitions. For example a process crash. The job processor would re-try the job, but now the entity is in an inconsistent state, and would fail. How could I handle this case without resulting back to polling the entity table looking for stale jobs? **Edit** There are two different concepts at play here. We have the data, and we have the state of the data as it relates to the job execution (scheduled/processing) + the state of the workflow (complete). Both of these pieces of information are in the same table. So after data grows the process of polling becomes inefficient (reads/updates/inserts constantly happening). So maybe a solution is to have `Application B` move active jobs into a separate datastore. So when the "clean up" task that @Ӎσᶎ refers to is running, the dataset should be much smaller. Ultimately, there it seems like there is no way to avoid polling the database to ensure data is a correct state.


title: Are There Other Use Cases For F# Type Providers?

text: So I think I know the main use case for F# 3.0's Type Providers, i. e. better Intellisense when working with data stores that use them. Are there other use cases for Type Providers or is that pretty much it?


title: Can interface be not abstract?

text: Friend of mine said that not every interface is abstract. I haven't chance to discuss that with him but it get me thinking of not abstract interface in any type of language. Is there a non abstract interfaces?


title: Career Day: how do I make "computer programmer" sound cool to 8 years old?

text: Have to do a talk at Career Day at my kid's school & looking for ideas on how to make "computer programmer" sound cool to 8 years old.


title: Should I be concerned if I have nothing to do during an internship?

text: I have been an intern at this company for about four months now. At first, it was great because I didn't have a ton of hours, the work was interesting, and it didn't interfere with school. However, once summer started, some problems turned up. They changed my direct supervisor from the person who managed the programmers to just one of the software engineers. He is pretty busy and doesn't have a lot of time to help me, so I can end up stuck for days before I can finally get help from someone. This is pretty frustrating, as I really have nothing to do during this time period and my new supervisor is extremely hard to get a hold of. As an intern, I really feel like I need more direction and help. I quickly run out of things to do or get completely overwhelmed when assigned broad things. I'm never really "checked on", so I can sit for a long time without getting anything done and no one really cares. I've tried asking for help multiple times, but he either doesn't respond to my emails or cancels our meetings. Is this normal for an intern? Is there anything I should be doing so that I can be more productive? Should I go ask management for help or would that be considered out of line for an intern? Should I not really worry about it, since this is just an internship?


title: Use of keyword "Using" in C# interface

text: When I'm using C# to write some code and I define an interface using Visual Studio 2010, it always includes a number of "using" statements (as shown in the example)               using System;     using System.Collections.Generic;     using System.Linq;     using System.Text;          namespace TestEngine.TestNameSpace     {         interface ITest1         {             bool testMethod(int xyz);         }     }       I wonder what these are for and if they are really necessary. Can I leave these out? Are they only necessary when I'm using those parts in my interface description?


title: What's the most appropriate duration of the video tutorial?

text: It is now more and more popular to have video tutorials of the software or technology instead of writing long articles. As for me, it makes perfect sense, especially for such areas like "Getting Started" or "What's New". What do you think is the most appropriate duration for such a videos? If you record the video tutorial yourself, would you just touch main points to keep it brief, or rather split it into a number of parts to keep the same level of details? And why? I know this question isn't implied to have one and only answer. I'd like to hear the reasoning behind various opinions. I have personally come across a video tutorial 45 minutes long today, and I got tired at around minute 10... So, my own impression is it's better to keep it from 5 to 10 minutes to gain visitor's attention fully. Thanks!


title: Python and only Python for almost any programming tasks!

text: Am I wrong if I think that Python is all I need to master, in order to solve most of the common programming tasks? **EDIT** I'm not OK with learning new programming languages if they don't teach me new concepts of programming and problem solving; hence the idea behind mastering a modern, fast evolving, with a rich set of class libraries, widely used and documented, and of course has a "friendly" learning curve programming language. I think that in the fast evolving tech industry, specialization is key to success.


title: Besides macros, are there any other metaprogramming techniques?

text: > **Possible Duplicate:**   >  Programming languages with a Lisp-like syntax extension mechanism I'm making a programming language, and, having spent some time in Lisp/Scheme, I feel that my language should be malleable. Should I use macros, or is there something else I might/should use? Is malleable syntax even a good idea? Is it perhaps too powerful a concept? In doing some research, I found `fexprs`. I don't really understand what these are. Help with that in an answer too please. Is it possible to have a language with macros/something-of-a-similar-nature without having s-expressions?


title: Languages like Tcl that have configurable syntax?

text: I'm looking for a language that will let me do what I could do with Clipper years ago, and which I can do with Tcl, namely add functionality in a way other than just adding functions. For example in Clipper/(x)Harbour there are commands #command, #translate, #xcommand and #xtranslate that allow things like this:               #xcommand REPEAT;         => DO WHILE .T.      #xcommand UNTIL <cond>;        =>     IF (<cond>);                   ;EXIT;               ;ENDIF;           ;ENDDO           LOCAL n := 1     REPEAT         n := n + 1     UNTIL n > 100      Similarly, in Tcl I'm doing               proc process_range {_for_ project _from_ dat1 _to_ dat2 _by_ slice} {         set fromDate [clock scan $dat1]         set toDate   [clock scan $dat2]              if {$slice eq "day"} then {set incrementor [expr 24 * 60]}         if {$slice eq "hour"} then {set incrementor 60}              set method DateRange              puts "Scanning from [clock format $fromDate -format "%c"] to [clock format $toDate -format "%c"] by $slice"         for {set dateCursor $fromDate} {$dateCursor <= $toDate} {set dateCursor [clock add $dateCursor $incrementor minutes]} {             # ...         }     }     process_range for "client" from "2013-10-18 00:00" to "2013-10-20 23:59" by day      Are there any other languages that permit this kind of, almost COBOL-esque, syntax modification? If you're wondering why I'm asking, it's for setting up stuff so that others with a not-as-geeky-as-I-am skillset can declare processing tasks.


title: Why don't languages include implication as a logical operator?

text: It might be a strange question, but why there is no implication as a logical operator in many languages (Java, C, C++, Python Haskell - although as last one have user defined operators its trivial to add it)? I find logical implication much clearer to write (particularly in asserts or assert-like expressions) then negation with or:               encrypt(buf, key, mode, iv = null) {         assert (mode != ECB --> iv != null);         assert (mode == ECB || iv != null);         assert (implies(mode != ECB, iv != null)); // User-defined function     }


title: Can I use the code for responsive video on this github link under a license?

text: This is the link: https://gist.github.com/jgarber/2302238 I am new to github and web development.So please bear with my questions. I would like to use the responsive video code on the link mentioned above, for a commercial website I am building. I see that the code is posted under the 'public' section but there is a copyright attached as well. And, the file name is MIT-LICENSE.txt. Does this have any connection with the MIT-License? Two questions: a) Can I use this code by giving an attribution? b) And, if I can, under which license can I use the code and what sort of attribution is required?


title: Database Schema Data Independence

text: I'm currently reading about database schemas about how the three-level ANSI- SPARC architecture works and i'm a bit confused about a concept it's talking about. My question is what would happen if an application was modified so it could store data for a column not defined in the logical schema? The book i'm reading talks about: > ... the addition or removal of new entities, attributes or relationships > should be possible without having to change existing external schemas or > having to rewrite application programs." - Database Systems: A practical > Approach to Design, Implementation and Management. Page: 40 (Part: 2.1.5)   * How does the logical schema handle input (columns) from applications for which it is not defined in the logical schema? ANSI-SPARC architecture: http://en.wikipedia.org/wiki/ANSI-SPARC_Architecture


title: Make a java program use more processors

text: I am running a program that is supposed to solve a problem with the brute force approach. My computer has a quad-core CPU. When I run the program clearly java uses only one core, because in my program I use only one thread. Is there a way to split up the program in more threads so that more core's are used and so to improve calculation speed? I mean: if one has a program which has a natural solution that uses only one thread, is it possible to force it use more threads without completely changing the code?


title: How to fix poorly designed software?

text: I am working on large project solo as a hobby, and I made a mistake in the very beginning: I jumped right into programming without giving a second though to design. Now I am nearly 6 months in and things are starting to fall apart: I cant get anything done, the code is very inconsistant, and the whole thing is a mess. Ive definitely learned the importance of design in software development, but I dont know how one designs software to begin with. Are there any programs that can help with this? Or do I need to sit down with pen and paper for the next few weeks trying to work things out?