Coming soon - Get a detailed view of why an account is flagged as spam!
view details

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

2
MetaSim API 1.0 Draft 2 In Progress
Post Body

Hi, I started working on a draft 2 for the MetaSim API.

One of the big unresolved and potential problems was how could clients efficiently receive simulation updates. In draft 1, the only option was to poll, and hope that the server implemented some for of caching or ETags or If-Modified-Since. That didn't seem like the best solution so I've added the ability to subscribe to changes through WebSockets.

I've updated the API document with a means to receive notifications using WebSockets. This solves a few problems:

  1. How can the server detect that the simulation is being viewed so that it can only iterate when the simulation is being viewed? (It's costly if someone were to create a simulation then leave when it is running in the background and chewing up resources indefinitely.)

  2. How can the client receive simulation updates (images especially)? Polling is inefficient and is a source of latency.

  3. How can engines receive simulation updates from other engines. An engine may want to wait to iterate until all of the engines it depends on for data have iterated. Polling, once again, is too inefficient for this and an even bigger source of latency.

Right now only the Body resource supports notifications, this assumes that bodies (planets, stars, etc.) are not created or destroyed for the lifetime of the simulation. We haven't really come to a decision about the scope of MetaSim simulations in terms of time, so I'm guessing that geologic timescales are ok, but universal timescales are too big for right now.

As always, I'm interested in feedback. The link to the MetaSim 1.0 Draft 2 is https://docs.google.com/document/d/16i6js1x-AFMwsWKfl1aKphYR2p8puRb3ldp8kXH9Z8Q/edit?usp=sharing The Notification resource is new and the Body resource has been updated.

Author
User Disabled
Account Strength
0%
Disabled 6 months ago
Account Age
15 years
Verified Email
Yes
Verified Flair
No
Total Karma
10,953
Link Karma
5,491
Comment Karma
5,094
Profile updated: 20 hours ago
Posts updated: 7 months ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
10 years ago