added generics to ChainsManager