kitty created OLINGO-1251:
-----------------------------
Summary: Missing flush method in DataSource interface
Key: OLINGO-1251
URL: https://issues.apache.org/jira/browse/OLINGO-1251
Project: Olingo
Issue Type: Improvement
Components: odata2-annotation
Affects Versions: V2 2.0.8
Reporter: kitty
Hi,
We are using olingo in our project for consuming oData.
As entities are created using annotations so we have a class which implements
org.apache.olingo.odata2.annotation.processor.core.datasource.DataSource.
When I looked at the interface methods, I saw that there is no save/flush
method available.So if we want to save the odata content to some persistence
provider then it should be done within method createData. Just wondering if
odata received is of multi level content, for example
Employee->Employee_Details->Address, then createData would be called 3 times
for each entity, if there is any issue in Address then the first 2 entites are
already persisted which is wrong. Here all the 3 entities should be persisted
at a time.
There is one more method writeRelation, in this method if there is any issue
and if we don't want to persist the odata entities then we can't do that as
save is already triggered in createData.
Could you please tell me is there any way we can achieve the above behavior or
my understanding is wrong?
Thanks,
Kitty
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)