6.4.4. Registering Advanced Externalizers
The following is an example of a declarative configuration for an advanced Externalizer implementation:
<infinispan> <global> <serialization> <advancedExternalizers> <advancedExternalizer externalizerClass="Person$PersonExternalizer"/> </advancedExternalizers> </serialization> </global> ... </infinispan>
The following is an example of a programmatic configuration for an advanced Externalizer implementation:
GlobalConfigurationBuilder builder = ... builder.serialization() .addAdvancedExternalizer(new Person.PersonExternalizer());
The following is a declarative configuration for the location of the identifier definition during registration:
<infinispan> <global> <serialization> <advancedExternalizers> <advancedExternalizer id="123" externalizerClass="Person$PersonExternalizer"/> </advancedExternalizers> </serialization> </global> ... </infinispan>
The following is a programmatic configuration for the location of the identifier definition during registration:
GlobalConfigurationBuilder builder = ... builder.serialization() .addAdvancedExternalizer(123, new Person.PersonExternalizer());