On Wed, May 6, 2015 at 6:54 AM, Arco <[email protected]> wrote:
> *1.Delay in call response*
>
(...)
>
> - Call getposts to get the latest posts (getposts 2-
> '[{"username":"arco"}, {"username":"john"}, {"username":"smith"}, ... + 130
> other users ... ]'
>
> This latest call, getposts returns some posts just after the user logged
> in, but one minute later the call doesn't get a response at all.
>
Just to clarify: does it mean the response is empty or that the call
doesn't return?
Did you try increasing -rpcthreads= ?
by default there are only 10 threads to service RPC calls (help says 4, but
it is wrong). standard twister-html client performs 6 simultaneous requests.
> I did notice though, that calling the getposts call with only one user
> does get a response after a while. (Is it bad practise to call getposts
> with all the users the user follows?)
>
No, that's the correct practice. Did you notice any cpu increased load due
to using all usernames? this is an interesting case to investigate.
>
> During this time I took a look at the debug.log and nothing seemed to
> happen. The only thing the deamon did was 'adding torrent for user [<random
> username>]'
>
Some mutexes may be held during that phase, but if they take such a long
time (to affect getposts) then i would qualify it as a bug.
>
> A possible cause might be that I am not shipping the right files of the
> blockchain, so the deamon is processing this database or whatsoever. See
> next question.
>
>
but this is usually shown in log (a frenetic blockchain activity validating
blocks).
> All in all the problem is that I can't show the user any posts when the
> client gets started for the first time. Making the user wait for 15 to 20
> minutes isn't really an option though.
>
agreed.
>
> *2.Shipping the blockchain*
> I'm want to ship the blockchain together with the application, I hope this
> is not bad practice?
>
No, sounds good.
> Which files should I ship exactly. At the moment I ship the following, and
> it seems to work fine but I would like to be sure that I am not sharing
> private or unnecessary data:
>
> - The folder blocks
> - The folder chainstate
>
>
I'd need to research this (it is just plain/old Bitcoin code, i didn't
wrote that part) but that seems correct imho.
>
> -
> - twister.conf
>
>
I prefer to generate twister.conf for each installation, so we may set
random rpcpassword instead of shipping a fixed file.
>
> -
>
> *3. Deamon size*
> The deamon (twisterd.exe) size of the Windows build I have is 147MB. Seems
> a bit big for a data processing application. Is this correct or did
> something go wrong with building maybe? I don't have a Linux instance to
> compare it with at the moment.
>
Just try "strip twisterd.exe". iirc that should reduce it to about 10-20 MB
by removing debug information.
regards,
Miguel
--
You received this message because you are subscribed to the Google Groups
"twister-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/d/optout.