aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Grid/UserServer/Main.cs
diff options
context:
space:
mode:
authorMW2007-12-01 18:49:17 +0000
committerMW2007-12-01 18:49:17 +0000
commit5df851761aa796cba70a3b6d8b36d119502c1de2 (patch)
tree4cab0f2d6ea32a6cfb280d74583d8ffce7331c26 /OpenSim/Grid/UserServer/Main.cs
parentAttempt to fix mantis issue # 65, seems like it is a race condition between t... (diff)
downloadopensim-SC_OLD-5df851761aa796cba70a3b6d8b36d119502c1de2.zip
opensim-SC_OLD-5df851761aa796cba70a3b6d8b36d119502c1de2.tar.gz
opensim-SC_OLD-5df851761aa796cba70a3b6d8b36d119502c1de2.tar.bz2
opensim-SC_OLD-5df851761aa796cba70a3b6d8b36d119502c1de2.tar.xz
Initial working Grid Inventory server. Only been tested on a very small grid, so likely to have problems on a larger grid with more people?
To use , both the user server and Inventory server need to be running this latest revision. (older regions should be able to still be used, just the user won't have inventory on them). Also and HERE IS THE BIG BREAK ISSUE, currently, so that the initial inventory details for a user are added to the inventory db , you need to recreate the accounts using the user server "create user" feature. It should be quite easy to manual populate the inventory database instead but I someone else will need to look into that) Also I've only tested using SQLite as the database provider, there is a Mysql inventory provider but I don't know if it works (SQLite is set as default, so you will need to change it in the inventory server config.xml)
Diffstat (limited to '')
-rw-r--r--OpenSim/Grid/UserServer/Main.cs19
1 files changed, 18 insertions, 1 deletions
diff --git a/OpenSim/Grid/UserServer/Main.cs b/OpenSim/Grid/UserServer/Main.cs
index 779a72b..b00bb76 100644
--- a/OpenSim/Grid/UserServer/Main.cs
+++ b/OpenSim/Grid/UserServer/Main.cs
@@ -27,7 +27,9 @@
27*/ 27*/
28 28
29using System; 29using System;
30using System.Collections.Generic;
30using System.IO; 31using System.IO;
32using libsecondlife;
31using OpenSim.Framework; 33using OpenSim.Framework;
32using OpenSim.Framework.Console; 34using OpenSim.Framework.Console;
33using OpenSim.Framework.Servers; 35using OpenSim.Framework.Servers;
@@ -44,6 +46,7 @@ namespace OpenSim.Grid.UserServer
44 public UserLoginService m_loginService; 46 public UserLoginService m_loginService;
45 47
46 private LogBase m_console; 48 private LogBase m_console;
49 private LLUUID m_lastCreatedUser = LLUUID.Random();
47 50
48 [STAThread] 51 [STAThread]
49 public static void Main(string[] args) 52 public static void Main(string[] args)
@@ -123,7 +126,9 @@ namespace OpenSim.Grid.UserServer
123 126
124 tempMD5Passwd = Util.Md5Hash(Util.Md5Hash(tempMD5Passwd) + ":" + ""); 127 tempMD5Passwd = Util.Md5Hash(Util.Md5Hash(tempMD5Passwd) + ":" + "");
125 128
126 m_userManager.AddUserProfile(tempfirstname, templastname, tempMD5Passwd, regX, regY); 129 LLUUID userID = m_userManager.AddUserProfile(tempfirstname, templastname, tempMD5Passwd, regX, regY);
130 RestObjectPoster.BeginPostObject<LLUUID>(m_userManager._config.InventoryUrl + "CreateInventory/", userID);
131 m_lastCreatedUser = userID;
127 break; 132 break;
128 } 133 }
129 } 134 }
@@ -145,9 +150,21 @@ namespace OpenSim.Grid.UserServer
145 m_console.Close(); 150 m_console.Close();
146 Environment.Exit(0); 151 Environment.Exit(0);
147 break; 152 break;
153
154 case "test-inventory":
155 // RestObjectPosterResponse<List<InventoryFolderBase>> requester = new RestObjectPosterResponse<List<InventoryFolderBase>>();
156 // requester.ReturnResponseVal = TestResponse;
157 // requester.BeginPostObject<LLUUID>(m_userManager._config.InventoryUrl + "RootFolders/", m_lastCreatedUser);
158 List<InventoryFolderBase> folders = SyncRestObjectPoster.BeginPostObject<LLUUID, List<InventoryFolderBase>>(m_userManager._config.InventoryUrl + "RootFolders/", m_lastCreatedUser);
159 break;
148 } 160 }
149 } 161 }
150 162
163 public void TestResponse(List<InventoryFolderBase> resp)
164 {
165 System.Console.WriteLine("response got");
166 }
167
151 /*private void ConfigDB(IGenericConfig configData) 168 /*private void ConfigDB(IGenericConfig configData)
152 { 169 {
153 try 170 try