irida icon indicating copy to clipboard operation
irida copied to clipboard

Limit the number of samples in the cart

Open apetkau opened this issue 2 years ago • 0 comments

Describe your idea for a new feature

Right now we don't have any specific limit on the number of samples that can be sent to the cart. This could lead to situations where somebody fills up the cart with too many samples (10s of thousands) and crashes IRIDA. It would be nice if we had a configuration option to limit the number of samples that could be sent to the cart. For example, setting a limit of say 5,000 samples that can be added to a cart (and display an error message if more samples are added in addition to 5,000).

One possible complication is that we use the cart for potentially different tasks (e.g., running pipelines, or sending files to Galaxy). Each of these tasks might need it's own limit in addition to a limit on the cart as a whole.

Describe how you would access this feature?

This would be a configuration option in /etc/irida/irida.conf to limit the samples in the cart, and if somebody tries to add too many samples they would get an error message.

Additional information

In a particular case somebody added 24,000 samples to the cart and the following exception was encountered:

at org.hibernate.hql.internal.ast.util.JoinProcessor.doFindAllNodes(JoinProcessor.java:120)

apetkau avatar Oct 08 '21 15:10 apetkau