ISPN-4678 Trim down ExpandableMarshalledValueByteStream to the actual data length before storing in cache
ISPN-4563 Create unit test to replicate concurrency issue

Change-Id: Id381cc57965b8520111ad5337c619d8d9b4e75aa