<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:clearspace="http://www.jivesoftware.com/xmlns/clearspace/rss" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Plugin Downloads : Forums Importer : Comments</title>
    <link>http://www.jivesoftware.com/jivespace/docs/DOC-3471#comments</link>
    <description>Comments on : Forums Importer</description>
    <language>en</language>
    <pubDate>Thu, 02 Oct 2008 16:45:41 GMT</pubDate>
    <generator>Jive SBS 3.0.8 (http://jivesoftware.com/products/clearspace/)</generator>
    <dc:date>2008-10-02T16:45:41Z</dc:date>
    <dc:language>en</dc:language>
    <item>
      <title>RE: Forums Importer</title>
      <link>http://www.jivesoftware.com/jivespace/docs/DOC-3471#comments-3991</link>
      <description>&lt;!-- [DocumentBodyStart:23f00885-942e-4cf0-8760-44a26bc33f65] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;&lt;p&gt;This is interesting, but incomplete and has too many requirements and potential gotcha's. Here are my notes for a successful migration:&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#1. get a full mysqldump of the jive database.&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;mysqldump jive &amp;gt; jive.sql&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#2. import that into a 'jive' database on my local machine.&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;mysql -u root jive &amp;lt; jive.sql&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;*******This step takes a while.*******&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#3. copy over the jive jiveHome directory to my local machine.&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#4. edit the jiveHome/jive_startup.xml file for the forums&lt;/p&gt;&lt;p&gt;and point that to the local datasource:&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;#160;&amp;lt;database&amp;gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp; &amp;#160;&amp;lt;mysql&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;#160;&amp;lt;useUnicode&amp;gt;true&amp;lt;/useUnicode&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp; &amp;#160;&amp;lt;/mysql&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp; &amp;#160;&amp;lt;defaultProvider&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;#160;&amp;lt;username&amp;gt;root&amp;lt;/username&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;#160;&amp;lt;maxConnections&amp;gt;25&amp;lt;/maxConnections&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;#160;&amp;lt;minConnections&amp;gt;5&amp;lt;/minConnections&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;#160;&amp;lt;serverURL&amp;gt;jdbc:mysql://localhost:3306/jive&amp;lt;/serverURL&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;#160;&amp;lt;driver&amp;gt;com.mysql.jdbc.Driver&amp;lt;/driver&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;#160;&amp;lt;connectionTimeout&amp;gt;1.0&amp;lt;/connectionTimeout&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;#160;&amp;lt;password&amp;gt;&amp;lt;/password&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp; &amp;#160;&amp;lt;/defaultProvider&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;#160;&amp;lt;/database&amp;gt; &amp;#160;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;#160;&amp;lt;connectionProvider&amp;gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp; &amp;#160;&amp;lt;className&amp;gt;com.jivesoftware.base.database.DefaultConnectionProvider&amp;lt;/className&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;#160;&amp;lt;/connectionProvider&amp;gt; &amp;#160;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;#160;&amp;lt;locale&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;nbsp; &amp;#160;&amp;lt;characterEncoding&amp;gt;UTF-8&amp;lt;/characterEncoding&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&amp;#160;&amp;lt;/locale&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#4a. Put mysql driver into jive_clearspacex_standalone_1_10_14/server/shared/lib/mysql-connector-java-5.1.6-bin.jar&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#4b. Install clearspacex 1.10.14 and run it to get it setup. Point it at a clearspace database on my local machine.&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;./start-clearspace.sh&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#4c. Setup clearspacex 1.10.14 jiveHome to point at jive_clearspacex_standalone_1_10_14/jiveHome&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#4d. Use Standard Database Connection and setup mysql&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#4e. Default User settings&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&lt;span&gt;#5. &lt;/span&gt;&lt;a class="jive-link-external-small" href="http://localhost:8080/clearspacex/admin/" target="_blank"&gt;http://localhost:8080/clearspacex/admin/&lt;/a&gt;&lt;/p&gt;&lt;p&gt; System -&amp;gt; Import / Export (Jive Forums Importer)&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#6. Set the path to the jive forums jiveHome that you copied over in #3.&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#7. Run the importer (agree to the 'errors')&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#8. Copy the user id's from jive to clearspace 1.10.x&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;update clearspace.jiveMessage, jive.jiveMessage set&amp;#160;&lt;/p&gt;&lt;p&gt; clearspace.jiveMessage.userID=jive.jiveMessage.userID where&amp;#160;&lt;/p&gt;&lt;p&gt; clearspace.jiveMessage.messageID=jive.jiveMessage.messageID&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#8a. Copy the poll and private message data over&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;insert into clearspace.jivePoll select * from jive.jivePoll;&lt;/p&gt;&lt;p&gt;insert into clearspace.jivePollOption select * from jive.jivePollOption;&lt;/p&gt;&lt;p&gt;insert into clearspace.jivePollVote select * from jive.jivePollVote;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;insert into clearspace.jivePMessage select * from jive.jivePMessage;&lt;/p&gt;&lt;p&gt;insert into clearspace.jivePMessageFldr select * from jive.jivePMessageFldr;&lt;/p&gt;&lt;p&gt;insert into clearspace.jivePMessageProp select * from jive.jivePMessageProp;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;update clearspace.jiveID set id = (select max(clearspace.jivePoll.pollID) + 1 from clearspace.jivePoll) where idType = 18;&amp;#160;&lt;/p&gt;&lt;p&gt;update clearspace.jiveID set id = (select max(clearspace.jivePMessage.pMessageID) + 1 from clearspace.jivePMessage) where idType = 20;&amp;#160;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#8b. This fixes the jivePoll table to have the right container ids...&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;create temporary table ContainerMap&amp;#160;&lt;/p&gt;&lt;p&gt;select c.communityID as communityID, cast(ot.propValue as signed) as forumsObjectType, cast(oi.propValue as signed) as forumsObjectID&amp;#160;&lt;/p&gt;&lt;p&gt;from clearspace.jiveCommunity c&amp;#160;&lt;/p&gt;&lt;p&gt;join clearspace.jiveCommunityProp ot&amp;#160;&lt;/p&gt;&lt;p&gt;on ot.name = 'migration.objectType'&amp;#160;&lt;/p&gt;&lt;p&gt;and ot.communityID = c.communityID&amp;#160;&lt;/p&gt;&lt;p&gt;join clearspace.jiveCommunityProp oi&amp;#160;&lt;/p&gt;&lt;p&gt;on oi.communityid = c.communityid&amp;#160;&lt;/p&gt;&lt;p&gt;and oi.name = 'migration.objectID';&lt;/p&gt;&lt;p&gt;update jivePoll p set p.objectID = (select cm.communityID from ContainerMap cm where cm.forumsObjectType = p.objectType and cm.forumsObjectID = p.objectID), p.objectType = 14;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#9. Dump the local clearspace database and copy it over to the db server where the upgraded clearspace will be run. Import the data.&lt;/p&gt;&lt;p&gt;local: mysqldump -u root clearspace &amp;gt; clearspace.sql&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#10. Start up cs 2.5.x and go through the upgrade process.&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;#11. stop cs 2.5.x, uncomment the kinkUserMigration bean in the jiveHome/spring-kink.xml, start up cs 2.5.x&lt;/p&gt;&lt;p&gt;then stop it again and re-comment it out again.&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;---------------------------------------------------&lt;/p&gt;&lt;p&gt;&amp;lt;?xml version="1.0" encoding="UTF-8"?&amp;gt;&lt;/p&gt;&lt;p&gt;&lt;span&gt; &amp;lt;beansxmlns="&lt;/span&gt;&lt;a class="jive-link-external-small" href="http://www.springframework.org/schema/beans" target="_blank"&gt;http://www.springframework.org/schema/beans&lt;/a&gt;&lt;span&gt;"&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span&gt; xmlns:xsi="&lt;/span&gt;&lt;a class="jive-link-external-small" href="http://www.w3.org/2001/XMLSchema-instance" target="_blank"&gt;http://www.w3.org/2001/XMLSchema-instance&lt;/a&gt;&lt;span&gt;"&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span&gt; xsi:schemaLocation="&lt;/span&gt;&lt;a class="jive-link-external-small" href="http://www.springframework.org/schema/beans" target="_blank"&gt;http://www.springframework.org/schema/beans&lt;/a&gt;&lt;/p&gt;&lt;p&gt;&lt;span&gt; &lt;/span&gt;&lt;a class="jive-link-external-small" href="http://www.springframework.org/schema/beans/spring-beans-2.0.xsd" target="_blank"&gt;http://www.springframework.org/schema/beans/spring-beans-2.0.xsd&lt;/a&gt;&lt;span&gt;"&lt;/span&gt;&lt;/p&gt;&lt;p&gt; default-init-method="init"&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; &amp;lt;bean id="kinkUserMigration" class="com.kink.jive.biz.KinkUserMigration" lazy-init="false"&amp;gt;&lt;/p&gt;&lt;p&gt; &amp;lt;property name="userManager" ref="userManagerImpl"/&amp;gt;&lt;/p&gt;&lt;p&gt; &amp;lt;/bean&amp;gt;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&amp;lt;/beans&amp;gt;&lt;/p&gt;&lt;p&gt;---------------------------------------------------&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;package com.kink.jive.biz;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;import java.sql.Connection;&lt;/p&gt;&lt;p&gt;import java.sql.PreparedStatement;&lt;/p&gt;&lt;p&gt;import java.sql.ResultSet;&lt;/p&gt;&lt;p&gt;import java.sql.SQLException;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;import org.apache.commons.logging.Log;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;import com.jivesoftware.base.EmailAlreadyExistsException;&lt;/p&gt;&lt;p&gt;import com.jivesoftware.base.User;&lt;/p&gt;&lt;p&gt;import com.jivesoftware.base.UserAlreadyExistsException;&lt;/p&gt;&lt;p&gt;import com.jivesoftware.base.UserManager;&lt;/p&gt;&lt;p&gt;import com.jivesoftware.base.UserNotFoundException;&lt;/p&gt;&lt;p&gt;import com.jivesoftware.base.UserTemplate;&lt;/p&gt;&lt;p&gt;import com.jivesoftware.base.database.ConnectionManager;&lt;/p&gt;&lt;p&gt;import com.kink.heart.biz.admin.i.MemberData;&lt;/p&gt;&lt;p&gt;import com.kink.love.i.NotFoundException;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;/**&lt;/p&gt;&lt;p&gt;&amp;#160;*&lt;/p&gt;&lt;p&gt;&amp;#160;*/&lt;/p&gt;&lt;p&gt;public class KinkUserMigration&lt;/p&gt;&lt;p&gt;{&lt;/p&gt;&lt;p&gt; private UserManager userManager;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; /** */&lt;/p&gt;&lt;p&gt; private static Log log = new MakeshiftLog(KinkUserMigration.class);&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; //Add &amp;lt;property name="userManager" ref="userManagerImpl"/&amp;gt;&lt;/p&gt;&lt;p&gt; // to the xml definition of this filter&lt;/p&gt;&lt;p&gt; public void setUserManager(UserManager userManager)&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; this.userManager = userManager;&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; public void init()&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; log.debug("******************************* Running the KinkUserMigration init method!!!");&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; Connection con = null;&lt;/p&gt;&lt;p&gt; PreparedStatement updateJiveMessageStatement = null;&lt;/p&gt;&lt;p&gt; PreparedStatement selectStatement = null;&lt;/p&gt;&lt;p&gt; PreparedStatement checkStatement = null;&lt;/p&gt;&lt;p&gt; PreparedStatement insertStatement = null;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; PreparedStatement updateJivePMessageStatementA = null;&lt;/p&gt;&lt;p&gt; PreparedStatement updateJivePMessageStatementB = null;&lt;/p&gt;&lt;p&gt; PreparedStatement updateJivePMessageStatementC = null;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; PreparedStatement updateJivePMessageFldrStatement = null;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; PreparedStatement updateJivePollStatement = null;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; try&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; con = ConnectionManager.getConnection();&lt;/p&gt;&lt;p&gt; checkStatement = con.prepareStatement("select propValue from jiveProperty where name='kink.user.migration'");&lt;/p&gt;&lt;p&gt; insertStatement = con.prepareStatement("insert into jiveProperty set name='kink.user.migration', propValue='true'");&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; selectStatement = con.prepareStatement("select distinct userID from jiveMessage");&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; updateJiveMessageStatement = con.prepareStatement("update jiveMessage set userID=? where userID=?");&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementA = con.prepareStatement("update jivePMessage set senderID=? where senderID=?");&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementB = con.prepareStatement("update jivePMessage set ownerID=? where ownerID=?");&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementC = con.prepareStatement("update jivePMessage set recipientID=? where recipientID=?");&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; updateJivePMessageFldrStatement = con.prepareStatement("update jivePMessageFldr set userID=? where userID=?");&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; updateJivePollStatement = con.prepareStatement("update jivePoll set userID=? where userID=?");&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; ResultSet rsCheck = checkStatement.executeQuery();&lt;/p&gt;&lt;p&gt; boolean hasFirst = rsCheck.first();&lt;/p&gt;&lt;p&gt; if (hasFirst)&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; String value = rsCheck.getString(1);&lt;/p&gt;&lt;p&gt; if (value.equals("true"))&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; log.info("No need to run the user migration as it has already run");&lt;/p&gt;&lt;p&gt; return;&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; else&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; log.info("Running user migration script!!");&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; ResultSet rs = selectStatement.executeQuery();&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; while (rs.next())&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; Long oldUserID = rs.getLong(1);&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; log.info("Processing userID: " + oldUserID);&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; MemberData member = null;&lt;/p&gt;&lt;p&gt; try&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; // For safety check the member exists in our system with the oldUserID&lt;/p&gt;&lt;p&gt; member = Heart.getJiveTalk().getMember(oldUserID);&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; User newUser = null;&lt;/p&gt;&lt;p&gt; try&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; // Look up the user by username so we don't double create.&lt;/p&gt;&lt;p&gt; newUser = this.userManager.getUser(member.getUsername());&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; catch (UserNotFoundException e)&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; log.info("NON-FATAL: Could not find username: " + member.getUsername() + " , now going to create that user and re-associate messages to them.");&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; try&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; // **** NOTE **** If you change stuff here, don't forget to also change it in KinkAuthProcessingFilter.attemptAuthentication()&lt;/p&gt;&lt;p&gt; UserTemplate template = new UserTemplate(&lt;/p&gt;&lt;p&gt; member.getUsername(), "*(&amp;amp;@#", member.getEmail(), member.getUsername(),&lt;/p&gt;&lt;p&gt; // emailVisible, nameVisible&lt;/p&gt;&lt;p&gt; false, false, null);&lt;/p&gt;&lt;p&gt; template.setFederated(true);&lt;/p&gt;&lt;p&gt; template.setSetEmailSuppoted(false);&lt;/p&gt;&lt;p&gt; template.setSetEmailVisibleSupported(false);&lt;/p&gt;&lt;p&gt; template.setSetPasswordHashSupported(false);&lt;/p&gt;&lt;p&gt; template.setSetPasswordSupported(false);&lt;/p&gt;&lt;p&gt; template.setSetUsernameSupported(false);&lt;/p&gt;&lt;p&gt; template.setSetNameSupported(false);&lt;/p&gt;&lt;p&gt; template.setSetNameVisibleSupported(false);&lt;/p&gt;&lt;p&gt; template.setSetPropertyEditSupported(false);&lt;/p&gt;&lt;p&gt; template.setCreationDate(member.getJoinedOn().toDate());&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; newUser = this.userManager.createUser(template);&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; catch (UserAlreadyExistsException e1)&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; // Ignored on purpose&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; catch (UnsupportedOperationException uoe)&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; // Ignored on purpose&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; catch (EmailAlreadyExistsException eaee)&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; // Ignored on purpose&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; log.info("Migrating data from userID: " + oldUserID + " to userID: " + newUser.getID());&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; // Do the migration&lt;/p&gt;&lt;p&gt; updateJiveMessageStatement.setLong(1, newUser.getID());&lt;/p&gt;&lt;p&gt; updateJiveMessageStatement.setLong(2, oldUserID);&lt;/p&gt;&lt;p&gt; updateJiveMessageStatement.executeUpdate();&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementA.setLong(1, newUser.getID());&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementA.setLong(2, oldUserID);&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementA.executeUpdate();&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementB.setLong(1, newUser.getID());&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementB.setLong(2, oldUserID);&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementB.executeUpdate();&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementC.setLong(1, newUser.getID());&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementC.setLong(2, oldUserID);&lt;/p&gt;&lt;p&gt; updateJivePMessageStatementC.executeUpdate();&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; updateJivePMessageFldrStatement.setLong(1, newUser.getID());&lt;/p&gt;&lt;p&gt; updateJivePMessageFldrStatement.setLong(2, oldUserID);&lt;/p&gt;&lt;p&gt; updateJivePMessageFldrStatement.executeUpdate();&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; updateJivePollStatement.setLong(1, newUser.getID());&lt;/p&gt;&lt;p&gt; updateJivePollStatement.setLong(2, oldUserID);&lt;/p&gt;&lt;p&gt; updateJivePollStatement.executeUpdate();&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; catch (NotFoundException e)&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; log.info("Could not find Heart member: " + oldUserID);&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt; insertStatement.execute();&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; catch (SQLException e2)&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; e2.printStackTrace();&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; finally&lt;/p&gt;&lt;p&gt; {&lt;/p&gt;&lt;p&gt; ConnectionManager.close(con);&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt; }&lt;/p&gt;&lt;p&gt;}&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;p&gt;&amp;#160;&lt;/p&gt;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:23f00885-942e-4cf0-8760-44a26bc33f65] --&gt;</description>
      <pubDate>Thu, 02 Oct 2008 16:45:41 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/docs/DOC-3471#comments-3991</guid>
      <dc:date>2008-10-02T16:45:41Z</dc:date>
      <clearspace:dateToText>1 year, 1 month ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
    </item>
    <item>
      <title>RE: Forums Importer</title>
      <link>http://www.jivesoftware.com/jivespace/docs/DOC-3471#comments-9370</link>
      <description>&lt;!-- [DocumentBodyStart:6a1b96af-49c2-4b6f-89a6-80c9503263b8] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;A little off topic but has anyone successfully imported an existing vBulletin implementation into Jive? Thanks.&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:6a1b96af-49c2-4b6f-89a6-80c9503263b8] --&gt;</description>
      <pubDate>Wed, 11 Nov 2009 17:52:46 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/docs/DOC-3471#comments-9370</guid>
      <dc:date>2009-11-11T17:52:46Z</dc:date>
      <clearspace:dateToText>1 week, 3 days ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
    </item>
  </channel>
</rss>

