1

I'm currently developing a web-site and ran into some bugs. In order to fix some bugs I need to reproduce them so I can debug and so forth.. Some bugs require me to do a repetitive specific combination of buttonclicks/checkbox markings within a limited timeframe. I.e. I need to be able to send multiple identical requests to the backend such that when a request is sent the previous request must not be done processing. This is the only way the bug can be reproduced.

Now, my problem is that my pc is too fast so I cant do the necessary steps quickly enough to reproduce the bug.. so my backend finishes processing each request before I can send a new request.

How do I go about solving reproducing issues like this? - I'm thinking about lowering the clockfrequence of the CPU, but that seems like going very far just to be able to recreate a bug. Is there some sort of test-framework which can be used to help this issue? - there is some sort of way to quickly resend requests via some browser-plugin.. I dont know.. and google hasnt found anything useful for me yet.. so I was hoping other developers here have had a similar issue and have some pointers for me :)

Linora
  • 10,418
  • 9
  • 38
  • 49
  • If you basically know what the problem is: `"I need to be able to send multiple identical requests to the backend such that when a request is sent the previous request must not be done processing."` Why do you need to reproduce the bug? You should be able to locate the bug within the source code based on that. If, this is however to test whether your fix is now properly handling the case, then that is a different story. :P – Ceiling Gecko Apr 03 '14 at 07:58
  • The problem is that the bug results in a NullPointer, but I dont know WHY the object is null.. this is why I want to see how the request looks like when arriving. I could wrap some line inside a null-check, but thats not a suitable solution as the object should never be null, thus the error lies somewhere else.. I need to debug and thus I need to reproduce the error – Linora Apr 03 '14 at 08:01
  • You could go backwards through the specific object's life-cycle up to when it was created and take notes where the object might have a possibility to become `null`. (e.g. Where object gets assigned a value, or where the value changes etc.) This is a long shot but since your computer appears to be too powerful to reproduce this error you could alternatively run a virtual machine on it emulating a slower computer to attempt to reproduce this error. – Ceiling Gecko Apr 03 '14 at 08:08
  • That is what I've tried doing.. but my original post was not directly related to this specific bug I'm facing, but more of a general question what to do in situations where you're not able to track the bug down by just looking at the code. Your suggestion of a virtual machine is a good idea.. I think I might give that a shot.. – Linora Apr 03 '14 at 08:16

1 Answers1

0

Consider using Apache JMeter, this is a tool that might suit you. It allows you to send multiple requests to remote server and perform actions based on response/missing of response/timeout etc.

Here is JMeter documentation: https://jmeter.apache.org/usermanual/index.html

Alexey Malev
  • 6,408
  • 4
  • 34
  • 52