That is a goal of Brubeck too. By using DictShield for modeling you get all your modeling needs, including serializing to Python dictionaries or JSON strings, but it doesn't have an opinion on what database you us.
Your database layer might change, for whatever reason, so you adjust a few queries for loading data and you're back in action.
In addition to this many people haphazardly choose their framework and make the mistake of using Tornado without understanding how nonblocking I/O works. If a user chooses.
Brubeck, they would get nonblocking support for free, which makes it a considerably safer haphazard choice.
I think it's unfortunate that the power of choice isn't as appreciated outside the Python world but I can also relate to people who feel they have to read way too much stuff.
In spite of this, however, Brubeck indeed aims to be a one-stop shop. It uses coroutines + nonblocking I/O to make scaling up easy but it also a web.py style routing system because all of us know this style already.
Choice is great for veterans, but for someone learning Python or Ruby, how do they know what to pick? How to they know that they're not going to bet on a losing horse that stops being actively developed after a while and doesn't do anything for their career. Veterans can afford to play around and test out new frameworks, because they can always fall back to Django or whatever pays the bills, but newbies can't.
They have to do their homework, ask around, and make the best possible guess. And more importantly, focus on the more general skills than the specific framework.
If someone is getting started in a vacuum, they're doing it wrong.
J2 Labs is the name of my consulting company (and twitter account @j2labs).
Brubeck + DictShield are both projects that have risen from building API's for startups. I aim to make Brubeck as useful as possible for building web projects a quick and easy process, without sacrificing easy scaling.
My thinking here is that a solid model should help developers build their idea fast and make it through the early days of startups without breaking their backs.
I don't particularly like working with Tornado because it offers little support for the plethora of Python drivers that are blocking only. On top of that, the callback model, while powerful, can lead to some seriously confusing code.
I believe people will find the combination of Mongrel2, eventlet and a database agnostic modeling system (DictShield) very flexible.
I guess what he means is that for drivers like mysql which are blocking only there is little support in tornado to not freeze the tornado instance during the request response cycle.
For some reason my other account is blocked from responding so I created this one.
That is correct about pymongo. Eventlet will convert any drivers that are written entirely in Python into nonblocking driver. Gevent, an alternative to eventlet, can do the same. Brubeck supports both.
In addition to that it also makes ZeroMQ nonblocking. The combination of ZeroMQ support and pymongo, pyredis and pyriak all being available entirely as python (bson is in c tho) is what convinced me I had to write a new framework.
Your account is probably blocking you from responding because of some flamewar prevention feature Paul put in a while ago that makes it difficult for commenters to have nested discussions with one another--the deeper the discussion, the longer you have to wait before making a reply to a user who just replied to you.
You know more about thrift than I do. If the "blocking" code is in python, eventlet should be able to fix it. You can't do anything about the native machine code, though. It appears that the client library includes a c-based codec to improve performance, but it should not be a problem if the transport is based on python sockets.
I use pymongo with gevent. A small hack is necessary to prevent pymongo from making a new connection for each thread that accesses mongodb (because with gevent, you can have a massive number of threads). I'd imagine the same is true with eventlet.
The difference here is that Brubeck answers ZeroMQ messages from Mongrel2 instead of being a web server. So instead of using WSGI, Brubeck connects to Mongrel2 via a ZeroMQ socket and reads messages representing the web requests.
Beyond that I attempted to create a familiar interface for everyone who's used a pythonic web framework before. Indeed, a lot like Flask, but also like Tornado.
Agreed. If you limit your application to WSGI then mongrel2 is "just" another high-performance event-driven webserver. To really take advantage of the advanced features of m2 you need a framework that's more closely tied to its model of the world.
(speaking as author of the m2wsgi module linked above)
I haven't done anything significant with Mongrel2 yet, so my mental model of its operation is probably somewhat flawed, but I was thinking about my above post for a while yesterday.
It seems like WSGI supports a subset of Mongrel2 features. Any "pure" WSGI app can run fine behind Mongrel2, but Mongrel2 allows much more than the WSGI model. For example, a response in Mongrel2 is just a socket getting written to. Mongrel2 can send a request to server A, and then receive the response from a completely seperate server B. Can WSGI support something like this? As far as I know, someone would need to reimplement a lot of Mongrel2's functionality in Python (which is idiotic) just for WSGI compliance.
Again, I've yet to build anything with Mongrel2 and I haven't read the WSGI PEP in a while, so please correct me if I'm wrong about anything. After thinking about it yesterday, I find the differences between a more traditional WSGI-esque model and something like Mongrel2 to be fascinating.
Brubeck is a Mongrel2 handler which makes it effectively a ZeroMQ Framework. But it is built with web serving in mind so I (I wrote it) attempted to also bring many of the customs we're used to with web frameworks to the Python + Mongrel2 world.
There are many python frameworks and each serves a different need. If you are a Tornado user but find the blocking / nonblocking paradigm confusing, you would probably get a lot out of Brubeck because it replaces the IOLoop (like Twisted's reactor) with a simpler system, eventlet.
I'm glad you think it's hip! It's only a couple months old.
Here in the city I am in, there is no problem at all selling those houses, and in other bigger cities it is similar. More and more people move to the cities if they can afford it. Better schools, better hospitals, and you Hukou (you "citizen registration card") it will not say "rural resident" anymore; to be a "city resident" is looks much better.
Buyers can be reasonably sure that those new areas will be developed a few years later.
However, for some 3 years now, the state and central gov't constantly come up with new laws to avoid that people buy many apartments and leave them empty. The new property tax in selected cities is one example. An increase in required down payment capital is another (http://usa.chinadaily.com.cn/china/2011-07/07/content_128581...). In the city I am in, you only get a bank credit for your first apartment now, to buy further apartments, you have to finance them yourself.
Buying an apartment is the safest form of investment in a country where the health system is only just being built up, and the retirement system is not widely trusted (yet). It is more the thing of the new middle class. The really rich people will try to get part of their money out of the country as soon as they can. You never know how stable the country will be tomorrow, is usually the reasoning.
Why does the price on failed buildings have to stay high? Why couldn't the government (through a bank, likely) reclaim a bankrupt project, restructure its books and basically "give away" the units?
China certainly has its share of problems. Having lots of extra housing for people to eventually move into is far from the top 10. Something related that is a bigger deal is the energy of heating and cooling housing built without 21st century insulation.
I think its useful to _not_ compare how the U.S. and EU have handled bailing out its financial institutions. China does not have to bail out its financial institutions in the same way if and when it comes to that. They could simply just let the rich take a haircut and give away a bunch of empty apartments to cool the angry masses.
What is Shanghai like these days? In Beijing there is a ton of vacant commercial real estate, but most of it seems to be owned by organizations with no need to lease (else why not lower prices?). Where developments like SOHO are competing is by selling rather than leasing smaller condo-style units. And while the market for apartments has slowed down, there are still people buying. Fifth ring road near Echo's place is 30,000 RMB per square meter.
I wonder more what the actual cost structure is for the complexes cited in these videos. They should be the lowest of all since they're being built on satellite territories. That said, even in a worst case scenario of total default, I wouldn't expect banks to seize the property of people they've been pressured to lend money to. And I wouldn't expect the property to remain "unowned" if it seemed like that would happen. The developers would just sell the assets to a property management company and go nominally bankrupt.
Agree about the differences between China, US and EU too, but my guess is that banks are safe, and that as individual markets get overdeveloped local governments will start adopting property taxes to raise revenue. This is NOT going to be popular with people who've already taken out a 30-year mortgage to buy a 60 square meter apartment, but that coupled with price stagnation should curtail people's tendencies to treat real estate as assets for investment instead of places to live, and push prices to whatever is logical given demographic and migration trends. Soft landing?
From the numbers I've seen, Shanghai is not far behind Beijing...lots of available space in less desirable/developed areas, tight in others, pricing that makes no sense for buying as a home. Certainly, there is nothing "fair" about this.
What do I expect will happen? I expect a lot of people will eventually take paper losses but get to keep the home they live in at adjusted terms. Larger holdings will take losses relative to how connected they are, with a few making out very well. Municipalities will test a variety of tax schemes.
How much social instability will there be in between now and this eventuality? I can't say but can only hope level heads prevail.
There wasn't enough time for the black hole to grow as large as this one is (was). If X is how much material it would consume per billion years, it is sitting 4X when you universe is only two billion years old and should have only been 2X (note: I don't know the actual magnitude of the numbers, but am basing my numbers off the six-foot kindergartner comment).
Who's to say? It's by definition - the "Big Bang" was the moment when the universe,time and space, came into existence. Neither existed before that. To talk about "before" the Big Bang isn't even correct - there is no "Before".
No, the big bang was an event that we know happened, but we don't know that it's when time, space, or the universe came into existence nor is it defined as such. Big bangs could happen over and over. Don't confused the known event, for the theory that it was the beginning, they are different things.
It doesn't necessarily. It is an object that due to current models of quasar formation should not exist at that point in time. This means that there is something wrong with those or current estimations of the age of the universe. The latter is less likely.
yes, we are trying to estimate the behavior, mass, luminocity, etc... of the objects in the Universe that was several times smaller than it is now, ie. the space itself was much more "dense" (for lack of a better word) and the matter "warmer" - was the Universe behaving like it does today? We know that the fundamental forces behave differently ( at least quantitatively-wise ) when the matter is "hot". So our estimations may be several orders of magnitude wrong, and finds such as this help to adjust our theories and estimates.
That's correct, lensing won't affect the observed redshift. It will, however, affect the observed luminosity of the quasar and make us perceive it to be more luminous than it really is. This would lead us to calculate a larger black hole mass. The lensing effect only goes as the square root of the magnification though, so you would need an extremely strongly lensed quasar to be able to explain the black hole mass. If that were the case, the lensing body would also be visible, which it is not.
If lensing (through one or more lenses) resulted in a significantly longer path for the light, would it not make sense for an object to seem older than it is (i.e. have greater redshift)?
Lensing will make light travel through only a very slightly longer path. At most the difference will only be a few light-weeks. (This is seen in objects which have multiple images. Occasionally you will see one of the images flare up for some reason, and a few days later the other image will flare up.) It won't be anywhere near long enough for cosmological effects like redshift to be important. The main effect of gravitational lensing is just to increase the apparent luminosity of the lensed object.
Thanks for the clarification. I was imagining a situation that would require tens of degrees of deflection, with two or three lenses zig-zagging light across a cosmologically significant distance.
Your database layer might change, for whatever reason, so you adjust a few queries for loading data and you're back in action.
In addition to this many people haphazardly choose their framework and make the mistake of using Tornado without understanding how nonblocking I/O works. If a user chooses.
Brubeck, they would get nonblocking support for free, which makes it a considerably safer haphazard choice.