[Building Sakai] Web Services for Site removal.

Neal Caidin neal.caidin at apereo.org
Tue Oct 21 06:38:03 PDT 2014


If someone comes up with documentation, I'll make sure it gets located 
in one of the more active Confluence spaces.

-- Neal


> Kmety, Matt <mailto:mrkmety at ilstu.edu>
> October 21, 2014 at 9:25 AM
>
> Hi,
>
> Is there any documentation out there that shows what would need to be 
> deleted/moved out of the database in order for the site to be 
> completely gone? Having the data moved out of our production database 
> would be helpful if it was still reportable.
>
> Thanks,
>
> Matt
>
> *From:*sakai-dev-bounces at collab.sakaiproject.org 
> [mailto:sakai-dev-bounces at collab.sakaiproject.org] *On Behalf Of 
> *Matthew Jones
> *Sent:* Tuesday, October 21, 2014 8:15 AM
> *To:* Alaa NIZAR
> *Cc:* sakai-dev
> *Subject:* Re: [Building Sakai] Web Services for Site removal.
>
> No, this is essentially what Steve was saying. Nothing really cleans 
> up after itself in Sakai. This makes it easier to recover data, but 
> can be harder to clean up content. And this was probably mostly 
> because storage space is cheaper than the time to make backups or 
> perform restorations from backups.
>
> Someone would have to implement the hardDelete method and others in 
> the HardDeleteAware interface for Assignment (and every other tool) to 
> have the tool be able to clean itself up. If you delete an Assignment, 
> the attachments remain.
>
> On Tue, Oct 21, 2014 at 8:59 AM, Alaa NIZAR <alaanizar at iihem.ac.ma 
> <mailto:alaanizar at iihem.ac.ma>> wrote:
>
> Alright. It is clear now.
>
> We used to remove the binary and the content from db manually as of 
> 2.9. Now, we are on 10.1, waiting for upgrading to 10.2.
>
> Case: purging the Assignments tool of a given site.
>
> Is there any function that do this automatically so that I can build a 
> web service on it?
>
> If I remove the Assignment related to that site, will the binary 
> attachments be removed also?
>
> Thank you for your help.
>
> Yours,
>
> Alaa
>
> Sent from Samsung Mobile.
>
> -------- Original message --------
>
> From: Steve Swinsburg
>
> Date:21/10/2014 13:39 (GMT+00:00)
>
> To: Alaa NIZAR
>
> Cc: sakai-dev ,Matthew Jones
>
> Subject: Re: [Building Sakai] Web Services for Site removal.
>
> Hard delete is not in Sakai 10, it is a new feature for Sakai 11 only. 
> You can backport it though.
> The javadocs on the interface say it's since 10.0 but it's actually 11.
>
>
> https://jira.sakaiproject.org/browse/KNL-1252
>
> It's currently hooked up to Resources so that content is purged if you 
> hard delete a site. This means that files on the filesystem and binary 
> in the database is deleted.
>
> Other tools generally just store data in the database. To get those to 
> delete that data, implement the interface (see the javadocs on the 
> interface), then the tool will be called upon at delete time to do 
> what it needs to do to remove its content.
>
> On Tue, Oct 21, 2014 at 6:54 PM, Alaa NIZAR <alaanizar at iihem.ac.ma 
> <mailto:alaanizar at iihem.ac.ma>> wrote:
>
> Great.
>
> What is partially implemented in Sakai 10.2?
>
> I mean how the delete thing is working is 10.2!
>
> Yours,
>
> Sent from Samsung Mobile.
>
> -------- Original message --------
>
> From: Steve Swinsburg
>
> Date:21/10/2014 08:16 (GMT+00:00)
>
> To: alaanizar
>
> Cc: sakai-dev ,Matthew Jones
>
> Subject: Re: [Building Sakai] Web Services for Site removal.
>
> Yes, for the tools that you want to have deleted, implement the 
> interface and use the tools own API to delete the content for the site 
> (if it exists). When the site is deleted it will call all implementors 
> to do their thing.
>
> sent from my mobile
>
> On 21/10/2014 2:40 AM, "Alaa NIZAR" <alaanizar at iihem.ac.ma 
> <mailto:alaanizar at iihem.ac.ma>> wrote:
>
> When a semester ends up, how could schools remove all the contents of 
> a site, as of Sakai 10.2.
>
> We used to delete data in table directly as we were only offering 
> announcements, schedule, resources, assignments and dropbox tools.
>
> Given the three kinds of deletion features, how could we do it SAFELY, 
> without touching tables directly?
>
> Is that possible!
>
> Yours,
>
> Sent from Samsung Mobile.
>
> -------- Original message --------
>
> From: Matthew Jones
>
> Date:20/10/2014 16:25 (GMT+00:00)
>
> To: Alaa NIZAR
>
> Cc: sakai-dev at collab.sakaiproject.org 
> <mailto:sakai-dev at collab.sakaiproject.org>
>
> Subject: Re: [Building Sakai] Web Services for Site removal.
>
> Well, even with "soft delete" if you delete something twice it will 
> delete it. However in many Sakai tools, if you delete something it 
> doesn't delete the references to everything else. So there's kind of a
>
> - "soft delete" = mark for deletion (New feature for sites/content in 
> 10) KNL-974/KNL-309
>
> - "normal delete" - only delete that specific thing, typical Sakai 
> behavior
>
> - "hard/full delete" - which is meant to be delete that thing and 
> everything related to that thing (partially implemented in 11 - KNL-1252)
>
> Like if you remove a user from a site it doesn't remove all of the 
> users forum posts and assignment submissions.
>
> Or if you remove a site from the system, it doesn't remove all of the 
> assignments and resources associated with the site.
>
> There's no referential integrity on the database between tables or 
> enforced via deletion.
>
> The idea for "hard delete" is that there could be, for schools that 
> wanted it a way for when sites were deleted to really delete everything.
>
> On Mon, Oct 20, 2014 at 11:14 AM, Alaa NIZAR <alaanizar at iihem.ac.ma 
> <mailto:alaanizar at iihem.ac.ma>> wrote:
>
> Hi,
>
> Soft delete does NOT remove the contents of the tools, then.
>
> If I understand, the soft delete feature only removes the site from 
> SAKAI_SITE, but leaves all the data related to that site in other 
> tables. Then, the data is still there on the database and binary 
> content also.
>
> If yes, how the HARD DELETE feature will permita full deletion of all 
> data and contents related to that sit, definitely?
>
> I'm refering to this feature as of Sakai 11.
>
> Yours,
>
> Alaa Nizar
>
> Sent from Samsung Mobile.
>
> -------- Original message --------
>
> From: Matthew Jones
>
> Date:20/10/2014 15:55 (GMT+00:00)
>
> To: Alaa NIZAR
>
> Cc: sakai-dev at collab.sakaiproject.org 
> <mailto:sakai-dev at collab.sakaiproject.org>
>
> Subject: Re: [Building Sakai] Web Services for Site removal.
>
> There is a feature for "hard delete" only in 11, but it's not for 
> contents (in resources) and I don't think there is a web service for 
> it yet. You'd have to backport kernel code to get it. It's a generic 
> interface so ideally other tools could also implement the hard delete 
> but as of yet, no other tool has.
>
> https://jira.sakaiproject.org/browse/KNL-1252
>
> If you didn't want to write a backport and call this 
> hardDelete(siteId) directly with a webservice, you could probably add 
> a webservice with some of the code here to go through all the 
> resources in a site and remove them, and any other tools you want. I 
> haven't heard of anyone that has done that any other way.
>
> On Fri, Oct 17, 2014 at 9:16 AM, Alaa NIZAR <alaanizar at iihem.ac.ma 
> <mailto:alaanizar at iihem.ac.ma>> wrote:
>
> Hello,
>
> How can we remove sites AND ALL its contents from sakai 10 using web 
> services?
>
> Thank you.
>
> Sent from Samsung Mobile.
>
>
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
>
>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org 
> <mailto: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 
> <mailto:sakai-dev-unsubscribe at collab.sakaiproject.org> with a subject 
> of "unsubscribe"
>
>
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
>
>
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
>
>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org 
> <mailto: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 
> <mailto:sakai-dev-unsubscribe at collab.sakaiproject.org> with a subject 
> of "unsubscribe"
>
>
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
>
>
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
>
> _______________________________________________
> 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"
> Matthew Jones <mailto:matthew at longsight.com>
> October 21, 2014 at 9:15 AM
> No, this is essentially what Steve was saying. Nothing really cleans 
> up after itself in Sakai. This makes it easier to recover data, but 
> can be harder to clean up content. And this was probably mostly 
> because storage space is cheaper than the time to make backups or 
> perform restorations from backups.
>
> Someone would have to implement the hardDelete method and others in 
> the HardDeleteAware interface for Assignment (and every other tool) to 
> have the tool be able to clean itself up. If you delete an Assignment, 
> the attachments remain.
>
>
> _______________________________________________
> 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"
> Alaa NIZAR <mailto:alaanizar at iihem.ac.ma>
> October 21, 2014 at 8:59 AM
> Alright. It is clear now.
>
> We used to remove the binary and the content from db manually as of 
> 2.9. Now, we are on 10.1, waiting for upgrading to 10.2.
>
> Case: purging the Assignments tool of a given site.
> Is there any function that do this automatically so that I can build a 
> web service on it?
>
> If I remove the Assignment related to that site, will the binary 
> attachments be removed also?
>
> Thank you for your help.
>
> Yours,
> Alaa
>
>
>
> Sent from Samsung Mobile.
>
>
> -------- Original message --------
> From: Steve Swinsburg
> Date:21/10/2014 13:39 (GMT+00:00)
> To: Alaa NIZAR
> Cc: sakai-dev ,Matthew Jones
> Subject: Re: [Building Sakai] Web Services for Site removal.
>
> Hard delete is not in Sakai 10, it is a new feature for Sakai 11 only. 
> You can backport it though.
> The javadocs on the interface say it's since 10.0 but it's actually 11.
>
> https://jira.sakaiproject.org/browse/KNL-1252
>
> It's currently hooked up to Resources so that content is purged if you 
> hard delete a site. This means that files on the filesystem and binary 
> in the database is deleted.
>
> Other tools generally just store data in the database. To get those to 
> delete that data, implement the interface (see the javadocs on the 
> interface), then the tool will be called upon at delete time to do 
> what it needs to do to remove its content.
>
>
>
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
> -- 
> This message has been scanned for viruses and
> dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
> believed to be clean.
> _______________________________________________
> 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"

-- 
Neal Caidin
Sakai Community Coordinator
Apereo Foundation
neal.caidin at apereo.org
Skype me! (but let me know in advance for the first interaction) - nealkdin

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20141021/f4e9cd6c/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: compose-unknown-contact.jpg
Type: image/jpeg
Size: 770 bytes
Desc: not available
Url : http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20141021/f4e9cd6c/attachment.jpg 


More information about the sakai-dev mailing list