django-msgpack-serializer 1.0.0

Creator: bradpython12

Last updated:

0 purchases

django-msgpack-serializer 1.0.0 Image
django-msgpack-serializer 1.0.0 Images
Add to Cart

Description:

djangomsgpackserializer 1.0.0

Provides a msgpack serializer/deserializer for Django models instances.

Installation
Add the module msgpack_serializer.serializer to your SERIALIZATION_MODULES setting:
SERIALIZATION_MODULES = {
"msgpack" : "msgpack_serializer.serializer",
}


Usage
To serialize:
from django.core import serializers

msgpack_serializer = serializers.get_serializer("msgpack")()
data = msgpack_serializer.serialize(my_objects) # returns bytes
To deserialize:
from django.core import serializers

deserialized_objects = serializers.deserialize('msgpack', data)
objs = [deserialized.object for deserialized in deserialized_objects]

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Customer Reviews

There are no reviews.