GetStream.io throws exception on feed update

Viewed 38

I use Java API to publish and update activity.

public class EventModel extends BaseActivity {
    private String state;
    public String getState() {
        return state;
    }
    public void setState(String state) {
        this.state = state;
    }
}

When I publish activity I set all necessary fields like object, foreignid, time. I attached web hook to the feed group and can monitor feed data. It does allow me to add activity or replace -> delete + add. Web hook shows all correct data like new or deleted.

But when I try to update I do this.

Feed feed = streamClient.newFeed(<feed group>, <feed>);
List<EventModel> models = activityService.getActivities().getResults().stream().collect(Collectors.toList());

Iterate through the list and update state field to whatever, then call this

activityService.updateActivities(Arrays.asList(model));

where model is the instance of the EventModel collected above The last line throws "AuthenticationFailed" exception. I am not sure what that means. I have only 1 feed in the group, there is no any following and it allows me add and delete data.

As I said I only change my custom field and all other fields stay as they were before. Any help? Thanks

0 Answers
Related