Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

ActiveObjects does not persist in Confluence

Boris
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 1, 2015

I have a problem with AO not persisting an entity when used in Confluence. Strangely, the same code works in JIRA.

I created two test plugins .

They both have the TestWS web service and a TestEntity.

To run the test for JIRA, visit

http://localhost:2990/jira/rest/testplugin/1.0/library/create

to create an entity and then

http://localhost:2990/jira/rest/testplugin/1.0/library/get

to get it. It will show "A name" string on the page.

Visiting the similar URLs for Confluence will not show anything as the entity was never persisted. No exception was thrown when persisting. Both plugins are started successfully.

The AO plugin setup is nearly identical in both cases except for AO version which has to match respective applications.

Confluence 5.7, ActiveObjects 0.29.3

JIRA 6.4, ActiveObjects 0.28.7

Any clues?

Thanks.

 

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

2 votes
Answer accepted
Daniel Wester
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 1, 2015

Confluence needs transactions. https://developer.atlassian.com/docs/atlassian-platform-common-components/active-objects/getting-started-with-active-objects#GettingStartedwithActiveObjects-Step9.CreateanAOinteractionwithinaTransaction

 

The other issue might be that you're doing a get to write. I know that Bamboo is really finicky about doing writes on gets. I'm not sure about Confluence, but you might want to switch to do a post.

Boris
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 1, 2015

Yes, it works with a transaction. GET was just for testing purposes. Thanks!

TAGS
AUG Leaders

Atlassian Community Events