Skip to Content.
Sympa Menu

grouper-users - [grouper-users] RE: hooks.StemHooks ... stemPreUpdate : how to tell what is changing on the preInsertBean?

Subject: Grouper Users - Open Discussion List

List archive

[grouper-users] RE: hooks.StemHooks ... stemPreUpdate : how to tell what is changing on the preInsertBean?


Chronological Thread 
  • From: "Black, Carey M." <>
  • To: "Hyzer, Chris" <>, grouper-users <>
  • Subject: [grouper-users] RE: hooks.StemHooks ... stemPreUpdate : how to tell what is changing on the preInsertBean?
  • Date: Wed, 27 Sep 2017 15:13:53 +0000
  • Accept-language: en-US
  • Authentication-results: spf=pass (sender IP is 128.146.163.18) smtp.mailfrom=osu.edu; internet2.edu; dkim=none (message not signed) header.d=none;internet2.edu; dmarc=pass action=none header.from=osu.edu;
  • Ironport-phdr: 9a23:fJUfzB+AjJXobf9uRHKM819IXTAuvvDOBiVQ1KB20ukcTK2v8tzYMVDF4r011RmSDNWds6oMotGVmpioYXYH75eFvSJKW713fDhBt/8rmRc9CtWOE0zxIa2iRSU7GMNfSA0tpCnjYgBaF8nkelLdvGC54yIMFRXjLwp1Ifn+FpLPg8it2e2//57ebx9UiDahfLh/MAi4oQLNu8cMnIBsMLwxyhzHontJf+RZ22ZlLk+Nkhj/+8m94odt/zxftPw9+cFAV776f7kjQrxDEDsmKWE169b1uhTFUACC+2ETUmQSkhpPHgjF8BT3VYr/vyfmquZw3jSRMMvrRr42RDui9b9mRh/2hikaKz43/mLZisJyg6JavB2vqBNwzpXIYIGMMPdyYr/Rcc8ESWdHQ81fVzZBAoS5b4YXAeYMIOJYoJPhqFsNtRe1GBehC/n1yjBWhn79wKo03/4vHQrb2wEvBNYOv27Io9X2LqseTP65wafTwDXEdPNWxC3x55bVfRA8uPyBW697f8nJyUQ3Cg/JklqdpZbqMj6XzOgAvHSX4/B9We+hhGMrsxx9riasy8s2l4XEiYMYxkrA+Ch22oo5O9O1RU5jbd6qDpRdtD2WOo5zT84iX25npCg6x7gYtZO0fSUF1ZEqyhHfZvGFfYWF5w7sW/2KLjhign9uZaixiAyo8Ue6z+3xTsm030hOripCitTCrmwA2RvP5sWJU/dw4F6v1SuW2wDU8e5LP1o4la3GK5492bEwkYcTsULeESPsgEX2lqiWdlk69ee09+TnY7LmppmGO49zlwH+LqAumsu4AeQ7KAQBQ2+b+eGk2L3i+032XqlKg+UrnqXFv53WP8sWq6yjDwJazoov8QuzAjmp3dgAmHkINlNFeBaJj4jzPFHOJej1Auy7g1u2jDhrxOrKMqD/DpjDNXXDl6zhfatn50FC1QUz0MhT54hIBbEZPPLzRkjxucTXDh8jNAy03v7nB8tn1o8HRGKPGbGWMLnJsVKT4uIvIvKMZJMOuDrjMfQl5vjujWMnll8He6mmw4cXZG6iEvt4PkqZfCmkvtBUW0cbrAckCKTBiEeDSnQbM3O5X7Mu6ysTCZmtS5rbS4arxrGNwXH/VpJMYX1eB0rJDGzlbZ7MD/gWbz+KL9UkjycJT6OJSok92AuouROgjbdrM7yH1DcfsMep/tx87O6X3To77zFlR+HbmSnZRWV9lWBOHmVt9KdkvApwxkrVgvswuOBRCdEGv6ABaQw9L5OJl+E=
  • Spamdiagnosticmetadata: NSPM
  • Spamdiagnosticoutput: 1:99

Chris,

Thanks. That was a copy and paste error. ( Subject "stemPreUpdate" was the
context that I was looking for these details. Somehow I put " preInsertBean "
into the subject and the body too. Argg... Sorry for the confusion.)

I had seen the "dbVersion()" method, but I read/assumed that it was
"hibernate related" and did not look deeper than that. :^/


Thanks for the pointer. That is what I was overlooking.

--
Carey Matthew



-----Original Message-----
From: Hyzer, Chris
[mailto:]

Sent: Monday, September 25, 2017 9:28 AM
To: Black, Carey M.
<>;
grouper-users
<>
Subject: RE: hooks.StemHooks ... stemPreUpdate : how to tell what is changing
on the preInsertBean?

Pre insert is for inserts which means there is no existing. You need
pre-update for updates.

In the object (Stem) is a "dbVersion()" and dbVersionDifferentFields() which
will help you get the database version... If you query for it you need a
different tx...

Thanks
Chris

-----Original Message-----
From:


[mailto:]
On Behalf Of Black, Carey M.
Sent: Sunday, September 24, 2017 10:57 PM
To: grouper-users
<>
Subject: [grouper-users] hooks.StemHooks ... stemPreUpdate : how to tell what
is changing on the preInsertBean?

A very quick look at the methods on preInsertBean does not reveal any obvious
"changing" data for the stem.

Maybe I would need to use the UUID to find the existing data via a FindStem
search and then compare all of the data values from the bean and the
"FimdStem" results of the two myself?

Any ideas/guidance?

If it helps, I am wanting to allow only *special* groups to modify the
extention, Display names. But others should be allowed to updated the
Description for the stems;. ( Thus writing a hook and I found this question.)

Thanks in advance.

--
Carey Matthew






Archive powered by MHonArc 2.6.19.

Top of Page