Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DELETEing an already deleted asset responds with old asset value; expected MTConnectError #449

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

mnoomnoo
Copy link
Contributor

@wsobel
Copy link
Member

wsobel commented Apr 28, 2024

I don't think this is the correct behavior. If you're requesting an asset by id, you should be able to get it. We should discuss.

@robot-ranger
Copy link
Contributor

when requesting an asset by asset id, how do we tell if that asset id had been previously deleted or not?

@robot-ranger
Copy link
Contributor

robot-ranger commented Apr 29, 2024

oh, i see removed="true" in the asset xml element. the issue is removed=true gets included in the response to both the first DELETE REST call, and any subsequent DELETE calls with the same asset id. (until the buffer cycles; obviously)

so it doesnt seem like there is a way to distinguish if the asset was deleted now because of my most recent DELETE or some previous action some time ago

@wsobel
Copy link
Member

wsobel commented Apr 29, 2024

The Asset block has a removed property: https://model.mtconnect.org/#Diagrams___19_0_3_91b028d_1579531819046_475681_8369

In XML it will have something like

<CuttingTool removed="true" ....>
</CuttingTool>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants