redmine-net-api icon indicating copy to clipboard operation
redmine-net-api copied to clipboard

Issue Serialization

Open impoetk opened this issue 2 years ago • 8 comments

Trying to use WriteXml and ReadXml or WriteJson and ReadJson fails to set the identifiablename properties back from the generated xml/json

i think the issue is related to the read methods rely on the { id = , name = } and the write methods write them as { project_id = }

impoetk avatar Nov 27 '23 19:11 impoetk

Hi, How do you intend to use the Write/Read xml/json methods?

zapadi avatar Nov 27 '23 20:11 zapadi

Hello

Thanks for the quick reply, I intend to write a cache of issues in my application since the issue count is already over 5000 and paged results is quite slow, so my idea is to have a perpetual system reading updates (with local-lan access) from redmine, and then the other side of the application can interact with the services

for this i need to be able to reliably serialize and deserialize the issues locally in my assembly, i tried using the read/write json perhaps a new method that can be called "Serialize" and "Deserialize" will help a lot in this regard

impoetk avatar Nov 27 '23 21:11 impoetk

I could do the changes my self, but i'm not sure if you like the approach of additional serialization methods or perhaps an optional flag passed to the write/read mehtods indicating if it should be to localscope or redmine api scope

impoetk avatar Nov 28 '23 18:11 impoetk

Please, open a PR with proposed changes

zapadi avatar Nov 28 '23 19:11 zapadi

made the pr #340

impoetk avatar Nov 29 '23 16:11 impoetk

hello, can you review and perhaps comment on the approach?

impoetk avatar Dec 19 '23 01:12 impoetk

I've reviewed the Pull Requests (PR) and I am considering an alternative approach involving converters (XML and JSON). This would ensure a complete separation of the serialization and deserialization processes from Redmine objects. The project has recently undergone significant internal modifications, and I'll be sharing these updates shortly.

zapadi avatar Dec 19 '23 09:12 zapadi

If you need a helping hand with that just let me know I'll gladly help

impoetk avatar Dec 20 '23 06:12 impoetk