Posts

hadoop - Oozie Java Action System.out -

i have oozie java action. after completition of job, can't find system.out.println output in oozie log. i'm looking @ web console "job log" screen. see log output there related oozie job not system.out.println output. how can configure oozie can see outputs of `system.out.println? you should override log4j.properties inside hadoop jar file: -d log4j.configuration=path_to_file (with spacebar) for instance: oozie job -oozie "$oozieserverurl" -config $ooziepath/coordinator.properties -d log4j.configuration=path_to_file -run -verbose

linux - Make cannot find present cross compiler -

i'm using make file compile kernel arm/xilinx platform. i'm setting env variable cross_compile make file use. i'm trying use cross compiler, present on system, called arm-xilinx-linux-gnueabi-gcc setting env var in following ways; export cross_compile=/opt/xilinx/sdk/2015.2/gnu/arm/lin/bin/arm-xilinx-linux-gnueabi- export cross_compile=arm-xilinx-linux-gnueabi- the make file should append gcc . the error given both is make: /opt/xilinx/sdk/2015.2/gnu/arm/lin/bin/arm-xilinx-linux-gnueabi-gcc: command not found scripts/kconfig/conf --silentoldconfig kconfig make: /opt/xilinx/sdk/2015.2/gnu/arm/lin/bin/arm-xilinx-linux-gnueabi-gcc: command not found chk include/config/kernel.release chk include/generated/uapi/linux/version.h chk include/generated/utsrelease.h make[1]: `include/generated/mach-types.h' date. cc kernel/bounds.s /bin/sh: 1: /opt/xilinx/sdk/2015.2/gnu/arm/lin/bin/arm-xilinx-linux-gnueabi-gcc: not found make[1]: *** [k...

jquery - Java - Http Framework to Post XML Files -

i want learn java / java ee , therefore decide rewrite javascript application build in jquery, can send xml files against rest api. simplified looks like: var core = { senddata : function() { jquery.ajax({ url : "/test", method : "post", contenttype : "application/xml; charset=utf-8", data : json.strinigfy(xmlfeed), success : function(data) { // todo }, error : function() { // todo } }); } } i want build java application, can post xml files against rest api. rest api nescessary, xml file post request payload. tried jsoup, can not send xml files in way. there java framework, makes easier me build first java application? i found an article might you. suggests apache httpclient or jersey client. httpclient better focused on specific need because jersey server-side rest implementations, , ...

exchangewebservices - Microsoft Exchange Java API get messages based on date and number in folder -

i have program has method. public list<message> getmessages(int start, int end, date earliestdate) throws messagingexception { using java ews api how messages folder using these variables. instance if wanted 50th-70th message in inbox or want messages 10-20 starting on specific date. date can null doesn't matter much. i doubt efficient method possible oh well. public list<message> getmessages(int start, int end, date earliestdate) { if (start < 1 || end < 1 || end < start) { throw new messagingexception(string.format(locale.us, "invalid message set %d %d", start, end)); } int length = end - start; itemview view = new itemview(length); finditemsresults<item> findresults = null; try { if (earliestdate == null) { findresults = mservice.finditems(mfolder.getid(), view); } else{ search...

How long are new instances of Java stored? -

this question has answer here: life cycle of local java objects created during method call 4 answers garbage collection on local variable 3 answers so lately i've had question: how long object stored when create new instance of it? i'm asking how being stored. example: public void inituser(player player) { user u = new user(ally, player.getuuid()); u.sethealth(20); } (user being object) so how long u stored? java clean after i'm done it? (after #sethealth called)? thanks. there special part of java runtime called garbage collector takes care of destroying objects when no longer in use. application can allocate memory object via explicit , implicit ways under object creation, can not explicitly free memory . to signal jvm...

c++ - Do i need to delete a object that was constructed with new and placement -

class foo{ //some member public: int bar; } int main(){ char* buffer = new char[100]; foo* f = new(buffer)foo(); //do have delete f; //or delete[] buffer; //enough } sure have delete if delete of foo has major effect on system lets simple storage object place compleatly inside of buffer , has no deconstructor delete other things. do have delete object places new inside of buffer or enough delete buffer? if have call delete on every object inside of buffer, why have todo this? i read: what-uses-are-there-for-placement-new , says you should not deallocate every object using memory buffer. instead should delete[] original buffer. the correct way destroy object explicit destructor call: f-> ~foo(); usually placement new used memory on stack. in case, it's heap allocation, need free buffer using form of delete matches new . delete[] buffer;

ios - Swift: How to remove border from segmented control -

how remove outside border of segmented control in xcode? i've set divider image wanted follow mock of app need have segmented control without outer border. you can remove both borders , dividers using below function. create uisegmentedcontrol extension: for swift 2.2: extension uisegmentedcontrol { func removeborders() { setbackgroundimage(imagewithcolor(backgroundcolor!), forstate: .normal, barmetrics: .default) setbackgroundimage(imagewithcolor(tintcolor!), forstate: .selected, barmetrics: .default) setdividerimage(imagewithcolor(uicolor.clearcolor()), forleftsegmentstate: .normal, rightsegmentstate: .normal, barmetrics: .default) } // create 1x1 image color private func imagewithcolor(color: uicolor) -> uiimage { let rect = cgrectmake(0.0, 0.0, 1.0, 1.0) uigraphicsbeginimagecontext(rect.size) let context = uigraphicsgetcurrentcontext() cgcontextsetfillcolorwithcolor(context, color.c...