I
and my name is also xik as most people
know me on github so I'm going to talk
about mango which is making it fully
decentralized and what does that means
it puts get repositories onto athyrium
swarm and I PFS I just a quick note
about what get is get is a version
control software where most developers
keep their source code and they make
changes to the source code other people
can track these changes and contribute
changes so the first thing is about get
as it was created roughly ten years ago
and it was created with decentralization
and distributed systems in mind however
ten years ago decentralized systems
weren't ready so you couldn't do this
you had to use a central part to get
however today we have decentralized
systems in place the etherium I PFS and
swarm so this is the time to accomplish
the goal of get the first thing is why
do I care about mango and what do I care
of it sorry why do I care about mango
and why you should also care about mango
there a couple of reasons you don't
really want to trust the central
repository with all your data they could
take it down and you want more security
than that this is a very important fact
that you get by default if you use mango
you get proof of existence of your code
so whenever you push your changes or
your code is a better name so whenever
you push changes to your code and it
will be stored on the block chain as
well and because of that you get the
timestamp according to the block chain
and you can prove that your code with
all its content existed at that point of
time you can see that's very important
because you can prove in case of legal
issues that you were the first
implementing that and you have the prior
art and that's really important in the
open source software and I don't really
used for mango which get cannot really
do is storing large pies so get just
towards large files as a single block
and whenever other people copy your gate
or they make changes to that or they
store other files or they change the
file it will be a brand-new entire blob
so if you have a file of like 10
megabytes which is the solidity compiler
for every new compiler version you have
the full file currently the solidity
repository is roughly 100 megabytes in
yet just for the compiler versions which
using IP FS or sworn you have
deduplication and whenever you store
these files and use it a mango only the
differences are stored this is something
many people don't know but get and the
last really important point is it here
iam as a cause is building decentralized
systems the whole source code of this
cost should be of label two distinct
rely systems the last photo so what is
get itself get is a content addressable
file system what is form it is the same
what is I PFS it is the same there's a
tiny bit of difference though it is
working on your local system what other
two are working in a global
decentralized way so you see it makes
sense to move your git repos to either
swarm or I BFS that this is something
many people have seen you know get looks
fairly complicated people mostly know a
few commands and they get afraid they
delete stuff and they start from scratch
I can assure you a few tricks or you
know just try to explain how it works
internally and that will help you to
understand how mango works and don't be
afraid it won't be long so you get
everything is an object and every object
has an identifier that this identifier
is a sha-1 hash so in this example the
first one example I'm just putting
putting some data in to get and you get
back the identifier and of course once
you notice identifier you can print the
details
so there I just loaded a file which at
the content hello material hello
Shanghai on the file system all these
data blobs are stalled stored in a
compressed form ok so now I have data
and get and the second thing I need is
the file name for that data and probably
permissions in some other details so the
second object think it is called trees
and creating a new tree is simple use
the identifier of the data and you set
the file name next to it and as you see
printing this object works the same way
as previously ok at this stage I know
what my data is I know what the fine aim
is but I don't know who created that
file and when it was created a white was
created so the third object we have is
called the comet and it's another simple
command which you can use and you get
back another simple hash similar to
before you can print that hash and you
get the familiar display which you
already see in get logs so I'm not
seeing all of you should use these
comments to manage get because you do
have the higher level systems to do that
but because of these three objects you
can represent get in a tree and the leaf
nodes in ingots are the data blobs then
you associate those data blobs with a
fine name and finally with the comet and
subsequent comets can refer to previous
comments etc and you see the tree is
just a flat structure if you want to
have multiple directories you can just
change trees together when you create a
merge or a pull request multiple
comments will be referenced in the next
comment ok so that was the hard part a
little bit what kind of objects we
haven't yet but you can see we have all
these simple bits of data and for a
single comment and actual you know
high-level commitment you put files into
your git repo you have at least four
five objects so my first implementation
of mango was just building all these
objects putting all these objects into
any theorem contract that works but
probably it's not very useful and for a
simple repo of a couple of files we
just a hello world in them it takes
roughly 50 million gas like developers
earn a lot but probably they don't have
enough money to keep up with typos
changes and pushing attempt to an atrium
contract so better implementation is
realizing the fact that we can use IVFs
and swarm so this is what I did and I
put all these objects into IP offense
and swarm but as I've mentioned get uses
sha-1 heshes and probably all of you
know that I PFS doesn't so shavon isn't
really good anymore we could change get
do not use shavon but unfortunately it's
really tied in which have one and we
want to keep a backwards compatibility
with every tool you have today as well
as solutions like github so we cannot
change that well a simple solution is to
map I PFS identifiers to get identifiers
so what this means is I push every
single object to I PFS then i create a
snapshot file of the mapping of these
identifiers and i push this snapshot 52
I PFS as well okay so why do you need it
here IAM right well you don't actually
need a theorem at least to this level
when you push all your content to I PFS
you get this top-level snapshot file and
you can give this snapshot identifier to
anyone you want to give your coat too
they can download your code that way
however if they make changes or you make
changes you're going to get a new
snapshot identifier so then you have to
give that identify to them they make
changes they give a new one you make
changes give a new one it's not really
practical so this is where a theorem
comes into play and it makes this a
practical solution so at every gate push
they push to details into a mango
contract which is what was the latest
comet which is the gate identifier and
the location of this snapshot pie and
today it is cost hundred forty thousand
gas which is a big difference 250
million and this contract isn't optic
so this could even go for the deck so
what is mango and mango is actually a
couple of things it defines the
semantics had to store get objects in I
PFS or swarm it also defines a contract
interface for itanium it gives you an
implementation for the get back end in
able to communicate with each here iam
and I BFS and it also gives you admin
tools to create repos so every git repo
has its own contract there's no point
making this complex and having a
contract for a number of repositories
this has to be simple and you know
secure as it can so what the etherium
does on top of this it can manage access
control and you're also free to
implement whatever else you want add
there's just a repo interface you have
to conform to but in if anything else
you do is up to you m for the actual
repo contract which uses hundred forty
thousand gasps there's an implementation
in the mango admin tool chain is it this
is an actual example how to use the tool
chain and once you install it you can
create repos this of course will need
access to an idiom RPC node as well as
to I PFS or swarm so once you create it
you get any tea room address and that's
the address of your repo then you can
create new users you can delete users
you can set administration rights and a
couple of other things okay at this
stage you have your repository so the
next thing is to upload data into it
assuming you have your repo already you
just have to set up the endpoint which
is your contract address and you can
push data into this repo let's mention
before we don't really store the data in
the repo but we need to update the
references in your repo okay now you
have all your content a decentralized so
it's time to share it with your friends
and they can download it as well
since you are able to create multiple
accounts in your repo contract your
friends are able to push changes to your
repo at the same time while you know
contract addresses work I think there
will be a better way to do that and I
hope ens or a similar system will come
along soon and you will have symbolic
names for your repos such as solidity
that etherium that mango the thief I
still need to convince the guys to
register five letter names in eve but
hopefully that works so where are we
with mango is it a replacement yet of
course well not entirely but there's
certain use cases it's already capable
off I would suggest that you use your
tools you're familiar with today and
your services you're familiar with today
but once you have a version of your
software or release you want to persist
for and an indefinite length of time you
could use mango and you could push that
certain chainset the certain version of
your software to mango but this should
change in the future so we have to
improve mango and we have to improve
tools to provide full replacement full
decent replacement to social coding so
the first thing we have to do here is
which is a tiny thing you know with each
releasing it you can only set a version
number we would be rakul to also set
release notes what that version includes
so that's actually possible with it add
this feature called get note which you
can use to put notes next to any object
it's kind of hard to use so this has to
be improved the second big thing is to
have issue tracking we didn't get and
google has a project to do that with get
notes but it's a bit clumsy so there's
still room of room for improvement here
the really big work here is a supporting
pull request or merge request and as
well as like github start forking so if
anyone has good ideas had to do it
please talk to me or anyone involved is
improving yet
and of course we need user-friendly
front end is yeah people some people are
happy to use the comment line but others
would be much more happy to have a nice
web prompting to create manage and view
and interact with all these repos one
important aspect there with improving
the issue tracking and the pull request
would get this wouldn't be only for
mango if you have all these things
waiting it itself no matter where you
take your repository or your data
including your issues and your pull
request will stay with you and I hope
actually github and get lab and other
bigger companies using it would be able
to support some of these features so you
could freely move between mango and the
decentralized the website or additional
eyes up and between these services
without any hassle well thank you for
listening I think now it's the time to
check out mango and actually no one
believes this but it works already so
you could try it out and thank you thank
you Alex
you