IRC logs of #tryton for Thursday, 2014-01-30

chat.freenode.net #tryton log beginning Thu Jan 30 00:00:01 CET 2014
2014-01-30 13:08 <jon1012> hi
2014-01-30 13:08 <jon1012> someone interfaced the tryton pos to magento ?
2014-01-30 13:18 <Pilou> jon1012: see https://github.com/openlabs/magento
2014-01-30 13:30 <Pilou> jon1012: oh wait it's not for tryton, sorry :-/
2014-01-30 13:39 <Pilou> In fact openlabs/mangento project is listed here https://imagento.openlabs.co.in/#faq, it seems you could use openlabs/project in a custom module
2014-01-30 13:56 <cedk> jon1012, Pilou: imagento is not opensource as far as I see
2014-01-30 13:58 <grasbauer> pokoli, rmu: dont know if search_rec_name is faster with the code provided by rmu - but it works
2014-01-30 14:00 <pokoli> grasbauer: but before you got errors, so it must be faster :)
2014-01-30 14:01 <grasbauer> pokoli, rmu: no errors - cpu was on 300% - but I guess that was because of an not uptodate index
2014-01-30 14:02 <pokoli> grasbauer: could you test it by removing the new code?
2014-01-30 14:02 <yangoon> grasbauer great cpu, where did you get it;)?
2014-01-30 14:05 <grasbauer> yangoon: ;)
2014-01-30 14:09 <Pilou> cedk: indeed. jon1012: but there is https://github.com/openlabs/trytond-magento too. I missed that one :)
2014-01-30 14:39 <jon1012> thanks
2014-01-30 14:39 <jon1012> I'll check :)
2014-01-30 14:42 <jon1012> if I find a way to use tryton for my pos solution, I'll owe you guys a couple of beers
2014-01-30 14:49 <grasbauer> pokoli, rmu: no difference with the OR
2014-01-30 15:23 <grasbauer> pokoli, rmu: my temporary solution: check in search_rec_name if len(clause[2]) > 6
2014-01-30 15:27 <grasbauer> pokoli, rmu: better solution could be to remove wildcards if len(clause[2]) <3 - if there is a product with a short code
2014-01-30 15:31 <grasbauer> nicoe: what do you think about a minimal length for applying wildcards to search_rec_name? Because typing one common letter in a big product table results in to much hits...
2014-01-30 15:40 -!- strebitz(~sebastian@91.183.59.105) has left #tryton
2014-01-30 18:47 <pokoli> grasbauer: maybe get_rec name search must be limited to 10 records only
2014-01-30 18:50 <cedk> pokoli, grasbauer: by the way, this do the work for account module: http://codereview.tryton.org/2901003/
2014-01-30 18:52 <pokoli> cedk: i suspect that nobody has 200.000 records in the account table :)
2014-01-30 18:53 <cedk> pokoli, grasbauer: patch is about OR
2014-01-30 18:53 <pokoli> cedk: i see, but grasbauer says that there is no diference with the OR and without the or
2014-01-30 18:55 <cedk> pokoli: depend how you measure it
2014-01-30 18:55 <cedk> pokoli: but for sure, it reduce the number of queries
2014-01-30 18:57 <pokoli> cedk: agree, so you will be in flavor to replace the old code with new OR format in all tryton modules?
2014-01-30 18:58 <grasbauer> cedk: I tried with or - for me the replacement of the wildcards was the solution: if there is only one common letter in the clause, i get 50.000 hits. making them to active record could be the bottleneck - so, if there is a product with a one-letter-code you will find that, but searching men
2014-01-30 18:58 <grasbauer> ans to know at least 2 letters :)
2014-01-30 18:58 <cedk> pokoli: yes
2014-01-30 19:00 <cedk> grasbauer: completion waits 300 msec before querying so if you are typing something it should not query for the first letters
2014-01-30 19:00 <cedk> except if you type very slowly but so you don't care about fast answer
2014-01-30 19:01 <cedk> by the way, search is limited by the client.limit which is 1000 by default
2014-01-30 19:01 -!- vcardon(~vcardon@LNeuilly-152-23-15-185.w193-252.abo.wanadoo.fr) has left #tryton
2014-01-30 19:05 <grasbauer> cedk: ok - I rewrite the domain like in account - its much faster now - first i didnt return the doamin, i returned ids
2014-01-30 19:07 <cedk> grasbauer: you should also think about adding a Trigram index: http://www.postgresql.org/docs/current/static/pgtrgm.html
2014-01-30 19:07 <grasbauer> cedk: ok
2014-01-30 19:09 <cedk> grasbauer: ha ok, it is the usage of id in [] which is a performance killer
2014-01-30 19:10 <grasbauer> cedk: so my first try with the OR but returning the ids didn't the trick - returning the domain it did
2014-01-30 19:11 <cedk> grasbauer: have you measurement?
2014-01-30 19:14 <grasbauer> cedk: impossible - the process was getting crazy, heavy cpu load and a roring fan :) so the 2nd solution its the better choice
2014-01-30 19:24 <rmu> grasbauer: i did write "return ['OR', ..." ;-)
2014-01-30 19:25 <grasbauer> rmu: so I messed up my time because of bad reading :(

Generated by irclog2html.py 2.17.3 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!