Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: jimbobway on March 02, 2012, 11:49:47 PM



Title: Feasibility on putting block chain on Google App Engine
Post by: jimbobway on March 02, 2012, 11:49:47 PM
What is the feasibility on putting block chain on Google App Engine?  I would like to do this since my app relies on Google App Engine.  I just want to read out of the block chain.


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: Jine on March 03, 2012, 03:49:45 AM
BitCoinJ is a Java-implementation of the bitcoin protocol, it should be able to port it to GAE.
Another solution would be to use the RPC-interface to bitcoind and place the blockchain + bitcoin somewhere else, for instance - EC2 (which have a free tier first year for a micro server)

A third solution would be to use blockchain/blockexplorer to get data, depending on what your needs is.

--
Regards, Jim
Bit LC Inc.
https://www.bitlc.net


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: bitcoinsarefun on March 04, 2012, 10:41:46 PM
What is the feasibility on putting block chain on Google App Engine?  I would like to do this since my app relies on Google App Engine.  I just want to read out of the block chain.

You could probably copy it up there and write yourself something similar to blockexplorer, I believe the source for it or something similar is out there.

Quote from: jine
Another solution would be to use the RPC-interface to bitcoind and place the blockchain + bitcoin somewhere else, for instance - EC2 (which have a free tier first year for a micro server)

This is what I have did for the litecoin faucet (http://freelitecoins.appspot.com/).


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: Mike Hearn on March 07, 2012, 09:32:57 AM
The problem with using Bitcoin on GAE is that, last time I checked, you are not allowed to make outbound TCP connections.


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: ripper234 on March 07, 2012, 10:34:41 AM
The problem with using Bitcoin on GAE is that, last time I checked, you are not allowed to make outbound TCP connections.

Take a look at Stratum (http://stratum.bitcoin.cz/). It's still very much work in progress, but it should work on GAE (I assume outbound HTTP connections are allowed).


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: bitcoinsarefun on March 07, 2012, 12:40:51 PM
The problem with using Bitcoin on GAE is that, last time I checked, you are not allowed to make outbound TCP connections.

Not true, certain types of connections are restricted - basically, anything involving raw sockets but outbound tcp connections work fine


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: Mike Hearn on March 07, 2012, 01:30:23 PM
In that case I guess you could use BitCoinJ to connect to the network every 10 minutes or so and download new blocks. Create an implementation of the BlockStore interface that uses the appengine datastore and you'd be "done" I guess, though nobody has tried it yet.


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: jimbobway on March 07, 2012, 05:20:33 PM
In that case I guess you could use BitCoinJ to connect to the network every 10 minutes or so and download new blocks. Create an implementation of the BlockStore interface that uses the appengine datastore and you'd be "done" I guess, though nobody has tried it yet.

Thanks Mike.  I'll be looking into this although I don't know if I have the time (or maybe even the talent).


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: weex on March 07, 2012, 10:17:38 PM
If you have the BTC, post a bounty!


Title: Re: Feasibility on putting block chain on Google App Engine
Post by: jimbobway on March 08, 2012, 01:02:43 AM
If you have the BTC, post a bounty!

Good idea.  I may post a bounty once I figure out what I need.  If I go with the GAE method then it will need to run on GAE.  Again I just need to read out of the blockchain.  Also, some the bitcond commands also need to work so you can query the blockchain from GAE, for instance, getting the balance of a bitcoin address.

Seems like if bitcoin can run on GAE it can scale indefinitely.



Title: Re: Feasibility on putting block chain on Google App Engine
Post by: Mike Hearn on March 08, 2012, 02:47:37 PM
You can query the balance of an address that's in your wallet. You don't need the private key. You can't (today) query the balance of every addresses in the block chain, a la blockexplorer. That's a use case that'd be useful to support later.