I have updated the implementation to have the portlet state object model and the registration model integrated by a one to many relationship.
Of course I have started to write the test case to ensure that state management is correctly done.
For now there is only one test which test that a clone before write happening under a registration context will create the clone related to that registration.