sync 4 jweb Installation GuideHow to install Sycn4jWebI am glad you are interested in my project. First of all, you don't need to torture yourself with strange ANT errors - everything in the Requirements1. You need Tomcat ( 2. You need as well MySQL. 3. In MySQL, Create one database called "sync4j" and one called "sync4j_local". The schema below needs to be imported in both databases. DROP TABLE IF EXISTS `databases`; CREATE TABLE `databases` ( `databaseid` int(11) NOT NULL auto_increment, `userid` int(11) NOT NULL default '0', `name` varchar(255) NOT NULL default , `description` varchar(255) default NULL, `lastsync` varchar(255) NOT NULL default , `nextsync` varchar(255) NOT NULL default , PRIMARY KEY (`databaseid`), UNIQUE KEY `name` (`name`,`userid`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `mapping`; CREATE TABLE `mapping` ( `localid` int(11) NOT NULL default '0', `databaseid` int(11) NOT NULL default '0', `remoteid` varchar(255) NOT NULL default , PRIMARY KEY (`localid`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `storage`; CREATE TABLE `storage` ( `localid` int(11) NOT NULL auto_increment, `databaseid` int(11) NOT NULL default '0', `value` text NOT NULL, `dirty` tinyint(4) default '1', `deleted` tinyint(4) NOT NULL default '0', PRIMARY KEY (`localid`) ) TYPE=MyISAM; DROP TABLE IF EXISTS `user`; CREATE TABLE `user` ( `userid` int(11) NOT NULL auto_increment, `username` varchar(255) NOT NULL default , `password` varchar(255) NOT NULL default , `description` varchar(255) NOT NULL default '', PRIMARY KEY (`userid`) ) TYPE=MyISAM; 4. Include these settings in your Tomcat /conf/catalina.policy file and replace {path_to_your_sync4jweb_installation} with the actual path (no curly braces :):
grant codeBase "file:${catalina.home}/webapps/syncml/-" {
permission java.security.AllPermission;
};
grant codeBase "file:${catalina.home}/webapps/sync4jweb/-" {
permission java.security.AllPermission;
};
grant codeBase "file:{path_to_your_sync4jweb_installation}/sync4jweb/build/-" {
permission java.security.AllPermission;
};
5. The file preferences.properties may need some tweaking now (database usernames, passwords etc.). Adapt where you see that the default settings are wrong. InstallationInstallation of Sync4j ServerThe Sync4j server is located in the tar.gz file at /sync4j/output/. Copy the contained folder "WEB-INF" to your "syncml" folder (which you have to create beforehand in the tomcat webapps folder). Restart Tomcat. Installation of Sync4jweb ServletIn the folder "sync4jweb", run the following command. It will install the sync4jweb servlet into tomcat. No need to restart Tomcat. $ ant install Testing the installationSync4j ServerSync4j server is located per default at sync4j WBXML This is the sync4j SyncML WBXML implemenation. Use a SyncML client to sync with this address. Learn more about sync4j at sync4j.sourceforge.net. More about SyncML in general: www.syncml.org Sync4jWeb ServletLoad Welcome to Sync4jWeb! This application lets you manage your personal contacts and calendar items. It is based on Sync4j, an open source SyncML implementation, on an improved kXML WBXML parser and on the servlet engine Tomcat. © Copyright 2004 - 2006 Nicola Fankhauser. All Rights Reserved. |