Recently I've posted this question, and I thought I had the answer, but there's a problem. I need to access the response object in the "success" and "failure" callbacks of the "save" method of a record:

Strange, the callbacks defined in "success" and "failure" are called too. Defining "callback" with my callback still receives an Ext.data.Operation object with no "response" object, which is what I need.

This is what I'm receiving in a failure case (from Chrome's console):

Code:

Ext.Class.newClass

action: "update"

callback: function (record, operation, success) {

error: undefined

exception: true

records: Array[1]

request: Ext.Class.newClass

running: false

scope: Ext.Class.newClass

success: false

__proto__: Class.registerPreprocessor.prototype

However, if I change the name of the property "callback" and I use "success", in a success case the response IS defined:

Sorry, but I don't understand how it works for you?
reader.jsonData
contains, in my case, entire data loaded so far to the store, but I need access to response object.
And later on to response.responseText. I handle entire batch of operations, so I actually need that for every operation in a batch, that failed.
How to get reference to response object for each operation, and WHY it is not included by default?!

on success I can assess that in the following way:
batch.operations[0].response.responseText

"response" in undefined in case of failure

EDIT: I have finally found rather ackward way of accessing response object in callback arguments! operation.request.callback.arguments[2]

EDIT2: the path provided above only works for the last operation in batch.