mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 17:05:55 +08:00
Thank you kindly, Tlaukkan (Tommil) for a patch that:
Fixed all NHibernate unit tests by implementing missing persistency methods, tables, columns and fixing bugs in the existing implementation. Two minor changes to classes outside NHibernate module: Added Scene instantiation for SceneObjectGroup in OpenSim.Data.Tests.BasicRegionTest as this was required by the NHibernate persistency. In the process added also mock constructor to Scene which only populates RegionInfo in the scene which is used by ScenePart.RegionUUID. NHibernate module is still in experimental state and has not been tested at opensim region or ugaim runtime configuration. Adding unit tests to build is not yet advisable nor using NHibernate module in any production setup.
This commit is contained in:
@@ -2,25 +2,32 @@ BEGIN TRANSACTION;
|
||||
|
||||
create table Prims (
|
||||
UUID TEXT not null,
|
||||
RegionID TEXT,
|
||||
GroupID TEXT,
|
||||
ParentID INTEGER,
|
||||
ParentUUID TEXT,
|
||||
RegionID TEXT,
|
||||
OwnerID TEXT,
|
||||
LastOwnerID TEXT,
|
||||
CreatorID TEXT,
|
||||
CreationDate INTEGER,
|
||||
LinkNum INTEGER,
|
||||
Name TEXT,
|
||||
Text TEXT,
|
||||
Description TEXT,
|
||||
SitName TEXT,
|
||||
TouchName TEXT,
|
||||
ObjectFlags INTEGER,
|
||||
CreatorID TEXT,
|
||||
OwnerID TEXT,
|
||||
GroupID TEXT,
|
||||
LastOwnerID TEXT,
|
||||
OwnerMask INTEGER,
|
||||
NextOwnerMask INTEGER,
|
||||
GroupMask INTEGER,
|
||||
EveryoneMask INTEGER,
|
||||
BaseMask INTEGER,
|
||||
Material INTEGER,
|
||||
ScriptAccessPin INTEGER,
|
||||
TextureAnimation BLOB,
|
||||
ParticleSystem BLOB,
|
||||
ClickAction INTEGER,
|
||||
Color INTEGER,
|
||||
PositionX NUMERIC,
|
||||
PositionY NUMERIC,
|
||||
PositionZ NUMERIC,
|
||||
@@ -99,4 +106,45 @@ create table PrimItems (
|
||||
primary key (ItemID)
|
||||
);
|
||||
|
||||
COMMIT;
|
||||
CREATE TABLE RegionSettings (
|
||||
RegionID TEXT not null,
|
||||
BlockTerraform BIT,
|
||||
BlockFly BIT,
|
||||
AllowDamage BIT,
|
||||
RestrictPushing BIT,
|
||||
AllowLandResell BIT,
|
||||
AllowLandJoinDivide BIT,
|
||||
BlockShowInSearch BIT,
|
||||
AgentLimit INTEGER,
|
||||
ObjectBonus NUMERIC,
|
||||
Maturity INTEGER,
|
||||
DisableScripts BIT,
|
||||
DisableCollisions BIT,
|
||||
DisablePhysics BIT,
|
||||
TerrainTexture1 TEXT,
|
||||
TerrainTexture2 TEXT,
|
||||
TerrainTexture3 TEXT,
|
||||
TerrainTexture4 TEXT,
|
||||
Elevation1NW NUMERIC,
|
||||
Elevation2NW NUMERIC,
|
||||
Elevation1NE NUMERIC,
|
||||
Elevation2NE NUMERIC,
|
||||
Elevation1SE NUMERIC,
|
||||
Elevation2SE NUMERIC,
|
||||
Elevation1SW NUMERIC,
|
||||
Elevation2SW NUMERIC,
|
||||
WaterHeight NUMERIC,
|
||||
TerrainRaiseLimit NUMERIC,
|
||||
TerrainLowerLimit NUMERIC,
|
||||
UseEstateSun BIT,
|
||||
Sandbox BIT,
|
||||
SunVectorX NUMERIC,
|
||||
SunVectorY NUMERIC,
|
||||
SunVectorZ NUMERIC,
|
||||
FixedSun BIT,
|
||||
SunPosition NUMERIC,
|
||||
Covenant TEXT,
|
||||
primary key (RegionID)
|
||||
);
|
||||
|
||||
COMMIT;
|
||||
|
||||
@@ -12,15 +12,24 @@ create table UserAgents (
|
||||
LoginTime INTEGER,
|
||||
LogoutTime INTEGER,
|
||||
Handle INTEGER,
|
||||
PositionX NUMERIC,
|
||||
PositionY NUMERIC,
|
||||
PositionZ NUMERIC,
|
||||
LookAtX NUMERIC,
|
||||
LookAtY NUMERIC,
|
||||
LookAtZ NUMERIC,
|
||||
primary key (ProfileID)
|
||||
);
|
||||
|
||||
create table UserProfiles (
|
||||
ID TEXT not null,
|
||||
WebLoginKey TEXT,
|
||||
FirstName TEXT,
|
||||
SurName TEXT,
|
||||
Email TEXT,
|
||||
PasswordHash TEXT,
|
||||
PasswordSalt TEXT,
|
||||
WebLoginKey TEXT,
|
||||
HomeRegionID TEXT,
|
||||
HomeRegionX INTEGER,
|
||||
HomeRegionY INTEGER,
|
||||
HomeLocationX NUMERIC,
|
||||
@@ -31,15 +40,22 @@ create table UserProfiles (
|
||||
HomeLookAtZ NUMERIC,
|
||||
Created INTEGER,
|
||||
LastLogin INTEGER,
|
||||
RootInventoryFolderID TEXT,
|
||||
UserInventoryURI TEXT,
|
||||
UserAssetURI TEXT,
|
||||
Image TEXT,
|
||||
FirstLifeImage TEXT,
|
||||
AboutText TEXT,
|
||||
FirstLifeAboutText TEXT,
|
||||
RootInventoryFolderID TEXT,
|
||||
`CanDoMask` INTEGER,
|
||||
`WantDoMask` INTEGER,
|
||||
`UserFlags` INTEGER,
|
||||
`GodLevel` INTEGER,
|
||||
`CustomType` TEXT,
|
||||
`Partner` TEXT,
|
||||
primary key (ID)
|
||||
);
|
||||
|
||||
create table UserAppearances (
|
||||
Owner TEXT not null,
|
||||
BodyItem TEXT,
|
||||
@@ -71,9 +87,22 @@ create table UserAppearances (
|
||||
Texture BLOB,
|
||||
VisualParams BLOB,
|
||||
Serial INTEGER,
|
||||
AvatarHeight NUMERIC,
|
||||
primary key (Owner)
|
||||
);
|
||||
create index user_firstname on UserProfiles (FirstName);
|
||||
create index user_surname on UserProfiles (SurName);
|
||||
|
||||
COMMIT;
|
||||
|
||||
CREATE TABLE UserFriends (
|
||||
UserFriendID TEXT,
|
||||
OwnerID TEXT,
|
||||
FriendID TEXT,
|
||||
FriendPermissions INTEGER,
|
||||
primary key (UserFriendID)
|
||||
);
|
||||
|
||||
create index UserFirstNameIndex on UserProfiles (FirstName);
|
||||
create index UserSurnameIndex on UserProfiles (SurName);
|
||||
create unique index UserFullNameIndex on UserProfiles (FirstName,SurName);
|
||||
create unique index UserFriendsOwnerFriendIndex on UserFriends (OwnerID,FriendID);
|
||||
|
||||
COMMIT;
|
||||
|
||||
Reference in New Issue
Block a user