Author Topic: Alternative Network Protocol - Testers Wanted  (Read 6439 times)

0 Members and 1 Guest are viewing this topic.

Offline ag

  • Full Member
  • ***
  • Posts: 132
    • View Profile
I started doing some asynchronous programming in node and learning javascript this last year. this code is an abomination. I understood none of it. But will give BM some slack, I am just a novice. I have started reading ES6... so maybe I like Promises... I'll see about 'class'. A networking protocol in javascript intrigues me so I am going to try and understand it.
« Last Edit: September 28, 2015, 05:47:18 pm by ag »

Offline clayop

  • Hero Member
  • *****
  • Posts: 2033
    • View Profile
    • Bitshares Korea
  • BitShares: clayop
@bytemaster please let us know when the node is back, so we can keep testing.
Bitshares Korea - http://www.bitshares.kr
Vote for me and see Korean Bitshares community grows
delegate-clayop

Offline clayop

  • Hero Member
  • *****
  • Posts: 2033
    • View Profile
    • Bitshares Korea
  • BitShares: clayop
Bitshares Korea - http://www.bitshares.kr
Vote for me and see Korean Bitshares community grows
delegate-clayop

Offline betax

  • Hero Member
  • *****
  • Posts: 808
    • View Profile
Are there docs for how this tree structure is created/maintained?

Also, since when does bytemaster write anything in javascript? =P

Good question ...  Docs or even just a hint on how that might look.

Bytemaster took probably a week to learn JavaScript and basically another week to get a good overview of our entire web architecture.  This was his contribution as a result, called the chain.js.  It has since been renamed to the ChainStore.js.

Lets just say that for all of the great things about C++, I have found I can develop faster in JavaScript and have come to appreciate the garbage collection and memory management.    Though it is annoying not having type checking to catch simple errors like the one James identified above :)   

I also like having one codebase rather than two :)

You could check TypeScript.
http://www.typescriptlang.org/

Node.js example
https://github.com/Microsoft/TypeScriptSamples/tree/master/imageboard
https://metaexchange.info | Bitcoin<->Altcoin exchange | Instant | Safe | Low spreads

Offline bytemaster

The main server ran out of disk space :(
For the latest updates checkout my blog: http://bytemaster.bitshares.org
Anything said on these forums does not constitute an intent to create a legal obligation or contract between myself and anyone else.   These are merely my opinions and I reserve the right to change them at any time.

Offline abit

  • Committee member
  • Hero Member
  • *
  • Posts: 4632
    • View Profile
    • Abit's Hive Blog
  • BitShares: abit
  • GitHub: abitmore
Is it working now? I cannot sync using this thing.
Not working for me.. I switched to the original p2p protocol.
BitShares committee member: abit
BitShares witness: in.abit

Offline clayop

  • Hero Member
  • *****
  • Posts: 2033
    • View Profile
    • Bitshares Korea
  • BitShares: clayop
Is it working now? I cannot sync using this thing.
Bitshares Korea - http://www.bitshares.kr
Vote for me and see Korean Bitshares community grows
delegate-clayop

Offline Thom

Wackou and I will be getting together on mumble tomorrow at 3PM CDT to discuss additional nodes on the backbone approach he has described here: http://digitalgaia.io/backbone.html.

BM, have you read Wackou's info about his backbone approach and DDOS protection scheme via backbone node proxies? It directly addresses the issue of security and more importantly for graphene connection latency.

I can't help but feel there is major overlap / reinvention of our plans from this thread.

If I am misunderstanding the intent of this thread I apologize, as I have not been able to stay in touch as well as usual due to personal issues.

Injustice anywhere is a threat to justice everywhere - MLK |  Verbaltech2 Witness Reports: https://bitsharestalk.org/index.php/topic,23902.0.html

Offline monsterer

Could you have independent 3rd party services publish a merkle root hash for each new block?  The entire chain you get from any independent central service has to hash all the way up to the root.  I may be over-simplifying it, but that could validate everything...

Why not just through away all the clients completely and have a plain, centralised bitshares service? I don't see the point of p2p at all when you're talking about using centralised validation service.
My opinions do not represent those of metaexchange unless explicitly stated.
https://metaexchange.info | Bitcoin<->Altcoin exchange | Instant | Safe | Low spreads

Offline clayop

  • Hero Member
  • *****
  • Posts: 2033
    • View Profile
    • Bitshares Korea
  • BitShares: clayop
Same here

Same result.  Stuck.

Code: [Select]
{
  "head_block_num": 123659,
  "head_block_id": "0001e30bb947c35176dfe5271ccf504682ce0ed7",
  "head_block_age": "3 hours old",
  "next_maintenance_time": "3 hours ago",
  "chain_id": "ecbde738ba0b319cb4d266e613b200d010da8b37313c20aec03f9c8e2d9b35e3",
  "participation": "82.03125000000000000",

Bitshares Korea - http://www.bitshares.kr
Vote for me and see Korean Bitshares community grows
delegate-clayop

Offline jamesc

The idea is that the root node is "real time" and doesn't get an opportunity to buffer and reorder.  Though technically it could.   The witnesses would then decide whether or not they want to coordinate via a central service to provide higher reliability or whether they wish to remain P2P.

And how do they know the central service has not been compromised? How can they tell the difference between a poor network connection and a compromised service?

Could you have independent 3rd party services publish a merkle root hash for each new block?  The entire chain you get from any independent central service has to hash all the way up to the root.  I may be over-simplifying it, but that could validate everything...

Offline bytemaster

Are there docs for how this tree structure is created/maintained?

Also, since when does bytemaster write anything in javascript? =P

Good question ...  Docs or even just a hint on how that might look.

Bytemaster took probably a week to learn JavaScript and basically another week to get a good overview of our entire web architecture.  This was his contribution as a result, called the chain.js.  It has since been renamed to the ChainStore.js.

Lets just say that for all of the great things about C++, I have found I can develop faster in JavaScript and have come to appreciate the garbage collection and memory management.    Though it is annoying not having type checking to catch simple errors like the one James identified above :)   

I also like having one codebase rather than two :)
For the latest updates checkout my blog: http://bytemaster.bitshares.org
Anything said on these forums does not constitute an intent to create a legal obligation or contract between myself and anyone else.   These are merely my opinions and I reserve the right to change them at any time.

Offline jamesc

Are there docs for how this tree structure is created/maintained?

Also, since when does bytemaster write anything in javascript? =P

Good question ...  Docs or even just a hint on how that might look.

Bytemaster took probably a week to learn JavaScript and basically another week to get a good overview of our entire web architecture.  This was his contribution as a result, called the chain.js.  It has since been renamed to the ChainStore.js.
« Last Edit: September 09, 2015, 01:54:14 pm by jcalfee1 »

Offline jamesc

JavaScript is easier to write / debug than C++ and more people around here can probably help improve it.

Looks like a message parameter to "this.isKnownTransaction()" was left out here:
Code: [Select]
   isKnownTransaction( message ) {
      return this.known_trxsa.has(message) || this.known_trxsb.has(message)
   }

   addKnownTransaction( message ) {
      if( !this.isKnownTransaction() )
      {
         this.known_trxsa.add(message)
         return true;
      }
      return false
   }

This would prevent transactions from being sent from the client to the upstream 'root' node.  I created an issue in github...

I see the web socket keeps a list of its clients.  I guess this means every client holds another client list just like the root node?

Offline monsterer

The idea is that the root node is "real time" and doesn't get an opportunity to buffer and reorder.  Though technically it could.   The witnesses would then decide whether or not they want to coordinate via a central service to provide higher reliability or whether they wish to remain P2P.

And how do they know the central service has not been compromised? How can they tell the difference between a poor network connection and a compromised service?
My opinions do not represent those of metaexchange unless explicitly stated.
https://metaexchange.info | Bitcoin<->Altcoin exchange | Instant | Safe | Low spreads