Search Results

Search found 8 results on 1 pages for 'scarcher2'.

Page 1/1 | 1 

  • Using Apache Camel how do I unmarshal my deserialized object that comes in through a CXF Endpoint?

    - by ScArcher2
    I have a very simple camel route. It starts with a CXF Endpoint exposed as a web service. I then want to convert it to xml and call a method on a bean. Currently i'm getting a CXF specific object after the web service call. How do I take my serialized object out of the CXF MessageList and use it going forward? My Route: <camel:route> <camel:from uri="cxf:bean:helloEndpoint" /> <camel:marshal ref="xstream-utf8" /> <camel:to uri="bean:hello?method=hello"/> </camel:route> The XML Serialized Message: <?xml version='1.0' encoding='UTF-8'?> <org.apache.cxf.message.MessageContentsList serialization="custom"> <unserializable-parents /> <list> <default> <size>1</size> </default> <int>6</int> <com.whatever.Person> <firstName>Joe</firstName> <middleName></middleName> <lastName>Buddah</lastName> <dateOfBirth>2010-04-13 12:09:00.137 CDT</dateOfBirth> </com.whatever.Person> </list> </org.apache.cxf.message.MessageContentsList> I would expect the XML to be more like this: <com.whatever.Person> <firstName>Joe</firstName> <middleName></middleName> <lastName>Buddah</lastName> <dateOfBirth>2010-04-13 12:09:00.137 CDT</dateOfBirth> </com.whatever.Person>

    Read the article

  • How do I exit a series of If / else conditions in a mysql trigger?

    - by ScArcher2
    I have a trigger that checks to see if certain fields changed during the update. If any of these fields changed I update another table. I'd like to "break" out of the if conditions as soon as I know that something changed. Is there a way to do this within a MySQL Trigger? What I have works, but It seems inefficient. CREATE TRIGGER profile_trigger BEFORE UPDATE ON profile FOR EACH ROW BEGIN DECLARE changed INTEGER; SET changed = 0; IF STRCMP(NEW.first_name, OLD.first_name) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.last_name, OLD.last_name) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.maiden_name, OLD.maiden_name) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.suffix, OLD.suffix) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.title, OLD.title) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.gender, OLD.gender) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.street, OLD.street) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.street2, OLD.street2) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.city, OLD.city) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.state, OLD.state) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.zip, OLD.zip) <> 0 THEN SET changed = 1; ELSEIF STRCMP(NEW.home_phone, OLD.home_phone) <> 0 THEN SET changed = 1; ELSEIF NEW.date_of_birth <> OLD.date_of_birth THEN SET changed = 1; END IF; IF changed > 0 THEN update other_table set updated = CURRENT_TIMESTAMP where id = NEW.id; END IF; END; |

    Read the article

1