Re: empty statuses in LogicActions.afterUpdate

2023-10-26 Thread Lionel SCHWARZ
Hi Francesco,
Your answer is absolutely clear, thanks
Regards
Lionel

- Le 25 Oct 23, à 16:28, Francesco Chicchiriccò ilgro...@apache.org a écrit 
:

> So let me summarize what is happening.
> 
> This step:
> 
> - update the user so that the approval is needed
> 
> is actually performed by calling
> 
> PATCH /users/self/
> 
> or
> 
> PATCH /users/
> 
> depending on whether the caller is the user themselveers or an administrator.
> Both invocations reach up to UserLogic#doUpdate that is where any matching
> LogicActions#afterUpdate is invoked.
> 
> If the update as above is triggering an approval in the defined user workflow,
> any propagation is suspended.
> 
> This step:
> 
> - approve the update
> 
> (I assume performed via Console) is instead calling
> 
> POST /flowable/userRequests/forms/
> 
> As you can see from Swagger UI, this all is returning all the propagation
> statuses as expected.
> 
> Hence, if you want to decorate the result of a form approval - similarly to 
> what
> you are doing via LogicActions#afterUpdate for plain updates - you will have 
> to
> code this into a workflow task, to be inserted in your definition right after
> approval.
> 
> Hope this clarifies.
> Regards.
> 
> On 24/10/23 09:48, Lionel SCHWARZ wrote:
>> Hi Francesco,
>> Thanks for your answer.
>>
>> You should be able to reproduce this with the UserWorkflow defined in the fit
>> part of Syncope (which I used as a base for my customized workflow 
>> definition)
>> and with the LogicActions implementation attached to the email:
>>
>> - declare the ExampleLogicAction in the default realm
>> - create a user in the default realm with a resource
>> - update the user so that the approval is needed
>> - approve the update
>> - check in the log that the afterUdate() receives empty 
>> List
>>
>> AND
>> - update the user so that the approval is NOT needed
>> - check in the log that the afterUdate() receives List 
>> with 1
>> item: the propagation of the resource
>>
>>
>> Best regards
>> Lionel
>>
>> - Le 24 Oct 23, à 8:44, Francesco Chicchiriccò ilgro...@apache.org a 
>> écrit :
>>
>>> Hi Lionel,
>>> can you provide a simple project that reproduces this issue?
>>>
>>> It should be enough to create a new Maven project from latest stable version
>>> (3.0.5 at this time), change the workflow definition to match your case and
>>> finally provide the steps to reproduce in embedded mode.
>>>
>>> Regards.
>>>
>>> On 23/10/23 18:10, Lionel SCHWARZ wrote:
 To be more specific about the issue, I must tell that I have a flowable
 UserWorkflow with approval on user update operations (on certain
 circumstances).
 It seems that when the update needs approval, the afterUpdate() is called 
 before
 approval with an empty List.
 When the update does not need approval, the afterUpdate() works fine.

 Lionel

 - Le 23 Oct 23, à 17:36, Lionel SCHWARZ lionel.schw...@in2p3.fr a 
 écrit :

> Dear all,
>
> I have a customized LogicAction with afterUpdate() implementation, but 
> this
> method receives an empty List when called.
> Nevertheless, the propagation works fine, and I get the correct REST 
> response
> with propagationStatuses and beforeObg/afterObj.
>
> Am I missing something?
>
> Regards
> Lionel
> 
> --
> Francesco Chicchiriccò
> 
> Tirasa - Open Source Excellence
> http://www.tirasa.net/
> 
> Member at The Apache Software Foundation
> Syncope, Cocoon, Olingo, CXF, OpenJPA, PonyMail
> http://home.apache.org/~ilgrosso/


smime.p7s
Description: S/MIME Cryptographic Signature


Re: Syncope 3.0.5 upgrade

2023-10-26 Thread Francesco Chicchiriccò

On 25/10/23 20:36, Thomas Ryman wrote:

Also is there any way to encrypt the keymaster.password=unencrypted-password 
and decrypt it during run time?



Starting with 3.0, Apache Syncope components are all Spring Boot applications, 
so you are free to integrate something like

https://github.com/ulisesbocchio/jasypt-spring-boot

to achieve this goal.


It would be anyway an interesting feature to add, please remember that 
contribution is always welcome!

https://syncope.apache.org/contributing

Regards.


--


--
Francesco Chicchiriccò

Tirasa - Open Source Excellence
http://www.tirasa.net/

Member at The Apache Software Foundation
Syncope, Cocoon, Olingo, CXF, OpenJPA, PonyMail
http://home.apache.org/~ilgrosso/



Re: Syncope 3.0.5 upgrade

2023-10-26 Thread Francesco Chicchiriccò

Hi Thomas,
as reported by

https://syncope.apache.org/docs/3.0/reference-guide.html#upgrade-from-2-1

there is no supported upgrade path from 2.1 to 3.0.

Please stick with the suggested migration approach.

Regards.

On 25/10/23 18:43, Thomas Ryman wrote:

Hello,

I am working on upgrading syncope from version 2 to version 3 however am having 
some issues.  I am following instructions that were found before however it 
seems whenever I start syncope the logs show that I am missing a class and 
possibly some properties.  Here is one of the current errors that I am 
investigating.  Also if there is any full documentation out there on the proper 
process to upgrade from version 2 to version 3 a link would be very appreciated.

Description: Field serviceOps in 
org.apache.syncope.common.keymaster.client.api.startstop.KeymasterStartStop 
required a bean of type 
'org.apache.syncope.common.keymaster.client.api.ServiceOps' that could not be 
found. The injection point has the following annotations:         - 
@org.springframework.beans.factory.annotation.Autowired(required=true) Action: 
Consider defining a bean of type 
'org.apache.syncope.common.keymaster.client.api.ServiceOps'in your 
configuration.



--
Francesco Chicchiriccò

Tirasa - Open Source Excellence
http://www.tirasa.net/

Member at The Apache Software Foundation
Syncope, Cocoon, Olingo, CXF, OpenJPA, PonyMail
http://home.apache.org/~ilgrosso/