Of the interface or class on the other end. Any implementation of these types will be mapped to an implementation Collection typesĬorda supports the collection types listed below. This section describes the classes and interfaces that the AMQP serialization format supports. The AMQP serialization format willĬontinue to apply the whitelisting functionality that is already in place and described in this page. Of CorDapp developers, to allow CorDapps to take into consideration the future state. This document describes what is currently and what will be supported in the Corda AMQP format from the perspective Selection of serialization context is usually opaque to CorDapp developers. Conversely,Ĭorda’s AMQP framework lets users concentrate on creating a secure framework that can be reasoned about and made safer. However, that flexibility makes it difficult to secure.
Than Corda’s AMQP framework in what it can construct and serialize. Kryo is more suited to the serialization of a program’s stack frames, as it is more flexible This separation of serialization schemes into different contexts lets Corda use the most suitable framework for a context, rather thanĪttempting to force a one-size-fits-all approach.
Deserialized objects go through supported constructors, rather than havingĭata inserted directly into their fields without an opportunity to validate consistency or intercept attempts to manipulate This is key to many Corda concepts, such as states. Support for open-ended polymorphism, where the number of subclasses of a superclass can expand over time,Īnd subclasses do not need to be defined in the schema upfront.
Java reflection to serialize code#
Ease of writing generic code - for example, user interfaces that can navigate the serialized form of data.Improved versioning, enabling easier interpretation of archived data (for example, trades fromĪ decade ago, long after the code has changed) and differing code versions.The benefits of Corda’s system include:Ī schema describing what has been serialized included with the data. Weakly or untyped string-based serialization schemes, such as JSON or XML. Corda’s custom, type-safe binary serializationĬorda uses a custom form of type-safe binary serialization, which is more secure than systems that use Messages, when the node sends objects to or from RPC clients, and when you store transactions in the database.
These two processes take place every time nodes pass objects to each other as Process, creates objects from a stream of bytes. Serialization converts objects into a stream of bytes.