(self)
| 979 | return cfg |
| 980 | |
| 981 | def __getstate__(self): |
| 982 | state = self.__dict__.copy() |
| 983 | # We cannot pickle the connection objects, they get recreated |
| 984 | # upon unpickling |
| 985 | state.pop('_redis') |
| 986 | state.pop('_buffer') |
| 987 | return state |
| 988 | |
| 989 | def __setstate__(self, state): |
| 990 | self.__dict__ = state |