Is there any possibility to change created by attribute in GCM Component using APIs?
Hi,
Accepted answer
No, that is not possible. As Ralph commented above,
dcterms:created
is intentionally considered a read-only attribute and cannot be modified with an HTTP PUT. This is considered best practice for audit reasons.The resource shape for a global configuration defines the
dcterms:created
property as:
oslc:property
[ a oslc:Property ;
oslc:name "Date Created" ;
oslc:occurs oslc:Exactly-one ;
oslc:propertyDefinition
dcterms:created ;
oslc:queryable "true"^^xsd:boolean ;
oslc:readOnly "true"^^xsd:boolean ;
oslc:valueType xsd:dateTime ;
dcterms:title "Date Created"^^rdf:XMLLiteral
David
2 other answers
In my mind, it should not be possible to modify data such as CreatedBy, Creation Date, ModifiedBy, Modified etc. this would clash with Audit capability and truth of the data. I have not been able to modify those values in any Jazz application I have tried with whatever API I tried. I believe I have seen EWM/RTC integrations being able to set these values for the initial creation, but I do not know which API they used. There might be a special hidden API that allows this. Once created, these values should not be modifiable.
The same applies to
dcterms:creator
:
oslc:property
[ a oslc:Property ;
oslc:name "Creator" ;
oslc:occurs oslc:Exactly-one ;
oslc:propertyDefinition
dcterms:creator ;
oslc:queryable "true"^^xsd:boolean ;
oslc:range foaf:Person ;
oslc:readOnly "true"^^xsd:boolean ;
oslc:valueType oslc:Resource ;
dcterms:title "Creator"^^rdf:XMLLiteral
] ;
Comments
Ian Barnard
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER Feb 22 '22, 3:57 a.m.No it isn't possible to change the created by property