Ignite HashSet clearing

classic Classic list List threaded Threaded
3 messages Options
yann.blazart@externe.bnpparibas.com yann.blazart@externe.bnpparibas.com
Reply | Threaded
Open this post in threaded view
|

Ignite HashSet clearing

Hello all ! :)

We are using ignite HashSet in our processes to test unicity of Id's when we are importing files in our system.

I have 5 or 6 HashSet wich in my example can contains millions of lines. Insert and check is working great.
But in next step, when we do not need it anymore, we clear each of them, that process take 5 minutes !! Why ? Is there a fast way to delete these hashsets ?


Thks
Regards.
This message and any attachments (the "message") is
intended solely for the intended addressees and is confidential.
If you receive this message in error,or are not the intended recipient(s),
please delete it and any copies from your systems and immediately notify
the sender. Any unauthorized view, use that does not comply with its purpose,
dissemination or disclosure, either whole or partial, is prohibited. Since the internet
cannot guarantee the integrity of this message which may not be reliable, BNP PARIBAS
(and its subsidiaries) shall not be liable for the message if modified, changed or falsified.
Do not print this message unless it is necessary, consider the environment.

----------------------------------------------------------------------------------------------------------------------------------

Ce message et toutes les pieces jointes (ci-apres le "message")
sont etablis a l'intention exclusive de ses destinataires et sont confidentiels.
Si vous recevez ce message par erreur ou s'il ne vous est pas destine,
merci de le detruire ainsi que toute copie de votre systeme et d'en avertir
immediatement l'expediteur. Toute lecture non autorisee, toute utilisation de
ce message qui n'est pas conforme a sa destination, toute diffusion ou toute
publication, totale ou partielle, est interdite. L'Internet ne permettant pas d'assurer
l'integrite de ce message electronique susceptible d'alteration, BNP Paribas
(et ses filiales) decline(nt) toute responsabilite au titre de ce message dans l'hypothese
ou il aurait ete modifie, deforme ou falsifie.
N'imprimez ce message que si necessaire, pensez a l'environnement.

ilya.kasnacheev ilya.kasnacheev
Reply | Threaded
Open this post in threaded view
|

Re: Ignite HashSet clearing

Hello!

Have you tried igniteSet.close()?

Regards,
--
Ilya Kasnacheev


вт, 4 июн. 2019 г. в 12:47, [hidden email] <[hidden email]>:
Hello all ! :)

We are using ignite HashSet in our processes to test unicity of Id's when we are importing files in our system.

I have 5 or 6 HashSet wich in my example can contains millions of lines. Insert and check is working great.
But in next step, when we do not need it anymore, we clear each of them, that process take 5 minutes !! Why ? Is there a fast way to delete these hashsets ?


Thks
Regards.
This message and any attachments (the "message") is
intended solely for the intended addressees and is confidential.
If you receive this message in error,or are not the intended recipient(s),
please delete it and any copies from your systems and immediately notify
the sender. Any unauthorized view, use that does not comply with its purpose,
dissemination or disclosure, either whole or partial, is prohibited. Since the internet
cannot guarantee the integrity of this message which may not be reliable, BNP PARIBAS
(and its subsidiaries) shall not be liable for the message if modified, changed or falsified.
Do not print this message unless it is necessary, consider the environment.

----------------------------------------------------------------------------------------------------------------------------------

Ce message et toutes les pieces jointes (ci-apres le "message")
sont etablis a l'intention exclusive de ses destinataires et sont confidentiels.
Si vous recevez ce message par erreur ou s'il ne vous est pas destine,
merci de le detruire ainsi que toute copie de votre systeme et d'en avertir
immediatement l'expediteur. Toute lecture non autorisee, toute utilisation de
ce message qui n'est pas conforme a sa destination, toute diffusion ou toute
publication, totale ou partielle, est interdite. L'Internet ne permettant pas d'assurer
l'integrite de ce message electronique susceptible d'alteration, BNP Paribas
(et ses filiales) decline(nt) toute responsabilite au titre de ce message dans l'hypothese
ou il aurait ete modifie, deforme ou falsifie.
N'imprimez ce message que si necessaire, pensez a l'environnement.

Alexandr Shapkin Alexandr Shapkin
Reply | Threaded
Open this post in threaded view
|

Re: Ignite HashSet clearing

In reply to this post by yann.blazart@externe.bnpparibas.com
Hi!

Ignite iterates over the whole keys collection, then performs a remove(keys)
method. So if there are a lot of items and a distributed cluster, then this
would take a long time.

You can take a look into into regular IgniteCache, which has a destroy()
method.
And use put/get for insert/check operations.






--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
Alex Shapkin