[Building Sakai] Adjusting links after a site duplication
Bryan Holladay
holladay at longsight.com
Wed Sep 14 10:27:13 PDT 2011
You seem to be confused on what SAK-16568 does. It creates an API to
manage conversions in text. It is an extension of EntityTransferrer
by extending the API to do two things:
1) When the tool transfers entities (ie. copy from one site to the
other), it returns a Mapping of (fromContextRef -> toContextRef).
This is collected and then passed into the 2nd step once everything is
collected from all tools being migrated.
2) updateEntityReferences(String toContext, Map<String, String> transversalMap)
You can leave this blank or use the mapping to do a String.replace()
in any text you want to update in your tool.
> 1) In the case of Forums, Topics appear to move over properly as it is,
> but the forum
> as a draft ? Do the modifications in SAK-16568 also move over postings
> ? Are the forums
> themselves moved to non-draft status
This Jira doesn't deal with converting anything to draft. The default
for site import is to import everything as a draft. There is a
property you can set in Sakai.Properties to make it so all imported
data is published.
import.importAsDraft=false
*(not tied to SAK-16568)
> 2) Samigo - after a site dup, the old quizzes are non published in the
> new site. Does it
> publish the quizzes and then adjust the links ?
Samigo doesn't import published sites over, just the working copies.
*(Not tied to SAK-16568)
> 3) Assignments - after a site dup, assignments in the new site are
> drafts. Does the new
> code change this ?
set import.importAsDraft=false
*(not tied to SAK-16568)
> 4) As I understand it, this code is invoked from Entity Picker. How
> does this work ?
Nope, Entity picker is just a use case for the need for this jira.
You seem to have another use case and SAK-16568 will cover it.
>Am I right
> in assuming the critical code in each tool is contained within method
> updateEntityReferences ? Could
> this be called from another context - for instance a free-standing "copy
> site" tool ?
If you want to use this API, just implement EntityTransferrer and
EntityTransferrerRefMigrator. For good reason (there's a long
conversation in the list archive), this is broken into 2 API's, but
you will want to use EntityTransferrerRefMigrator function
transferCopyEntitiesRefMigrator if you want to return a mapping,
otherwise you just need to implement updateEntityReferences.
Thanks,
Bryan
>
> - George Pipkin
> U.Va.
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>
> TO UNSUBSCRIBE: send email to sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of "unsubscribe"
>
More information about the sakai-dev
mailing list