Better HN
topnewbestaskshowjobs
Log inSign up

rcoder

2,116 karma · joined Aug 14, 2007 (19y ago) · 566 submissions

Submissions

comment 17y ago · link · parent

I haven't read up on BitFrost in several months, so bits of the model may have changed by now, but as best I can recall, BitFrost is very closely tied to the Linux/POSIX process model. A core part of its process isolation model is the execution of each task under its own ephemeral user and group ID, with system-mediated IPC over DBus.

comment 17y ago · link · parent

I'm failing to see how this could possibly disadvantage Microsoft at all. Since the sandboxed code runs as a native X86 app, it also uses native system calls. Games (or any desktop app delivered via NaCl) using DirectX or other native Windows system APIs would be just as tightly coupled to Windows under NaCl as they were when running standalone.

If anything, Microsoft should welcome this as a defense against the encroachment of cross-platform JS and Flash applications.

comment 17y ago · link · parent

Slow startup time has been an Achilles' Heel for JRuby for a long time now. Being able to get <100 msec startup times could help a lot in making JRuby a reasonable option for short-lived systems automation scripts, cron jobs, etc.

comment 17y ago · link · parent

Even the base-model Amiga had almost double the CPU speed of the IBM (7 MHz vs. 5), four times the RAM (512 KB vs. 128 KB), and a full 32-bit processor (albeit with a 24-bit address space). The Amiga was also released four years later than the PCjr. That's an entire generation in personal computer hardware.

Regardless, I'm not sure where you picked up a sense of "parody" from the original article. I see an almost touching devotion to make something useful out of a dead, useless platform. It's ridiculous, silly, and probably a waste of time, but it made me smile anyway, and brought back memories of all the time I spend playing with my own PCjr in my parents' basement 20 years ago.

305.

JRuby Nailgun Support in 1.3(blog.headius.com ↗)

1 points · by rcoder · 17y ago · 1 comment

comment 17y ago · link · parent

Q: What happens when you combine this with the default Ruby OpenSSL certificate verification level? (Hint: the default verify setting is 'none'.)

I'm also not sure this is worth an entire blog post, given how little code is required to implement it:

  require 'open-uri'

  module Kernel
    alias :_orig_require :require
    def require(mod)
      mod =~ %r{^https?://} ? eval(open(mod).read) : _orig_require(mod)
    end
  end
Edit: I should have phrased that a little more constructively. My point was not to suggest that small snippets of code are unworthy of blog discussion; rather, it was to show that the code in question really was equivalent to any case of 'eval' applied to untrusted input. I.e., a Bad Idea.

comment 17y ago · link · parent

XMPP was a core part of Twitter's feature-set from the earliest days. Delivery became a bit (cough) "spotty" in early 2008 or so, and has been turned off AFAIK for a while now. That being said, there's no reason it couldn't be a part of their product offering again, if the obvious security and peer-server throttling issues could be resolved.

OpenMicroBlogging, while an interesting idea in the abstract, suffers from combo of feature bloat (license info per post/link) and missing core items (no baked-in Atom/RSS feed support, no friend/follow listing in profile) that make it far from a "Twitter-killer" out of the box.

Furthermore, the "reference implementation" laconi.ca is a bog-standard PHP/MySQL app. Since many of the complaints about Twitter's dominance stem from frustration with their uptime and scalability, it hardly seems realistic to pin our hopes for a better, more reliable future on a collection of PHP scripts running on a bazillion cheap shared hosting boxen.

In fact, WordPress + P2 (http://wordpress.org/extend/themes/p2) seems like a much more potentially-disruptive technology to me. OMB may be much more carefully designed to preserve security, license terms, and privacy, but we've seen time and time again that normal users don't really care about those things. They want a clean, usable UI, and readily-available documentation and support for a commonly-available product.

comment 17y ago · link · parent

The web browser on the Kindle is limited, but works fine for basic sites (Wikipedia, Google, Twitter, and many other mobile-optimized sites) and absolutely piggy-backs on the onboard (free) cell modem.

News.YC doesn't look terribly on it, either. ;)

309.

What Makes Jersey Interesting(codahale.com ↗)

1 points · by rcoder · 17y ago · discuss

comment 17y ago · link · parent

I'm sorry, but...what?

The book-scanning process in Rainbows End was an obvious parable, not an attempt at plausible futurism. Even in the book, alternatives to the destructive scanning process existed, and the choice of digitization technique was a business decision, not a technical one.

Furthermore, many of my favorite authors (Stephenson, Pynchon, Murakami) work full-time as writers, and seem pretty capable of doing so without starving for source material.

comment 17y ago · link · parent

I don't disagree that livestock are a serious greenhouse gas factor, but goats may have multiple uses as a stock animal, including mowing, meat, and dairy. If these animals are raised as, say, a dairy herd, and incidentally feed on grass at corporate offices rather than private ranch land, that would seem to me to be a net win in terms of carbon emissions.

comment 17y ago · link · parent

And this, kids and kid-ettes, is why having someone who knows their way around your C compiler, assembler, and debugger on your team can be worthwhile, even if you're working in a high-level language like Ruby.

comment 17y ago · link · parent

I see one graduate thesis, extended into a sparse handful of conference papers, then somehow converted into the holy grail of database technology: an index algorithm which can be used as a drop-in replacement for B-trees, offering a 2-order-of-magnitude increase in performance with no downsides.

What's that, you say? There must be some trade-offs involved? Well, sure, maybe...but you'll never be able to find out, because you can't look at anything other than said early research results without waiting for a sales representative to contact you. No downloads, real-world benchmarks, or testimonials from users == a pretty dubious set of claims, at least to these cynical eyes.

I'm not disputing the fact that these guys may have an honest improvement over the state of the art for certain search tasks. If they do have anything close to the 50x speedups they claim for general MySQL workloads, though, why hasn't Google simply written them a check and stuffed their great discovery away with all of the their IP portfolio?

comment 17y ago · link · parent

Honestly, the registry is no worse from an end-user POV than the /etc filesystem under Linux. In point of fact, given the diversity of file formats and sources in /etc, it's probably fair to say that the registry is equally navigable and understandable to the average Windows power user as the config tree is to a Linux fan. Because keys are typed and support ACLs, it's also arguably better-protected against accidental or intentional breakage.

If you want to attack an ad-hoc config system, then perhaps talk about the mess that is OS X 'defaults', or GConf's half-assed reimplementation of the Windows registry for GNOME.

That being said, I am most certainly not a Windows partisan. The last time I worked primarily on a Windows system was when I worked for a large hardware manufacturer, and the entire company ran on Exchange + Office. That was over five years ago, and I have been almost 100% on Mac OS X + Linux in the meantime, with only occasional use of Windows in a VM to verify IE compatibility.

The reason is this: for the tools I need to be productive (Vim, Ruby, Java, Firefox, MySQL, IM client, email client) Windows is at best equally capable, and at worst a second-class host, to Linux. OS X is about as suitable a platform for those tools, but has a much smoother media (esp. online video) and mobile story. Hence, the advantages of Windows (huge application library, obscure HW compat) are largely moot, while its disadvantages (poor POSIX/UNIX compat., weird dev tools, cost) are more apparent.

comment 17y ago · link · parent

Honestly, I'm most excited about the seemingly mundane parts of this update: named and default args, and package objects. The big reason that Scala appeals to me more than Haskell or ML for building non-trivial systems is the pragmatic way it approaches real-world program construction.

I think that adopting the best features of existing OO languages like Python (named/default args, first-class packages) and Ruby (flexible syntax for pseudo-DSLs, pervasive use of lambdas/blocks in stdlib for iteration and control) while running atop the JVM is a great strategy.

comment 17y ago · link · parent

My understanding is that Scala already wraps lambdas in internal class instances with a `call` method, so I would imagine that CPS will carry a similar performance and memory hit.

It certainly won't be quite as fast as idiomatic Java code, but it should be considerably faster than other non-local exit implementations that rely on exception handling to manipulate the stack.

comment 17y ago · link · parent

Supporting multiple version control systems means accepting the set intersection of their features as your baseline. Part of why GitHub has been able to just fly is their laser-like focus on only those features which facilitate collaboration atop Git. (I say this from painful experience, having spent much of the last couple of months months trying with only limited success to make users of Subversion, Mercurial, and Git happy with the same UI for source code repository browsing.)

Furthermore, trying to implement fork queues, pull requests, and even proper contributor attribution atop Subversion would be a ridiculous amount of work for very little gain.

Regardless, if you really want to stick with Subversion, you might at least consider setting up a cron job that fetches to a local git-svn mirror and then pushes a clone to GitHub. You won't have to learn a whole new version control system, and your users will happily run circles around you with their ability to fork, branch, and merge before you can copy your source tree into a new tag.

comment 17y ago · link · parent

This is something I keep trying to tell people whenever micro-benchmarks appear showing that such-and-such web server handles >5k concurrent connections within a particular memory footprint, or that this-and-that message queue supports 8k enqueue/dequeue ops per second without hitting disk.

How many Rails apps out there can handle more than, say, 200-300 concurrent clients without either pegging the CPU or bringing the database to its knees?

Putting Passenger behind Nginx just removes a need to install + configure Apache for folks who are already use and like Nginx. It may also have some benefit on memory-constrained environments like entry-level VPS hosts.

That being said, I personally think that folks who spend days or weeks tweaking their deployment to run in <256MB of RAM to save a few bucks a month on hosting should probably reevaluate their priorities.

comment 17y ago · link · parent

Using a default configuration, Apache actually maintains a pool of worker child processes which handle the actual request processing, rather than forking on every incoming request. You can allow it to fork more workers under load, or keep it locked down to manage resource usage. You can also configure it to use an alternate MPM (Multi-Processing Module) to use thread pools, fork on each request, or some mix of the above.

The difference in resource usage is due more to the fact that Apache is written to be a sort of generic network service platform, rather than a lean-and-mean HTTP server. It allows plug-in modules (whether written in C, or any of the mod_perl/python/ruby/etc. dynamic language bindings) to interact with just about any stage of request processing. In addition, a default Apache install will usually link a large number of other modules in each worker

That being said, tuning Apache for performance + minimal resource usage is a bit of a black art. If you're not comfortable configuring + building your own server package from source, it's probably easier to just grab Nginx and be done with it.

comment 17y ago · link · parent

It's not a question of being able to "afford" dropping out to work on a startup, so much as it's a question of what you're willing to give up to do it.

My parents made less than $30k combined when I entered college in the late 90s. I dropped out after my freshman year, worked as a restaurant cashier and temp for about six months, then managed to land an entry-level media production job at a startup. Since then, I've slowly clawed my way up to a decent development gig at a major systems player in Silicon Valley, all without the benefit of a college degree, or any major financial support other than my own earnings.

Even several years after I first "broke in" to the industry, however, I've had entire years where I made only a few thousand dollars. If you're willing to live in shared housing, eat a lot of cheap stir-fry and soup, and occasionally suck it up and ask a friend or family member for a couple of hundred bucks to make rent that month, you can weather some pretty drastic changes in your income.

Regardless, after a decade or so of working as a developer, I've found that the lack of a college degree matters less and less. Am I less likely to be on the short list of folks to get promoted to upper management? Almost certainly. Does that bother me? Not really. I like writing code, and am happy to continue doing so until something else seems more interesting.

comment 17y ago · link · parent

I was at demo these guys did for a SV Rails Meetup, and while the basic functionality is pretty damn cool, I have some concerns about the base footprint of applications.

The baseline they quoted was 2MB, which may not be much when you're talking about a desktop app downloaded over cable or DSL, but in the mobile space, where (non-iPhone) devices may only ship with 50-100MB of storage free, and many users are served mostly by poky EDGE networks, a multi-MB "hello, world!" seems a bit excessive.

That being said, for their core market -- namely, developers porting enterprise app UIs to mobile devices -- I think it could be an acceptable tradeoff for the productivity gain that results from it being "just another browser app".

comment 17y ago · link · parent

Honestly, this isn't all that far off -- modern Intel and AMD chips have essentially nothing in common with the old 8086 line, and in fact use microcode heavily to "emulate" the classic instruction set.

Of course, it took them a few years longer than he thought to get there, but the basic idea is sound.

comment 17y ago · link · parent

If you know and like Tomcat, may I suggest you have a look at JRuby deployment for Rails apps? With recent versions of jruby-rack and the warbler gem, it's as simple as listing your dependencies in a config file, and then running 'rake war' from the top level of a Rails app to get a shiny new WAR file ready to drop into your Tomcat deployment directory.

comment 17y ago · link · parent

Once upon a time, people made the same comments about Ruby and Rails: "it's a fringe language", "the tools are immature", "you shouldn't use it because you can't find Ruby coders", etc., etc.

I find it honestly hilarious to hear it suggested that one of the early high-volume Rails shops should stick with "safe" language choices because they won't be able to hire enough developers to work with a new language.

I've read through the sources to Kestrel, and found them quite easy to grok. If anything, most real-world Scala code seems to be essentially very clean Java, with much of the syntactic cruft (redundant type declarations, inner classes, 'public static final' declarations, etc.) removed. Any experienced, effective developer is going to spend far more time getting to know your in-house APIs and coding style than they are the language.

comment 17y ago · link · parent

A really talented sysadmin with good tools may be able to manage 100 servers; a great developer can optimize your algorithms to get an order-of-magnitude reduction in the number of servers you need.

Eventually, more servers == more headcount.

comment 17y ago · link · parent

Please read the original article. Nowhere in it (or the original talk) does Alex advocate using Scala instead of Rails for the things that Rails does well -- namely, interactive web page rendering.

Within that niche, Rails does a fine job. For infrastructure and middleware code, however, Rails has little to offer other than the Ruby language, which has serious issues when applied to time + memory-intensive problem domains.

I'm a huge fan of Ruby, and a (perhaps somewhat begrudging) user of Rails, but that doesn't mean I think they're the right solution to every problem.

comment 17y ago · link · parent

First of all, I don't think it's fair to accuse the Twitter dev team of working without real experience and numbers to back up their decisions. They have a huge volume of data being generated by their service, and have weathered the whole "Rails doesn't scale" flame-fest with relative grace and good humor. IMHO, that entitles them to talk fairly freely about the relative scalability of different languages and frameworks.

Secondly, any "ranting" you hear in this article is the product of El Reg, not Alex. He mostly offered a calm, positive presentation about the improved speed (with relatively little, if any, tradeoff in developer productivity) that came from using Scala instead of Ruby for critical infrastructure services.

Regardless, most Java web applications' performance issues stem from framework-itis, not from the underlying runtime. By itself, Tomcat (or another modern Java servlet container) is capable of some pretty impressive throughput -- perhaps not on par with a lean, pure C server like nginx, but not nearly as limited in functionality and extensibility, either.

No matter what you think about Java the language, you at least have to admit that HotSpot blows MRI, YARV, the Python VM, and Parrot out of the water when it comes to raw performance on low-level code. That doesn't save you from bad implementation ideas, but it does at least give you the possibility of getting fast, efficient code, if you have a decent compiler and work fairly close to the metal.

Using Scala is one way to produce that sort of low-level implementation code without wanting to gouge your eyes out (which is how most Java source tends to make me feel, anyway).

comment 17y ago · link · parent

More importantly, Mercurial is extensible in Python -- you can write extension modules, hooks, etc., all of which have full access to the (albeit poorly-documented) Mercurial internals.

Writing extensions for Git is rather different, since you effectively can't. To extend or build on Git, you end up doing a lot of shelling out to the 'git' binary with use of 'raw' output formats and regexp-based scraping. It's pipes and shell subcommands all the way down, instead of a library-style programming API.

Which you prefer depends a lot on the diversity and preferences of the community using your repositories. Mercurial pushes you towards usability and single-language (Python) solutions, while Git easily drops into a classic UNIX-like "lots of little scripts" solution.

comment 17y ago · link · parent

I've settled into a pretty happy workflow using Git as a local snapshot of an upstream Subversion repository using git-svn. With a bit of discipline, you can keep things nicely in sync, and get the benefits of cheap-as-hell branching and local/offline commits without forcing your entire project team to migrate to a new VCS.

I've got some notes on the subject on my blog:

http://rcoder.net/content/daily-git-svn

comment 17y ago · link · parent

The key difference here is that one group is going after those they consider guilty of unauthorized copying of media, while the other is simply trying to have their claim of authorship respected.

Torrent files of MP3s and TV shows don't, as a general rule, mis-represent the original creators of a work. Because of that, they can still drive real revenue for those artists -- people may initially acquire an album or episodes of a TV show illegally, then go on in the future to pay for new content from the same people.

Doing a copy-and-paste job on someone else's blog content, however, breaks the link (however tenuous) between author and reader, which means that the author is unlikely to ever see anything of value back from the interaction. Not only are they deprived of direct financial (AdSense) and social (search rankings, public visibility) benefits, they are robbed of one of the most valuable commodities available to a blogger: direct feedback from interested readers.

1
101112
19