String applicationName = module.layer().application().name();
Preferences root = Preferences.userRoot();
Preferences node = root.node( applicationName );
PreferencesEntityStoreInfo info = new PreferencesEntityStoreInfo( node );
ServiceDeclaration service = module.services( PreferencesEntityStoreService.class )
.setMetaInfo( info )
.visibleIn( visibility() )
.instantiateOnStartup();
if( hasIdentity() )
{
service.identifiedBy( identity() );
}
module.services( UuidIdentityGeneratorService.class ).visibleIn( visibility() );
}