Database Changes After Adding Liferay Account Group
Created: 5 December 2024 Modified:What data changes occur when an account group is added to Liferay. Added account group Rock Seller Managers. This user was added by administrator user Test Test with email test@test.com. Keep in mind that Liferay doesn’t enforce referential integrity in the database. Instead it is “enforced” in the code.
Many tables have columns classNameId and classPK. These act as a psuedo foreign key to the ClassName_ table. The ClassName_ table basically references Java classes. These Java classes have associated database tables. ClassPK contains an identifier that references a row in the table. This seems to be used to add levels of abstraction for second order relationships.
Liferay has many moving parts. I did not include tables that were changed but did not appear to be associated with adding the new user. Original data dumps containing all changes are available. Removed tables are as follows
- Counter
Tables that were changed after adding the new account group Rock Seller Managers.
- AccountGroup
- Table to store account group data.
- Primary key is accountGroupId.
- Row was added for Rock Seller Managers.
- AccountGroupId for Rock Seller Managers is 32703.
- AccountGroupRel
- Table to store data defining the relationships between accounts and groups.
- Primary key is accountGroupRelId.
- Row was added for Rock Seller Managers.
- AccountGroupRelId value is 32704
- AccountGroupId value is 32703.
- ClassNameId was 28707 with ClassPk of 32503. Which points to com.liferay.account.model.AccountEntry in the ClassName_ table.
- ResourcePermission
- Table to track permissions to resources such as portlets and models.
- OwnerId was 20123 which points to the Test Test user.
- Row added for account group 32703
- Name value is com.liferay.account.model.AccountGroup.
- PrimKey value is 32703.
Diagram is only showing the relationships most relevant.
Resources
tags: java - liferay ce - liferay - ce - mariadb - fedora - 41 - fedora 41 - linux - account - group