►
From YouTube: .NET Design Review: JSON
Description
Today, we're reviewing one open issue with JSON:
* https://github.com/dotnet/corefx/issues/36639
A
D
D
So
a
given
percentage,
you
know,
25%,
plus
or
minus
you
know,
50%
of
the
people
probably
wouldn't
be
able
to
use
the
serializer
if
they
have
custom
data
types
or
if
they
have
other
scenarios
that
require
manual
DC,
realization
of
a
poco
type.
For
other
reasons.
So
this
is
considered.
You
know
a
required
feature
coming
in
it's
composed
of
a
two
different
features.
One
is
these
on
XXX
callbacks,
which
are
like
callbacks
for
easter,
realization
of
certainly
and
sterilization.
D
Before
and
after
these
also
this
this
feature
exists
on
system
reflection,
our
sorry
Liga,
certain
systems,
fertilization,
namespace
as
well,
and
the
other
feature,
then,
is
the
ability
to
have
your
own
converter,
which
can
be
either
for
poco
type
or
for
a
value
type.
Like
you
know,
a
phone
number
value
type
and
also
acid.
It
has
a
feature
or
some
notes
later,
that
required
some
changes
to
the
to
the
writer
to
support
as
a
matter
property
name,
to
support
this
programming
model.
D
A
D
So
I
put
that
in
the
open
discussions
on
the
way
bottom,
but
so
the
original
discussion
about
custom
attributes
when
we
were
first
there
working
on
the
sterilizer
was
all
supported.
Attributes
should
derive
from
a
common
base
class
which
is
Jason
attribute.
It
helps
with
discoverability
for
one.
You
know
it
allows
us
to
make
changes
you
know
to,
but
I
do
list
that
as
an
option
to
say:
hey,
we
don't
have
to
add
these.
You
know
new
attributes.
We
can
this.
B
A
Think
in
general,
like
I,
don't
think
we
should.
We
use
the
existing
attributes
per
se,
because
from
a
user
standpoint
now
you
import
both
names,
whether
you
have
a
complete
mixture
of
civilization
with
the
stuff
and
it's
very
hard
to
reason
about
which
one's
applied
to
both
and
which
one's
apply
to
just
one
of
them.
I.
G
A
D
Like
this
again
currently
system
serialization
and
it's
just
empty
that
wasn't
another
open
discussion,
but
but
we
decided
that
we'll
just
support
an
empty
method
in
the
future.
If
we
wanted
to
pass
an
options
or
something
like
that,
we
could.
But
for
you
know,
step
one,
it's
just
an
empty
method.
Only
yeah.
A
That
makes
sense
all
I'm
saying
like
how
would
I
know
that
I
groove
on
interface
there's
a
pattern
where
I
just
implement
the
interface,
and
then
you
know
everything
else
from
there
just
works
it
aren't.
You
think
about
signature
like
the
signature
is
given.
I
can
decide
to
make
it
private,
but
you
know
if
I
used
by
doing
an
exposition
to
it.
Implementation.
I,
don't
have
to
think
about
this.
With
this
there's
a
bunch
of
questions.
I
just
have
to
read
the
docs
on
now,
meaning,
what's
the
signature,
does
it
have
to
be
public?
A
H
Model,
and
also
even
if
you
implement
the
interface
explicitly,
you
still
I
mean
you
know
you
have
a
type
and
it
implements
an
interface
and
it's
an
implementation
detail
for
the
civilization.
But
having
said
that,
if
I
understand
correctly,
there
are
two
different
modes,
you
can
implement
this
interface
or
if
we
had
an
interface
either
on
a
time
or
on
the
like
a
converter
box
secret.
H
D
Yeah,
certainly
the
design
is.
You
have
to
put
these
on
a
tight
beam
deserialize.
So
that's
either
your
data
type
for
your
vocal
and
then
you
have
the
different
feature
that
allows
you
write,
a
converter
with
which
you
can
do
the
same
things.
You
can
get
these
four
hooks,
but
that
doesn't
have
to
be
on
your
photo.
In
fact,
it
can't
be
on
your
poll,
cool.
D
So
the
ability
to
write
your
own
converter
allows
you
to
you,
know
manually,
set
your
own
fields
and
get
in
the
reader
or
the
writer
and
the
options
and
then
really
pull
your
own.
You
know
derealization
serialization.
These
attributes
are
just
simple
callbacks
on
your
pokel
kind
of
ignoring
the
lower
level.
Details
of
you
know
fertilization,
so
so,
for
example,
these,
if
you
implement
these
one
of
these
four
methods,
you
don't
have
access
to
the
reader
or
the
right
or
anything
you're.
Basically,
just
fixing
up
your
object.
You
know
before
and
after
easter
light.
H
What
I
was
asking
is,
could
I
add
those
four
simple
members
to
my
comparator
time.
Instead
of
adding
them
directly
to
the
back
of
I
I
know
like
maybe
we
want
to
enable
you
know,
adding
methods
to
Paco,
but
I
may
not
own
the
pocke
types
and
if
we
don't
enable
me
to
end
these
simple
methods
where
proxy
celebration,
proxy
or
comparator,
then
I
think
I'm,
basically
stuck
with
low-level
API
sand.
I
have
to
use
my
you
know
either
in
the
right
there.
So
does.
I
H
D
Helpers,
they
throw
down
a
little
bit
more
because
that
there
are
read
and
write
method.
So
if
you
try
to
emulate
the
the
before
and
after
callbacks,
using
a
converter,
which
of
course
not
on
the
poco,
you
would
have
to
implement.
Try,
read
and
write
and
you'd
put
your
before
and
after
code
before
the
call
to
the
reader
of
the
writer.
But
you
would
have
to
write
that
line
of
code
or
whatever
to
call
back
into
the
circle
Iser.
So
you
can
still
do
it
but
yeah
it's
it's
not.
H
What
I
was
getting
at
imagine
that
we
basically
had
this
interface,
because
there
is
one
interface
as
he
was
saying,
it
makes
the
signature
super
clear
and
we
allowed
people
to
implement
the
interface
either
on
the
comparator
or
on
the
pocket.
Id
then
like.
If
you
just
want
to
implement
the
interface
and
you
don't
care
about
the
pocket
I'm
coming
in
the
interface,
you
know
implement
the
implementation,
you
do
it
if
you
do
care
and
implement
it
on
the
converter
and
you
have
the
best
of
both
worlds.
E
H
H
Oh
no
I
don't
want
to
yeah
better
than
time.
I,
don't
want
to
implement
it
in
their
face
and
heat
that
they
stop
like.
So,
for
example,
I'm
thinking
about
like
a
juridical
scenarios,
there
are
those
mother
dies.
We
want
them
to
like
look
like
beautiful
dotnet
database.
We
don't
want
any
serialization
cool
to
show
up
in
the
public
surface
area,
so.
G
H
I
E
Now
it
has
the
problem
that
I
just
mentioned
a
few
minutes
ago,
where
presumably
these
methods
are
intended
to
change
private
implementation.
Details
of
the
object
you
now
need
to
make
all
of
your
fields
internal
or
it's
just.
How
are
you
breaking
cancellation
or
just
have
a
nested,
strap
right,
yeah,
but
must
obstruct
me
and
if
you
are
touching
the
original
type.
A
B
A
F
I
I
Of
cetera
it's
like,
then,
you
don't
need
the
side
loading,
it's
just
the
converter
is
the
external
and
then
attribute
or
interface
or
whatever
is
the
micelle,
and
then
all
that
you're
missing
is
the
I
wish
that
you
would
now
given
me
a
coat
hook,
but
I
wish
that
you
would
now
do
the
thing
that
you
did.
If
I
wasn't
here,
I.
G
G
D
G
E
I
D
Say
that
the
original
prototype
had
an
interface
head
for
interfaces
actually
one
through
each
of
the
on
methods
and
they
did
take
the
object
and
they
did
take
the
reader
and
you
could
implement
it
on
the
poco
or
some
other
class
on
the
side.
I
mean
and
I
can
share
that.
You
know
in
this
meeting.
If
you
want
to
spirit
it
like
the
original
one.
D
E
A
A
H
H
D
D
Mean
like,
like
I
said
originally
in
the
prototype
and
I,
can
share
that
since
I
I
mean
I
had
if
I
want
to
look
up,
the
original
prototype
I
had
for
this
I
did.
I
did
consider
that
you
know
having
these
four
callbacks
that
could
also
perform
read,
writes
if
you
want
it
to
and
I
would
pass
in
everything
passing
the
options
reader
and
then
you
could
implement
that,
like
I
said
yeah
they're
on
the
poco
or
on
another
class
on
that
you'd
have
to
register
and
I
think
that
was
fine.
D
I
think
the
most
feedback
I've
gotten
so
far
is
that
this
is
an
existing
pattern.
You
know
used
by
Jason
net
used
by
system
sterilization
it's
a
common
pattern
to
place
these
four
attributes
on
and
then
and
then
for
the
other
part,
the
converter
feature
on
this
is
also
a
common
pattern
similar
to
you
know
other
serializers
that,
where
you
have
to
register
a
converter
that
doesn't
exist
on
the
Polka
code,
so.
F
D
D
Oh,
it's
data,
isn't
bellator
missing.
You
know,
there's
missing
properties,
that
sort
of
thing
and
these
callbacks,
but
the
idea
is
that
you
don't
necessarily
get
to
you.
Don't
even
know
how
you're
being
serialized
you
know
to
what
so
that's
the
reason
you
don't
have
a
reader
or
a
writer
or
anything
like
that.
You
can
kind
of
keep
your
object
as
an
object
and
not
you
know,
try
to
add
some
interface
to
it.
D
D
I
The
drawback
of
the
attributes
is
you
have
to
look
at
documentation
to
understand
what
your
method
signature
is
supposed
to
be.
They're
all
zero
argument,
that's
fairly
easy
to
understand.
There's
a
policy
and
model
question
that
has
to
be
answered
of.
If
I
have
three
on
deserializing
are
they
all
called?
Is
the
order
deterministic
or
does
it
throw
that
this
type
can't
be
deserialized,
because
it's
in
an
invalid
state,
pretty
serialization
and
then
I
have
Committee
on
deserialized?
That's
the
event.
I
H
We
are
trading
in
these
kind
of
knobs,
or
this
civilization
and
I
don't
know
where
it
ends,
meaning
we
already
had
some
questions
like
what
happens
if
you
can
pull
the
comparator
and
these
metals,
which
they
express,
like
all
the
rules
of
what
ultimately
type
in
someone's
keyboard,
is
very
loud.
It's
hard
here,
you
so
I,
totally
mine,
because
I'm
typing
the
notes
like
that,
the
rules
you
know
where
we,
when
we,
when
we
end
when
we
are
done
with
all
the
knobs.
H
H
First,
I'm
not
pushing
back
on
the
only
thing
that
I'm,
the
only
thing
kind
of
substantial
against
that
I
said
is:
if
you
guys
want
to
design
a
supervisor
for
our
SDK
it,
there
is
one
requirement
we
want
to
be
literally
in
full
control
of
the
type
of
their
public's
times.
We
don't
want
to.
Oh,
you
have
to
implement
some
interface
or
you
have
to
do
something
right.
So
that's
the
only
thing
that
I
kind
of
used
shown
me
once
we
want
to
support
our
SDK,
not
this
serializer.
H
The
rest
is
just
like
I've
seen,
serializers
evolving
over
time
and
in
tonight
starts
with
simple
notes,
and
then
we
discover
that
we
have
a
whole.
So
then
we
had
another
now
and
then
we
had
another
now
and
the
way
that
we
had
and
another.
And
then
you
have
to
explain
to
people
what
is
the
precedence
of
all
these
notes,
and
sometimes
we
end
up
with
with
too
many
knobs
like
if
we
from
the
get-go
started
with
you
know,
analyzing
all
the
things
that
we
need
to
do
and
designing
it.
A
Yeah
I
mean
to
me
it's
very
similar
to
our
design,
a
language
right.
You
basically
have
two
who
ask
how
these
things
interrelate
with
each
other
right,
because
you
can
always
apply
all
these
knobs
and
then
the
question
is:
what
happens
if
three
of
them
are
active
at
the
same
time?
What's
the
what's
the
state
and
even
if
we
know
the
precedence
will
do
you
may
not
be
aware
that
you
just
created
something
that
is
actually
illegal
right
or
that
is
nonsensical
or
has
undesired
behavior?
F
D
F
What's
the
action
I
didn't
want
to
call
back,
gave
you
guys,
especially
because
I
think
we
sure
to
spend
the
next
little
bit
on
the
converters,
but
that's
accurate
environment
that
people
from
yes
me
as
others
have
probably
right,
I've
been
keeping
the
badges.
Are.
We
saying
we
put
the
whole
future
was
Rijo?
Has
the
EFT.
J
E
E
H
H
If
I
was
basically
designing,
this
I
would
say
there
are
pocket
eyes
and
they
are
very,
very
simple,
and
maybe
you
can
have
some
like
simple
attributes
to
basically
say
hello.
You
know
change
casing
or
do
something.
That's
it.
If
you
want
more
like
powerful
customization,
you
never
have
a
separate
time.
You
do
like.
We
give
you
all
the
powers,
all
the
knobs
everything
you
literally
can
even
read
the
whole
object
from
the
reader
and
give
me
the
result
and
that
we
skip
reading
all
the
objects,
and
that's
that's
it.
H
It
seems
to
me
like
we
have
like
many
layers
like
this.
You
know
Paco
objects,
you
can
apply
attributes,
you
can
then
add
civilization
callbacks
to
the
object,
and
you
can
have
converters
and
it's
like
too
many
places
that,
at
least
for
me
it
would
be
difficult
to
wrap
my
head
around
like
which
executes
when
in
what?
With
order
and.
A
I
mean
to
answer
a
sense
original
question
like
what
is
the
pushback
on
the
attributes.
I
can't
articulate
this
because
my
problem
is
similar
to
crystals
in
the
sense
that
I
need
to
think
about
how
this
feature
and
the
other
theatres
compose,
and
in
order
for
me
to
even
have
an
opinion
or
whether
there
is
a
problem,
but
there
might
be
no
problem,
it's
possible,
it's
just
compose
as
cleanly,
but
it's
hard
to
do
this
in
10
minutes,
but
I
think
the
one
thing
I
would
push
back
on.
A
What
Chris
have
just
said
is
that,
like
I
think
we
cannot
have
a
civilization
of
design.
That
assumes
there
are
simple
types
over
here
and
because
I
mean
I've,
never
seen
anybody
serializing,
simplified
people
say
that,
but
in
practice
there's
always
some
additional
requirement
that
they
have
like
in
your
case,
like
what
really
need
to
control
the
class
hierarchy
or
what
we
need
to
implement
certain
interfaces
or
how
things
are
read-only
or
immutable
right
and
like.
G
A
So,
like
I
mean
in
practice,
you
kind
of
have
to
design
for
years
to
assume
the
other
type
is
almost
whatever
the
shape
is,
and
you
have
no
control
or
that
and
now
the
question
is
you
can
register
a
callback
that
says
how
do
you
want
to
see
all
eyes
this
time
right
and
once
you
have
a
generic
design
like
this
and
I
think
you
invariably
end
up
of
some
continuum,
but
you
have
more
knobs
because
well,
that's
very
heavy-handed.
If
you
do
that
right,
so
you
need
something
like.
A
D
Basically,
this
code
I
mean
I
is
scheduled,
driven
right
now
and
and
if
we
can't
decide
this
week,
there's
not
gonna
be
time
to
implement
it
before
we
have
to
be
feature
complete,
not
that
I'm
trying
to
you
know
apply
it
part
of
it
refresh
or
anything.
That's
just
the
way.
It
is
so
if
we're
not
sure
that
this
is
right,
I
would
say
we
just
kill
it
and
we
DCR
it
later,
but
the
on
xx
methods
I
mean
if
there's
pushback.
H
H
D
It's
publicly
it's
simple,
because
these
can
okay.
D
E
A
D
A
D
I'll
just
kind
of
walk
through
this
quickly.
The
first
part
here
by
the
way
the
namespace
wrong
is
for
this
options
class.
It
recently
got
moved
it's
not
in
the
sterilization,
namespace
anymore,
but
I
forgot
to
move
it
up,
putting
either
case.
There's
a
new
method
called
converters,
and
this
is
where
you,
you
would
add,
a
converter
at
runtime.
There's
also
an
attribute
right
below
that
Jason
converter
attribute
that
you
can
add
to
a
class
or
a
property
to
say
what
your
converter
type
is.
D
H
D
Yes,
so
if
you
have
a,
this
would
be
a
one-off
case
that
you
would
put
on
your
focal
object
or
a
property
on
a
poco,
but
you
would,
you
would
say,
hey
here's
a
poco
object.
I
want
to
put
this
attribute
on
it.
Call
this
converter
when
you
need
to
deserialize
and
sterilize,
or
you
can
do
that
in
a
property
level.
You.
H
D
H
A
D
Yeah,
do
I
have
examples
down
below
of
a
polymorphic
scenario
and
like
a
customer
person
employee
that
you
write
one
converter
for
and
then
that
converter
will,
you
know,
do
the
right
thing
based
upon
a
type
discriminator,
I'm,
a
Jason.
A
What
one
is
the
simple
case
where
you
just
point
to
the
type
of
the
converter,
the
other
one
is
you
derive
from
it
and
you
basically
like
insane
yet
the
converting
itself,
which
is
basically
the
virtual
method
right.
They
probably
should
be
different
types,
but,
like
that's,
I,
think
the
general
idea,
in
which
case
you
know
case,
you
would
only
have
one
attribute
that
would
know
about
all
the
types
ers
DK
cares
about,
and
then
you
just
do
a
you
know.
If
type
is
this
mistake,
this
instantiate
that.
J
A
D
E
G
A
J
G
D
Chapel's
below,
but
I'm
just
gonna,
throw
this
out
quick,
is
that
originally
I
had
a
factory
method
on
that
Jason
converter,
the
non-generic
one
that
says
create
the
real
converter
and
that
allowed
similar
to
how
the
attribute
house
it
and
I
got
some
feedback
on
that
said.
Do
we
really
need
that
and
I
took
it
off
and
I
there's
still
reasons
to
have
that
and
then
in
that
case
you
would
actually
derive
directly
from
the
non-abstract
class.
If
you
needed
a
factory
pattern.
Well,.
G
I
I
think
this
is
a
case
where
you
just
want
to
have
one
converter.
That's
a
shared
instance.
That's
reused
over
and
over
because
it
just
has
all
the
logic
contained
in
itself
into
methods,
because
you
don't
actually
need
like
a
separate
type
for
every
te.
You
want
to
support
you
only
you
need
for
a
body
that
is
good
and.
H
I
almost
wonder
whether
we
shouldn't
have
there's
a
you
know:
reference
type
comparator
and
value
type,
comparator
reference
type
converter
and
just
developed
one
of
them.
I
don't
want
to
have
25
in
Texas.
You
know,
I
have
a
complicated
object
graph
and
it
has
many
classes.
I
don't
want
to
have,
but
then,
if
you
have
one,
how
do
you
implement
it?
If
they're.
G
E
It
means
I,
don't
have
gleeg
house
in
my
code,
because,
if
I'm,
if
I'm
operating
with
something
that's
a
person,
yeah
right
but
I-
need
to
cast
it
back
to
a
tea
like
the.
G
Right
because
in
because
in
the
method,
you
can
do
you,
you
can
either
do
if
type
of
T
equals
blog
and
call
this
method
or
you
can
use
the
new
c-sharp,
a
pattern
matching
which,
with
which
uses
a
type
switch,
which
will
just
do
the
same
thing
but
really
pretty
code,
and
then
the
gym
will
specialize
it
correctly.
So
if
it's
a
value
type,
you
all
be
non
everything
that
isn't
the
exact
T
will
get
dropped
and
in
the
reference
type,
all
the
value
types
get
dropped.
But.
H
G
G
G
A
People
things
no
like
think
about
coming
for
metal
versus
one
of
the
air,
has
decayed
I
have
like
500
times
right.
So
there
is
probably
some
logical
set
of
types.
I
did
say:
I,
don't
know
a
bunch
of
times.
I
do
units
find
meters
in
blah
blah
blah
right.
You
can
just
encapsulate
them
in
one
time
and
then
basically
because
they're
all
virtually
more
or
less
the
same,
you
don't
want
to
have
25
implementations
of
something
you.
A
G
D
Let's
just
and
let's
I
think
we
I
mean
we
have
five
minutes
left
I
want
to
go
over
the
mainstream
scenarios,
which
is
this
particular
scenario,
is
a
very
mainstream
scenario.
I
have
a
polymorphic
case.
This
is
how
the
current
design,
unless
you
do
it
you
know,
and
and
if
we
want
to
optimize
for
twenty
different
strikes,
blah
blah
blah-
that's
probably
going
to
be
a
different
design.
E
F
A
E
Here
in
terms
of
load,
this
coat
finish
or
certainly
yeah
yeah.
The
right
method,
I
think,
is
actually
a
good
example
of
a
very
straightforward
right.
Nothing
I
would.
A
A
D
E
No
like
so
like
I
should
be
not
what
happen
is
the
very
first
line
of
code.
People
right
here
will
be
reader
dot
we'd
like
reader
docket
string
immediately
pass
it
into
activator
to
create
instance,
and
now
there
are
applications
owned,
because
that's
the
easiest
most
straightforward
way
to
do
polymorphism.
If
we
don't
have
an
answer.
That
is,
if
we
don't
have
an
answer
that
is
at
most
two
lines
of
code
yeah,
the
two
lines
of
code
I
just
listed
will
be
whatever
one
writes.
D
That
we
is
out
of
scope.
We
can't
prevent
people
from
doing
this
by
the
way.
If
we
have
a
converter
model,
I
mean
they
can
do
whatever
they
want.
So
this
is
an
example
of
us.
You
know
some
people
want
to
do
this,
but
we
will
not
have
for
v3
a
way
to
do.
Polymorphic,
D
serialization,
without
use
without
converting
to
this
adjacent
element.
Type,
which
is
you
know,
name
value
pairs,
yeah
Jason
net,
doesn't
have
that.
Then
they
actually
embed
the
actual
type
in
the
in
the
JSON,
which
is
a
security
risk.
D
D
So
yeah,
okay,
we're
out
of
time
I.
Do
we
wanted
to
circle
back
around
to
these
on
xx
attributes?
Do
we
think
we
need
them
so.
D
A
D
A
D
D
Everyone
to
go
through
these
examples-
and
you
know,
with
the
case
of
the
20
strokes
and
using
the
generic
methods
instead
of
you,
know
the
type,
if
you
can
figure
out
a
way
to
factor
that
in
let
me
know
without
complicating
them.
The
mainstream
scenarios
of
you
know
normal
user
code
nod
tremor
code.