Hi,
I'm trying to update a Confluence-page via REST.
As a result I'm getting a response code 500. Looking in the atlassian-confluence.log it says:
2016-04-07 14:53:29,973 ERROR [http-nio-172.22.115.49-8090-exec-426] [rest.api.model.ExceptionConverter] convertServiceException No status code found for exception, converting to internal server error : -- url: /confluence/rest/api/content/18822443 | userName: tunupnavi java.lang.IllegalArgumentException: Property with name sync-rev is not a String at com.atlassian.confluence.content.ContentProperties.getStringProperty(ContentProperties.java:86) at com.atlassian.confluence.content.apisupport.ContentCreator.setSyncRevOnEntity(ContentCreator.java:196) at com.atlassian.confluence.content.apisupport.ContentCreator.setCommonPropertiesForUpdate(ContentCreator.java:182) at com.atlassian.confluence.api.impl.service.content.typebinding.PageContentTypeApiSupport.update(PageContentTypeApiSupport.java:164) at com.atlassian.confluence.api.impl.service.content.typebinding.PageContentTypeApiSupport.update(PageContentTypeApiSupport.java:42) at com.atlassian.confluence.api.impl.service.content.ContentServiceImpl.updateUsingApiSupport(ContentServiceImpl.java:126) at com.atlassian.confluence.api.impl.service.content.ContentServiceImpl.update(ContentServiceImpl.java:176)
What is going wrong?
I'm using Confluence 5.9.3 with an Oracle DB.
Thanks,
Marcel
Community moderators have prevented the ability to post new answers.
The Problem seems to be fixed with version 5.9.14: https://jira.atlassian.com/browse/CONFSERVER-41493
Hi all. I don't know if it's still an issue for anyone. Our instance had same problems with update and we got rid of this by migrationg data from Oracle DB to MS SQL DB.
Atlassian sent me their solution, but I was done with migration by this time, so I don't know if it's permanent.
Here is their answer:
It's seems that the additional entries in the contentproperties table has cause the problem with updating the page. We are still uncertain on what has trigger the additional "sync-rev" entries to be added into the table even though it is not used yet.
Good news is that, we are able to find a fix for this problem by removing the entry related to the sync-rev values directly from the database. Thus, please :
// identify how many entries need to be deleted select count( distinct propertyid) from CONTENTPROPERTIES where propertyname='sync-rev'; // delete all of the entries delete from CONTENTPROPERTIES where propertyname='sync-rev';
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The answer from Atlassian doesn't work for me. After deleting the entries, and restart the instance, the entries came back after that and the problem persisted
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Together,
I am really suffering with this issue.
Is there any solution to this issue? What do you need to check?
Stephan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This matches my guess, since I am able to update a page right after I manually edited it but not after about an hour.
We upgraded from v5.8.5 to v5.9.3 and switched from HSQL to Oracle DB at once.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We have the same issue after update to v5.9.7, and I suspect database update might be the reason.
What was your scenario for upgrading Confluence?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production With the Partitioning option
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your advice but unfortunately it had no effect...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please add space as one of the inputs and check once. I used the same request along with space from my Java application.
"space":{"key": "test"}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
My request:
PUT https://confluence.sha.vrkw.de/confluence/rest/api/content/18837679 HTTP/1.1
[Content-Type: application/json; charset=UTF-8,Content-Length: 1819,Chunked: false]
{"id":"18822443","type":"page","title":"_VkAKQGaBEeWW-_fJrjeK2A","version":{"number":3},"ancestors":[{"id":"18821974"}],"body":{"storage":{"value":"<h2>hello</h2>","representation": "storage"}}}
{http.auth.credentials-provider={<any realm>@confluence.sha.vrkw.de=[principal: tunupnavi]}, http.auth.auth-cache={https://confluence.sha.vrkw.de:443=[B@139a76}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Do the id values need to be in quotes? shouldn't it be "id":18822443?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
According to this documentation (https://developer.atlassian.com/confdev/confluence-rest-api/confluence-rest-api-examples#ConfluenceRESTAPIExamples-Manipulatingcontent) you have to use quotes.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Maybe i'm misreading it, but when I searched for Ancestors I see this:
"ancestors":[{"id":456}]
with no quotes around the integer?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You are right, there are no quotes around the ancestor-id in the documentation. When I'm sending a GET request there are quotes tho:
"ancestors": [{
"id": "4259846",
"type": "page",
"status": "current",
"title": "NUP",
"extensions": {
"position": 1
}]
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please post the Confluence REST API request as well
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Community moderators have prevented the ability to post new answers.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.