Open KarlLevik opened 7 years ago
Hi @KarlLevik,
We had an internal meeting and we all agreed that we are missing here the big picture of this. Could you explain what is the purpose and use case for Container Registry, Report and History?
Another minor comments are:
Thanks, A.
Hi @antolinos we do have barcode in the container table, however it assumes uniqueness (we use it for plate barcodes where it must be unique). Therefore if you register two containers you cannot use the same barcode, mx users obviously want to reuse their pucks.
Puck barcodes for most people dont exist at the moment, diamond now etches a barcode onto each unipuck, this is what we store in containerRegistry.barcode field. The is the same as say DLS-0001 that people would usually put into the container.code field. However code sometimes doesnt match the actual puck text, so containerRegistry.barcode is filled in by a staff member as they etch the puck, so we know it is consistent. This value is then used by the automated puck barcode scanners to assign pucks in ISPyB.
ContainerReport.report is some text that staff can fill in the explain if there is a problem with the puck, i.e. missing screws etc. This is emailed to the users. attachmentFilePath relates to this, it allows staff to attach a photo to the report.
Sorry forgot the first question!
DLS is slowly moving towards assigning pucks where ever there is beamtime disassociated from dewars. As part of this staff would like to keep track of where pucks are, usages, reporting, etc. The puck database allows us to do this.
DLS staff etch the DLS-0001 text as a qr code onto each puck as they receive them on site. This value is then registered into containerregistry.barcode and this registered container is linked to one or more proposals via containerregistry_has_proposal (sometimes pucks are shared between proposals). We now have a unique way to identify each puck.
When users create a shipment, now when they registered a container they can link the current "instance" of a puck to a registered "container" from container registry. The reason we do this and not use barcode / code fields in container is because they are inconsistent. Users often make mistakes with the text of code, which means they cannot be automatically matched on scanning.
We now register "history" against each container in the same way we register history against dewars. Puck DLS-1234 was loaded into position 4 on i03. This is recorded into history. We also use this on VMXi to record where containers are on the beamline, there are many different locations "storage", "goniometer", etc. Now we have auditable timestamped data for containers, which means you can search and locate them.
Long term we can now see how many times a puck has been used. Along with reporting we can see if a user has sent us a back a container that staff have already reported as broken, etc.
As discussed at the ISPyB meeting at Soleil earlier this week, Diamond has made some database schema developments for supporting a "puck database" within ISPyB. We now also have production code for this in Synchweb.
However, we are happy to make changes to the schema if anyone finds a problem with it. I've pasted in the create script below, but sadly there doesn't seem to be an easy way to attach the diagram.
The main table is ContainerRegistry, and the other tables are referencing that. An entry in ContainerRegistry can be associated with multiple Proposals through _ContainerRegistry_hasProposal. ContainerHistory will show the history of a given Container (i.e. the beamlines it's been to). ContainerReport allows a Person to write one or more reports about a Container in the ContainerRegistry.
Statements to remove the tables and columns created
Create statements
Can this be merged into the official schema?