This is a migrated thread and some comments may be shown as answers.

Possible ways to customize AutoSave feature

2 Answers 229 Views
Extensions and Customization
This is a migrated thread and some comments may be shown as answers.
Rohit
Top achievements
Rank 1
Rohit asked on 07 Aug 2019, 11:58 AM
Hi,

I'm trying to figure out if there's a way to customize the AutoSave functionality. I'm expecting it to handle below scenarios:

1) All 4xx and 5xx errors should be send to one SAZ file, while the rest should be written to separate SAZ file as Fiddler currently works.
2) I wish to maintain single and unique Error.SAZ file in the FiddlerAutoSave folder:
     2.1) First time, the SAZ file need to be created, and once the file is in place, the subsequent file writing basically should perform an add/update operation, i.e. add the new sessions to the SAZ file, instead of creating new files with timestamp.
      2.2) Avoid duplicate URLs. While writing, it should check if there's already an erroneous URL present, then ignore, otherwise, continue adding session to the SAZ file.

I hope you see why the ask is. Basically, I'm trying to fix the many 4xx and 5xx errors in the application, and having to go through many duplicates among several SAZ files is time consuming, so thinking to throw some programming around it. I'm not familiar with the language Fiddler has been written, so looking for some guidance on where to start.

Thanks for looking into it.

Cheers,

2 Answers, 1 is accepted

Sort by
0
Eric
Top achievements
Rank 1
answered on 10 Aug 2019, 09:28 PM

Fiddler's AutoSave isn't configurable in the way you describe.

But it would be straightforward to write a little function in FiddlerScript or an extension that loads an auto-save generated SAZ file and pulls all of the 4xx/5xx responses from it, and sticks those with unique URLs in another SAZ file.

Unfortunately, having Fiddler's SAZ engine doesn't have any functionality that allows you to "append" to a SAZ file-- your code would have to load all of the existing Sessions from the SAZ, then add new ones, then overwrite the SAZ file.

0
Rohit
Top achievements
Rank 1
answered on 11 Aug 2019, 05:45 AM

Thank you Eric for the reply. I'd prefer the extension route over FiddlerScript.

[quote]

But it would be straightforward to write a little function in FiddlerScript or an extension that loads an auto-save generated SAZ file and pulls all of the 4xx/5xx responses from it, and sticks those with unique URLs in another SAZ file.

[/quote]

All I'm see is Utilities.ReadSessionArchive(), but not sure how to filter 4xx/5xx responses then then write those to another SAZ file. Can you please share some sample code to achieve this? 

Cheers,

Tags
Extensions and Customization
Asked by
Rohit
Top achievements
Rank 1
Answers by
Eric
Top achievements
Rank 1
Rohit
Top achievements
Rank 1
Share this question
or