Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

CRRRS6402E Content is not allowed making PUT request in RDNG

Hello guys!

Sorry for disturbing. I'm trying to update an artifact with OSLC in accordance to:
But I can not overcome it! Could anybody take a quick look at my case and say what I'm doing wrong.
I'm working with RDNG v6.0.5, use Firefox v12 and Poster add-on installed.
1. Building GET request
Poster GET request

2. Taking and copy-pasting body from result to content of new PUT request to be sent
GET request result

3. Taking content from ETag header in the result of GET request and saving it as is in If-Math header of new PUT request
Coping ETag value to If-Match header

4. Executing PUT request
Error in PUT request

What is wrong?
Thanks a lot in advance!

0 votes


Accepted answer

Permanent link

 I was not talking about the HEADER. I was talking about the MESSAGE content in the PUT.


Dmitry A. Lesin selected this answer as the correct answer

0 votes

Comments

Yes, sure, I'm understanding that. I have taken body from result in GET request and copy/pasted it to content to be sent. As well as ETag copied to If-Match.

Or may be I didn't understand you clear again? 

  Content is copied

SURE

This is a specifics of Poster, I believe. It's never mind if you set "Content-Type" header. It must be set in "Content Type" filed of Poster!

  Content type must be set in a special field


2 other answers

Permanent link

The error message seems to indicate that whatever you sent as a payload in the post was not in a valid application/rdf+xml format. Also check the log and search for the entry using the code.

0 votes

Comments

It's strange because I was taking the content from GET result as is. It means that GET result was not in valid application/rdf+xml format, wasn't it?

Log doesn't have enough info:


2018-11-26 17:40:02,447 [Default Executor-thread-4833 @@ 17:40 <unauthenticated> <Mozilla/5.0 (Windows NT 6.2; WOW64; rv:12.0) Gecko/20100101 Firefox/12.0@fe80:0:0:0:180a:7716:d783:2d90%12> /rm/resources/_QdJP-OjKEeinF9fCDHR5fg] ERROR ibm.rdm.fronting.server.services.RMRestServiceBase  - CRRRS1007E  A problem occurred in the Requirements Management (RM) server: Entry [6d335a433bffd7b5]
com.ibm.rdm.fronting.server.exception.UnsupportedMediaTypeException: CRRRS6402E  Content is not allowed.  Content type must be application/rdf+xml
at com.ibm.rdm.fronting.server.exception.RRSException.newException(RRSException.java:315)
at com.ibm.rdm.fronting.server.exception.RRSException.newUnsupportedMediaTypeException(RRSException.java:206)
at com.ibm.rdm.fronting.server.services.calm.internal.OSLC20ContentHandler.validateContentType(OSLC20ContentHandler.java:1712)


Permanent link

Your GET request is asking for content type of "application/xml" and not "application/rdf+xml".

0 votes

Comments

I was trying already all variants: "application/xml", "application/rdf+xml" in Accept and Content-Type headers but the result is the same.

To be clear, the only combination is correct.

For your GET request define the following headers:
Accept: application/rdf+xml
OSLC-Core-Version: 2.0
...

For your PUT request define the following headers:
Content-Type: application/rdf+xml
OSLC-Core-Version: 2.0
If-Match: [E-Tag of GET request]
...

Yes, thank you!

I was trying this variant too.
I appreciate your advice anyway!

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,938
× 234
× 60
× 25
× 17

Question asked: Nov 26 '18, 9:20 a.m.

Question was seen: 125,391 times

Last updated: Nov 26 '18, 10:43 a.m.

Confirmation Cancel Confirm