cancel
Showing results for 
Search instead for 
Did you mean: 

SAP MDK Offline Store Partial Uploads

0 Kudos

Hi,

I'm implementing partial uploads in my SAP MDK offline application.

I have the following configuration on the offline upload action:

{
    "ActionResult": {
        "_Name": "upload"
    },
    "ActivityIndicatorText": "Uploading",
    "OnFailure": "(...)",
    "OnSuccess": "(...)",
    "Service": "/mobileapp/Services/MyService.service",
    "ShowActivityIndicator": true,
    "UploadCategories": [
        "FinalRequest"
    ],
    "_Type": "Action.Type.OfflineOData.Upload"
}

The problem is that this action is uploading all Categories instead of only the "FinalRequest" one.

The following requests are also being sent to the service.

{
    "ActivityIndicatorText": "Saving",
    "OnFailure": "(...)",
    "OnSuccess": "(...)",
    "Properties": {
       (...)
    },
    "RequestOptions": {
        "UnmodifiableRequest": false,
        "UpdateMode": "Replace",
        "UploadCategory": "IncompleteRequest"
    },
    "ShowActivityIndicator": true,
    "Target": {
        "EntitySet": "MyEntity",
        "ReadLink": "{@odata.readLink}",
        "Service": "/mobileapp/Services/MyService.service"
    },
    "_Type": "Action.Type.ODataService.UpdateEntity"
}

I'm currently using the MDK version that is deployed to the Android Store

Can someone help me configure the partial Uploads?

Thank you.

Jitendra_Kansal
Product and Topic Expert
Product and Topic Expert
0 Kudos

In which OData action you are passing UploadCategory as FinalRequest like you are passing as IncompleteRequest in above example?

Can you share details about that action as well?


0 Kudos

Hi jitendrakumar.kansal, in this example I'm using the same action but with a rule that uses the same action but modifies some properties:

context.executeAction({
            "Name": "/mobileapp/Actions/Service/uploadAction.action",
            "Properties": {
                "Target": {
                    "QueryOptions": "$filter=id eq '" + idVar + "'"
                },
                "OnSuccess": "",
                "RequestOptions": {
                    "UpdateMode": "Replace",
                    "UploadCategory": "FinalRequest"
                },
                "Properties": {
                    {...}
                }
            }

I've tried also with a separate action and I faced the same problem.

Jitendra_Kansal
Product and Topic Expert
Product and Topic Expert
0 Kudos

nuno_silva_oliveira49

I would recommend you open a support ticket (select component MOB-MDK) for this issue so it can be investigated further.

Jitendra_Kansal
Product and Topic Expert
Product and Topic Expert
0 Kudos

nuno_silva_oliveira49

Were you able to resolve your issue? If any of the responses helped you, then please mark the helpful answer by accepting it OR post an answer so others might benefit from your findings and then close this discussion.

Regards,
Jitendra (SAP Community Moderator)

Accepted Solutions (0)

Answers (0)