721 karma · joined October 9, 2010
Now, what's the difference between a library and a framework? Hint: it's probably a continuum between no inversion of control and total inversion of control (not "reversion of control" btw). Many libraries provide some inversion of control mechanisms and "force" you to work their way (tyranny!!!). Is JQuery a library with all its callbacks and the use of $? Should you use JQuery then or "stay in control"?
As for: "So, our advice to you is to stay in control of the development path of your software and prefer libraries over frameworks for real-world projects."
Where is the nuance, the "it depends" in this conclusion? It depends on where you are in the product lifecycle, where your competitors are, how many developers you have, what your core features are vs. what features the frameworks can provide, etc.
For example, imagine that you invented a new programming language. Say clojure. Now you want to provide syntax highlighting, syntax checking, tab-completion, features that an IDE provide. Will you (1) write a completely new IDE or (2) write a plug-in/extension/script for vim/emacs/eclipse/netbeans? Are they, "real world projects"?
Not sure what other strategies exist to reliably build an index.
http://www.postgresql.org/docs/current/static/sql-createinde...
In addition, there are some "advanced" features that may not be provided by MongoDB: you can choose your index type, rebuild the index, update the stats that will help the query optimizer decide if the index should be used at all, etc.
Well, foreign keys are not just a way to minimize storage: it speeds up future updates. If you duplicate your data everywhere for faster read access, your write cost just increased.
Google seems to be busy in many challenging areas, and after a Ph.D. in C.S., technical challenges look like a rare commodity in Montreal.
I was also confused by these frameworks (e.g., Django) that ask you for a secret key and I thought that the secret key was a site-wide salt. Fortunately, they knew better than me ;-)
It seems these days that there is a confusion between the web server (often a reverse-proxy), the web application and the thing in the middle (gateway/pipe/container/app server). While I would certainly consider Go for the implementation of a reverse-proxy or an app server, it isn't clear that Go is a good choice for the web application itself, especially when you consider that most of the time is spent in the DB and in the cache...
Anway, the article mostly talked about Go and not about Python...
What? I thought it was the opposite, i.e., that typical VPS customers were familiar with a command line or had to get familiar pretty quickly :-) Do you have any data or experience to back this claim (I ask because I don't have any data to back my perception)? Maybe you are referring to managed VPS as opposed to unmanaged VPS?
Btw, the article is 2 yrs old so (should have been in the summary...).
Their mistakes benefited to all new services and competitors. If GitHub had been the first to offer this kind of service, they may have committed some of SF mistakes.
Actually, this isn't black and white. When I need to create more than one exception class for a library, I prefer to avoid subclassing standard exceptions to prevent that kind of confusing situation:
try:
afile = open('myfile.txt')
content = afile.read()
my_library.do_something(content)
except IOError:
# recover from afile.read() failure
If my_library was returning a IOError, you would not know if the problem came from your code or the library code. Moreover, this would leak implementation detail.Of course, you can always get around this by wrapping each library call within a try/catch block, but that does not scale well if you make many calls interspersed with your code.
Many developers have been burned by trying to optimize their queries and indexes too early. The query planner, although sometimes unpredictable, is generally better than developers at predicting the performance of a particular execution plan. Table scans are also preferable in certain situations.
Relying on the fact that RDBMS have sophisticated query planner (as opposed to MongoDB) is not a sign of "reactive development". It just means that you should test your queries (and your indexes) with close-to-production data, and, as the data grows and evolves, continue to test, because the best execution plan might change.
RDBMS have a lot more features and support many more usage scenarios out of the box than any NoSQL systems and SQL offers more features as a query language than any other NoSQL query languages.
Of course, NoSQL query languages are simpler than SQL by design because the programmer is expected to write a program or a script for complex queries instead of using the query language. But then, you have to write your own execution plan, and think about atomicity and consistency, etc.
NoSQL are clearly the specialized systems, not the general ones.
With bit.ly, the link is much shorter with 21 characters, http://bit.ly/j8IpC8, and I'm left with 119 characters to describe the link in a twitter message.
Oh, and I'll know how many people clicked on my bit.ly link. I've become addicted to that feature.
This is quite nice if you can choose which function to represent with a table (as opposed to having to represent all functions as tables).
A recent publication on this:
Parnas D., Document based rational software development, Journal of Knowledge-Based Systems, 22(3):132-141, 2009. http://dx.doi.org/10.1016/j.knosys.2008.11.001
The fact that comments like "Man you guys are dumb." (http://news.ycombinator.com/item?id=2482925) wasn't voted down is indicative of the health of this thread.
Btw, someone downvoted a previous poster who said exactly that. The post was deleted though :-(
Spring Framework thus go way beyond web frameworks.
Disclaimer: I'm not a huge fan of Spring and I don't like "meta-frameworks", but to qualify it as a "web framework" is diminutive at best.
Not that I bought the book for the preface...
Should Python programmers write the unofficial guide to migrating off of heroku?
No NoSQL. And they use transactions for write queries.
They use apache (not even nginx!).
Only 25% of their servers are pure (no snapshot) caching servers (not 50% or 75%).
They prefer vertical partitioning over sharding (but they still use sharding).
I understand they are looking at redis for some of their features, but really, their main stack is traditional and proven. Very enlightening.
And no, I don't think Bespin/Skywriter/Ace is good enough right now.
Sure, let's throw out of the window all the optimizations the VM can do at runtime because it takes a whole second to start the VM.
And you need to actually compile the source file before executing it!
Those server applications should all be written in bash because it's instantaneous!
Kidding aside, one prof at my university once told me that she wished students should still have to compile and wait for a program to start. When there is such a delay, it pays to read your code and try to understand it before running it (as opposed to run-and-see-what-happens).