• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
ERRest Update Op Fails
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

ERRest Update Op Fails


  • Subject: ERRest Update Op Fails
  • From: Benjamin Miller <email@hidden>
  • Date: Mon, 06 Dec 2010 17:58:19 +0000

I'm using ERRest to provide access to a number of entities in my app. Updating values in one entity fails silently and I can't figure out where to look. I suspect this may not be related to ERRest but when I'm using the same model and classes in other 'more traditional' (for me) areas of my app, there are no problems. Other entities using the same method update fine and the other CRUD actions behave normally.

I perform an update request:

PUT /cgi-bin/WebObjects/Patrol.woa/ra/suite_runs/10 HTTP/1.1

<SuiteRuns>
  <priority>11</priority>
</SuiteRuns>


I'm using modified example code to handle the request:

public WOActionResults updateAction() {
		SuiteRun suiteRun = routeObjectForKey("suiteRun");
		update(suiteRun, listFilter());
		editingContext().saveChanges();
		return response(suiteRun, showFilter());
	}

	public ERXKeyFilter updateFilter() {
		ERXKeyFilter filter = ERXKeyFilter.filterWithAttributes();
		filter.include(SuiteRun.TESTS);
		filter.include(SuiteRun.TEST_INVOCATIONS);
		return filter;
	}

The object to update looks OK, so does the EC used. update() appears to work and the new values are pushed into the EO. The EO isn't persisted to the database and the EC doesn't register any changes. As the EO is populated with the new values, a correct response is returned to the client. The save fail is silent and nothing appears in logs.

Any ideas where to start looking?

Thanks,
Benjamin

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: ERRest Update Op Fails
      • From: Farrukh Ijaz <email@hidden>
  • Prev by Date: Re: ERRest XML Entity Names
  • Next by Date: Re: ERRest Update Op Fails
  • Previous by thread: Re: ERRest XML Entity Names
  • Next by thread: Re: ERRest Update Op Fails
  • Index(es):
    • Date
    • Thread