Posts

Showing posts from January, 2011

Nuget SignalR installs jQuery 1.6.4 -

i use install-package on package manager command line type: install-package microsoft.aspnet.signalr i have jquery 1.7.4 nuget installs 1.6.4 i trying use nuget uninstall-package command rid of jquery 1.6.4 pm> uninstall-package jquery 1.6.4 uninstall-package : no compatible project(s) found in active solution. shall delete javascripts 1.6.4, nuget adding stuff packages.config , packages folder in solution part of source control just delete it, or don't use in code, should ok since jquery 1.7.4 should supported from asp.net signalr hubs api guide - javascript client a javascript client requires references jquery , signalr core javascript file. jquery version must 1.6.4 or major later versions, such 1.7.2, 1.8.2, or 1.9.1.

windows phone 7 - C# panorama view 2 titles -

is possible give panorama view 2 pages, separate titles? page 1 example "heading 1" , page 2 "heading 2", not using subheadings each panorama item, title property of main panorama control thanx you set text of title nothing. use margin property of subheadings move them title be. when setting margin put second number negative move object page. (example: margin="0,-50,0,0")

javascript - JS - Regular Expression for 12hr Time Matching -

i attempting take regular expression being used in java application , use javascript. (1[012]|[1-9]):[0-5][0-9](\\s)?(?i)(am|pm) however, running issues. getting syntaxerror: invalid quantifier error. escaped ? , ended with (1[012]|[1-9]):[0-5][0-9](\s)?(\?i)(am|pm) however, when run following test, not matching properly: "1:00 am".match(/(1[012]|[1-9]):[0-5][0-9](\s)?(\?i)(am|pm)/) this regex should matching “1:00am”, “1:00 am”, ”1:00 am” where going wrong? try "1:00 am".match(/(1[012]|[1-9]):[0-5][0-9]\s?(am|pm)/i) the ignore case flag i should @ end of regex

java - How to get a substring from a string -

i have xml file i'm reading string, http://localhost:8080/sdpapi/request/10/notes/611/ my question how can 611, of variable, can 100000, example, string? split string string input = "http://localhost:8080/sdpapi/request/10/notes/611/"; string output = input.split("notes/")[1].split("/")[0]; output value need

linux - Changing highlight line color in emacs -

Image
i installed emacs 24 , installed prelude , wanted change theme zenburn tango-dark. color line highlighted yellow , don't that. want gray color in zenburn. what should do? prefer not turn off hl-line when tried saw space between parentheses () highlighted same yellow color. (in zenburn theme didn't happen). know not part of tango theme because when run vanilla emacs(sudo emacs) tango theme no such highlighting happens. that easy fix if customize init file ( ~/.emacs , ~/.emacs.el , or ~/.emacs.d/init.el ) turn on hl-line: (global-hl-line-mode 1) set color background face of current line: (set-face-background 'hl-line "#3e4446") to keep syntax highlighting in current line: (set-face-foreground 'highlight nil)

windows runtime - Porting to WinRT apps: How to use NMAKE to call winRT apps in build process -

i trying port open source library winrt. in original setup few projects compile form .exe called makefile using nmake. these .exe used prepare data .dll .txt(raw data files). now porting have converted exe projects winrt apps. did adding package.appxmanifest files , assests folder. making changes in project settings of exe. in configuration manager, have checked option deploy after building these apps. need call these exe. how this? please help.

How to import css/js in spring MVC application jsp page -

i new spring mvc , creating user registration page , there need put external css , import external js . i put script tag src , link tag href. think in spring mvc application not work straight forward. added resourceservlet mapping still not working i not able find way how csn include these assets in jsp file. please me one. regards, pranav i added following mapping but after getting exception trace below severe: exception sending context initialized event listener instance of class org.springframework.web.context.contextloaderlistener org.springframework.beans.factory.xml.xmlbeandefinitionstoreexception: line 34 in xml document servletcontext resource [/web-inf/mvc-dispatcher-servlet.xml] invalid; nested exception org.xml.sax.saxparseexception: cvc-complex-type.2.4.c: matching wildcard strict, no declaration can found element 'mvc:resources'. @ org.springframework.beans.factory.xml.xmlbeandefinitionreader.doloadbeandefinitions(xmlbeandefinitionreader.jav...

python - Numpy, dot products on multidimensional arrays -

i have doubts on numpy.dot product. i define matrix 6x6 like: c=np.zeros((6,6)) c[0,0], c[1,1], c[2,2] = 129.5, 129.5, 129.5 c[3,3], c[4,4], c[5,5] = 25, 25, 25 c[0,1], c[0,2] = 82, 82 c[1,0], c[1,2] = 82, 82 c[2,0], c[2,1] = 82, 82 then recast in 4-rank tensor using multidimensional array def long2short(m, n): """ given 2 indices m , n of stiffness tensor function return index of voigt matrix = long2short(m,n) """ if m == n: = m elif (m == 1 , n == 2) or (m == 2 , n == 1): = 3 elif (m == 0 , n == 2) or (m == 2 , n == 0): = 4 elif (m == 0 , n == 1) or (m == 1 , n == 0): = 5 return c=np.zeros((3,3,3,3)) m in range(3): n in range(3): o in range(3): p in range(3): = long2short(m, n) j = long2short(o, p) c[m, n, o, p] = c[i, j] and change coordinate reference system of tensor using rotation matrix ...

c# - Web API 'Request' is null -

i'm trying return httpresponseexception post web api action using 'request': throw new httpresponseexception(request.createerrorresponse(httpstatuscode.notfound, "file not in correct size")); when doing so, value cannot null. parameter name: request . essentially - request null. what missing? thank you use this: httpresponsemessage message = new httpresponsemessage(httpstatuscode.internalservererror); message.content = new objectcontent(typeof(messageresponse), "invalid size", globalconfiguration.configuration.formatters.jsonformatter); throw new httpresponseexception(message); note: can change "invalid size" object may want return user. e.g.: public errormessage { public string error; public int errorcode; } errormessage msg = new errormessage(); msg.error = "invalid size"; msg.errorcode = 500; httpresponsemessage message = new httpresponsemessage(httpstatuscode.internalservererror); message...

ruby on rails - Opening an existing class in Redmine Plugin file -

i'm writing plugin on redmine. i want add new method inside existing controller of redmine. controller name repositories. i wrote in repositories.rb following code: class repositoriescontroller < applicationcontroller def exec_client ... end end in routes.rb put: match '/projects/:id/repository', :controller => 'repositories', :action => 'exec_client', :via => :post in view navigation.html.erb wrote: <%= button_to_function l(:gerar_build_project), remote_function(:action => 'exec_client', :controller => 'repositories')%> the code of class repositoriescontroller written on file repositories_controller.rb. but, when click in button i've created in view, following message: abstractcontroller::actionnotfound (the action 'exec_client' not found repositoriescontroller): what's going wrong? to extend class in redmine plugin , add new methods, need follow these st...

php - DynamoDb retrieve data Order by descending order and then use pagination like sql syntax -

i facing problem retrieve records in descending order pagination limit amazon dynamodb in mysql. using following script, gives unordered list of records. need last inserted id on top. $limit = 10; $total = 0; $start_key = null; $params = array('tablename' => 'event','attributestoget' =>array('id','interactiondate','repname','totalamount','fooding','nonfooding','pdfdocument','ismultiple','payment_mode','interaction_type','products','programtitle','venue','workstepid','foodingother','interaction_type_other'), 'scanfilter'=> array('manufacturername' => array("comparisonoperator" => "eq", "attributevaluelist" => array(array("s" => "$manufacturername")))),'limit'=>$limit ); $itemsarray = array(); $itemsarray = array(); $finalitemsa...

unix - How to find out which process is eating that much memory? -

output of # top -o size last pid: 61935; load averages: 0.82, 0.44, 0.39 10+13:28:42 16:49:43 152 processes: 2 running, 150 sleeping cpu: 10.3% user, 0.0% nice, 1.8% system, 0.2% interrupt, 87.7% idle mem: 5180m active, 14g inact, 2962m wired, 887m cache, 2465m buf, 83m free swap: 512m total, 26m used, 486m free, 5% inuse pid username thr pri nice size res state c time wcpu command 1471 mysql 62 44 0 763m 349m ucond 3 222:19 74.76% mysqld 1171 root 4 44 0 645m 519m sbwait 0 20:56 3.86% tfs 41173 root 4 44 0 629m 516m sbwait 4 19:17 0.59% tfs 41350 root 4 44 0 585m 467m sbwait 7 15:17 0.10% tfs 36382 root 4 45 0 581m 401m sbwait 1 206:50 0.10% tfs 41157 root 4 44 0 551m 458m sbwait 5 16:23 0.98% tfs 36401 root 4 45 0 199m 108m uwait 2 17:50 0.00% tfs 36445 root 4 44 0 199m 98m uwait 4 20:...

python - sqlalchemy generic foreign key (like in django ORM) -

does sqlalchemy have django's genericforeignkey? , right use generic foreign fields. my problem is: have several models (for example, post, project, vacancy, nothing special there) , want add comments each of them. , want use 1 comment model. worth to? or should use postcomment, projectcomment etc.? pros/cons of both ways? thanks! the simplest pattern use have separate comment tables each relationship. may seem frightening @ first, doesn't incur additional code versus using other approach - tables created automatically, , models referred using pattern post.comment , project.comment , etc. definition of comment maintained in 1 place. approach referential point of view simple , efficient, dba friendly different kinds of comments kept in own tables can sized individually. another pattern use single comment table, distinct association tables. pattern offers use case might want comment linked more 1 kind of object @ time (like post , project @ same time). pat...

css - "vertical-align:middle" does not work when apply the container element "float" -

this question has answer here: css vertical align not work float 3 answers the following code works well: <div id="container"> <p>test</p> </div> #container{height:500px;display:table-cell;vertical-align:middle;} but when container element has css property: float:left it cannot work!! i want vertical-middle while floating you must set line-height in case: line-height:500px

rhomobile - how to use httpclient in Rho-Mobile -

i new rho-mobile, , want know whether or not can use http-client , how? i googled apis rho-mobile unfortunately, not find useful info. the rhomobile have asynchhttp api. rhomobile docs have few examples of how use here . alternative, can use ruby net/http library. explained here , how use net/http extension rhodes application.

javascript - AngularJS - Directives, ng-repeat, ng-click and Jquery -

trying 3d party jquery library working 2 pretty simple custom directives: can't ng-click work , not sure how data repeated element in link function. when click on slide it's name , hidden data should append on list below it. jsfiddle angular.module('sm', []) .directive('selector', function () { return { restrict: "e", template: '<div class="swiper-wrapper">' + '<div class="swiper-slide" ng-repeat="slide in slides">' + '<h1 ng-click="selected(slide)">{{ slide.name }}</h1>' + '</div></div>', replace: true, controller: ['$scope', '$timeout', function ($scope, $timeout) { $scope.slides = [{ name: 'one', hidden: 'kittens' }, { name: 'two', hidden: 'puppies' }, { name: ...

html - CSS getting text in one line rather than two -

i have small issue title text display on single line rather split onto 2 im trying arrange these blocks grid jsfiddle html <div class="garage-row"> <a class="garage-row-title" href="/board/garage_vehicle.php?mode=view_vehicle&amp;vid=4"> <div class="garage-title">1996 land rover defender</div> <div class="garage-image"><img src="http://enthst.com/board/garage/upload/garage_vehicle-4-1373916262.jpg"></div> </a> <div class="user-meta"> <b> <a href="{block_1.row.u_column_2}">hobbs92</a> </b> </div> </div> css @import url(http://fonts.googleapis.com/css?family=open+sans); .garage-row { border: 1px solid #ffffff; float: left; margin-right: 5px; padding: 12px; position: relative; width: 204px; } .garage-row img{} .gara...

301 Redirects on any non existent image, pdf or url using .htaccess -

i have website updated , problem google bot indexes website gives lot of 404/500 errors when image not exist anymore or has been deleted. it's product catalogue website, products deleted , added on hourly basis. i've tried rewriterule ^/(.*)$ /site/page/view/404 [r=301,l] which causes images on website not display more or ^(.*) /site/page/view/404 [r=301,l] which gives error 500 on browser. is there way match non existent files/urls , redirect them permanently different url e.g. /site/page/view/404 try (assuming .htaccess in web root) rewriteengine on rewritebase / rewritecond %{request_filename} !-d # not dir rewritecond %{request_filename} !-f # not file rewriterule ^.*$ /site/page/view/404 [r=301,l] alternatively, can use errordocument well. errordocument 404 /site/page/view/404

Powershell, JSON and NoteProperty -

i'm trying use zabbix api powershell automate monitoring stuff. i'd retrieve "items" based on different parameters passed function : if -itemdescription parameter passed, description and/or if parameter -host passed limit scope host etc... can find method description here : https://www.zabbix.com/documentation/1.8/api/item/get this correct request : { "jsonrpc":"2.0", "method":"item.get", "params":{ "output":"shorten", "search": {"description": "apache"}, "limit": 10 }, "auth":"6f38cddc44cfbb6c1bd186f9a220b5a0", "id":2 } so, know how add several "params", did host.create method, : $proxy = @{"proxyid" = "$proxyid"} $templates = @{"templateid" = "$templateid"} $groups = @{"groupid" = "$hostgroupid"} ... add-member -passthru noteproperty p...

Struts2 display stream pdf -

i want display pdf stream in new popup windows, when stream empty, want write error message in current page (edition.jsp) in edition.jsp page : <s:form id="pdf" action="exportpdf" theme="simple" target="pageedition" > ... <sj:menu name="typeedition" cssclass="edition" list="listeeditions" /> </s:form> in struts.xml : <action name="exportpdf" class="exportpdfaction"> <result name="success" type="stream"> <param name="inputname">inputstreampdf</param> <param name="contenttype">application/pdf</param> <param name="contentdisposition">filename="myfile.pdf"</param> <param name="buffersize">2048</param> </result> <result name="error">/web-inf/web/edition.jsp</result>...

c++ - STL size_type(-1) vs size_t(-1) -

this question has answer here: when should use vector<int>::size_type instead of size_t? 4 answers 'size_t' vs 'container::size_type' 3 answers in c++ stl implementation, see code block: size_type max_size() const { return size_type(-1); } i understand works when size_type size_t. purpose of adding indirect level here? i.e. why not use size_t(-1) directly in max_size() ? is there specification says (size_type(-1)) should evaluate maximum object size on platform)...

c++ - Mex runtime error: Unexpected standard expression -

this question has answer here: c++ : exception occurred in script: basic_string::_s_construct null not valid 3 answers i new mex. after building c++ mex file, error @ runtime. >> [a b c] = read_svm('/all/testhalf_anger_1.libsvm'); unexpected standard exception mex file. what() is:basic_string::_s_construct null not valid .. this execution of code looks thank in advance! the error message explains well, somewhere in code you're constructing basic_string passing null pointer constructor. basic_string constructor takes chart * requires pointer non-null, hence crash. note std::string , std::wstring typedefs std::basic_string class template, may using 1 of these in code. you can fix doing similar following snippet char const *p = nullptr; // std::string s(p); // not allowed! std::string s( p ? p : "" ); // string emp...

arduino c++ issues regarding class name -

i working on connecting philips hue light bulbs arduino , found resources online. 1 of resources has file keeps throwing error , when looked @ it, have never seen syntax used before. can me out? #ifndef serialhue_h #define serialhue_h #include <arduino.h> #include <stream.h> #include <arduinohue.h> class serialhue: public arduinohue{ public: serialhue(char* ipaddress, stream* serial); boolean connect(char* deviceid, char* username); protected: char* _ipaddress; char* _deviceid; char* _username; boolean makepost(char* request, char* data); boolean waitforresponse(); stream* _serial; }; #endif the error in line: * class serialhue: public arduinohue{ * giving error: serialhue.h:10: error: expected class-name before '{' token what format , wrong here? check compiler settings...it might possible tries compile c++ code c compiler about format: class x : public y { } is syntax of extending class in c++ plus: check arduinohue.h ...

Field inheritance on Java -

are fields inherited "one level up"? by mean if have superclass class, has subclass, , superclass has field, class inherit , subclass won't. correct? and if is, there way make subclass automatically inherit field superclass given that, understand it, there's no way inherit 2 classes @ once? thank takes time answer. realize question may impractical , in reality you'd override field or something, i'm not trying specific, trying learn how java works. thank you. here's code: public class superclass { protected int entero; protected void method(){ entero=1; } public class subclass extends class { public subclass(){} } public class class extends superclass { public class(){} } public static void main(string[] args){ class object= new class(); subclass subobject= new subclass(); /*this error, why?*/ subobject.entero=2; /*this 1 fine*/ object.entero=2; object.method(); ...

c++ - Why do generic programming designs prefer free functions over member functions? -

i got introduced design of generic programming libraries stl, boost::graph, boost propertymaps http://www.boost.org/doc/libs/1_54_0/libs/property_map/doc/property_map.html what rationale behind using free functions get(propertymap, key) on member functions propertymap.get(key)? i understand generic form of these functions defined in "boost" namespace. suppose define new propertymap in namespace "project", best place define it's corresponding "get" function? "boost" or "project" the main motivation preferring nonmember nonfriend functions helps keep classes concise possible. see herb sutter's article here: http://www.gotw.ca/publications/mill02.htm . this article contains answer other part of question, put corresponding function. it's feature of c++ called argument dependent lookup (adl). herb sutter, calls koenig lookup although name controversial (see comments below): koenig lookup says that, if s...

Android: Service value to a BroacastReceiver -

i beginner , read posts service , broadcastreceiver components. still not now, here. have service (class: exampleservice) changes variable k: @override protected void onhandleintent(intent intent) { while (k < 1000) { if(forward==true){ k++; }else{ k--; } synchronized (this) { try { wait(100); } catch (interruptedexception e) { // todo auto-generated catch block e.printstacktrace(); } } } k = 0; this.stopself(); } public long getint(){ return k; } and broadcastreceiver: broadcastreceiver broadi=new broadcastreceiver(){ @override public void onreceive(context arg0, intent arg1) { // todo auto-generated method stub exampleintentservice se=new exampleintentservice(); text.settext("count:"+string.valueof(se.getint())); } }; so create object of service , try value 'getint()' method. returns 0 , dont know why. tips? wh...

etl - Pentaho Data Integration (DI) Get Last File in a Directory of a SFTP Server -

Image
i doing transformation on pentaho data integration , have list of files in directory of sftp server. files named file_yyyymmddhhiiss.txt format, directory looks that: mydirectory file_20130701090000.txt file_20130701170000.txt file_20130702090000.txt file_20130702170000.txt file_20130703090000.txt file_20130703170000.txt my problem need last file of list in accordance of creation date, pass other transformation step... how can in pentaho data integration? in fact quite simple because file names can sorted textually, , max in sort list recent file. since list of files short, can use memory group by step. grouping step needs separate column aggregate. if have column , want find max in entire set, can add grouping column add constants step, , configure add column with, integer 1 in every row. configure memory group by group on column of 1s, , use file name column subject. select maximum grouping type. produce single row grouping column, file name field r...

ios - How to effectively deal with large datasets in Core Data? -

i using core data in app store entities have many 50k objects or more. have paired nsfetchedresultscontroller in table view. table view works fine due cell reuse biggest problem queuring actual database dataset. when first load table view need results db. using default fetch request single sort descriptor , have set batchsize 1,000. on ipad 2 query takes 15 secs finish! have run query after search has been cancelled overall makes app unusable. assumption cd still has resolve results or setup sections or something, have no idea using batchsize doesn't help?? content dynamic in sense new rows getting added, sort order changing etc.. caching has limited benefit. i thinking best option use fetchlimit in fetchrequest , implement basic paging. when table view scrolls end fetch next "page" of results? problem approach lose sectionindex , cant think of way around that. anyone have ideas or dealt issue already? when set fetch request frc batch size should few i...

android - update Database with JSON class crashing -

the update class crashing cant open it, , didn't understan logcat: 07-17 19:28:22.115: d/dalvikvm(3799): gc_for_alloc freed 133k, 23% free 12979k/16808k, paused 254ms, total 278ms 07-17 19:28:22.623: d/dalvikvm(3799): gc_for_alloc freed 15k, 15% free 14345k/16808k, paused 58ms, total 58ms 07-17 19:28:22.666: i/dalvikvm-heap(3799): grow heap (frag case) 16.517mb 2514028-byte allocation 07-17 19:28:22.863: d/dalvikvm(3799): gc_for_alloc freed <1k, 13% free 16800k/19264k, paused 192ms, total 192ms 07-17 19:28:23.003: d/dalvikvm(3799): gc_concurrent freed 0k, 13% free 16800k/19264k, paused 8ms+24ms, total 147ms 07-17 19:28:23.133: d/dalvikvm(3799): gc_for_alloc freed 1380k, 13% free 16801k/19264k, paused 57ms, total 58ms 07-17 19:28:23.173: i/dalvikvm-heap(3799): grow heap (frag case) 18.916mb 2514028-byte allocation 07-17 19:28:23.443: d/dalvikvm(3799): gc_concurrent freed <1k, 12% free 19256k/21720k, paused 109ms+10ms, total 269ms 07-17 19:28:28.693: d/androidruntime(3799...

c# - How to get ignorewhitespaces to work with escape sequences -

if (regex.ismatch(line, "^([\\w\\-\\ ]+)\\ ,([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+),([^,]+)", regexoptions.ignorepatternwhitespace)) how ignorepatternwhitespace work above. works @" .... " because of amount of quotes , backslashes went " ... " , escape them wth backslashes instead of @" ... " , doubling down quotes. works huge line instead of neat little blocks. the reason language specification prohibits normal string literal ( "normal string literal" ) spanning lines -- is, may not contain embedded literal newline character. at-strings this @"this string spans lines " may span lines in above. what can to take advantage of c#'s constant folding , build string along these lines: regex foo = new regex( " part 1" ...

mysql - Can I re-insert a row with a newly created auto_increment primary key -

edit: i want update id newly created auto increment id, rest of row's columns not change. original: i've got table in mysql looking like: id userid productid all columns ubigint, , id primary key, set auto increment. so want re-insert row same table, newly created id. , old row should deleted! i'm using id order (higher == newer). is possible, because other option adding timestamp column , updating column, won't use timestamp. want prevent @ costs. let's have following table create table ( `id` int(11) not null auto_increment, `num` varchar(20) not null, primary key (`id`), unique (`num`) ) engine=innodb default charset=utf8; then can use following query insert new row insert (num) values ("hi") on duplicate key update id=last_insert_id()+1; if there "hi"-row query update it's id equal next after last inserted in case insert table (userid, productid) values (someuserid, someproductid...

c# - Unable to locate .MSI package -

i've used autoupdatordotnet dll auto-update application. i've done things according documentation codeplex site. app check updates perfectly. download update perfectly but... when try install new update shows error "an error occured attempting install setup" , in details pane... shows "unable locate application file 'setup.msi" nothing found in documentation of autoupdaterdotnet regarding error. please me out. thanks alot

c++ - error C2440 in driver file -

i keep receiving error on driver program. have develop driver program. driver program print menu allowing user choose option want. have never created driver program before, pretty rough. the error: cpp(38) error c2440: '=' : cannot convert 'void (__cdecl *)(void)' 'int' what have tried: -i have tried changing variables int void, vice-versa. //banking system driver program #include "bankingsystem.h" // account class definition #include <iostream> #include <fstream> #include <iomanip> #include <cstdlib> // exit function prototype using namespace std; void enterchoice(); void createtextfile( fstream& ); void updaterecord( fstream& ); void newrecord( fstream& ); void deleterecord( fstream& ); void outputline( ostream&, const account & ); int getaccount( const char * const ); enum choices { print = 1, update, new, delete, end }; int main() { // open file reading , writing fstream in...

apache zookeeper - Hbase: HConnectionManager$HConnectionImplementation Fatal Error -

i attempting htable htablepool , error. can me understand means , how go troubleshooting , fixing it? org.apache.hadoop.hbase.client.hconnectionmanager$hconnectionimplementation: unexpected exception during initialization, aborting org.apache.zookeeper.keeperexception$connectionlossexception: keepererrorcode = connectionloss /hbase/master @ org.apache.zookeeper.keeperexception.create(keeperexception.java:99) @ org.apache.zookeeper.keeperexception.create(keeperexception.java:51) @ org.apache.zookeeper.zookeeper.exists(zookeeper.java:1021) @ org.apache.hadoop.hbase.zookeeper.recoverablezookeeper.exists(recoverablezookeeper.java:171) @ org.apache.hadoop.hbase.zookeeper.zkutil.watchandcheckexists(zkutil.java:226) @ org.apache.hadoop.hbase.zookeeper.zookeepernodetracker.start(zookeepernodetracker.java:82) @ org.apache.hadoop.hbase.client.hconnectionmanager$hconnectionimplementation.setupzookeepertrackers(hconnectionmanager.java:581) @ org.apache.hadoop.hbase.client.hconnectionmanage...

setting up multiple queues using TORQUE -

i set 2 different queues using torque on rocks. each functional different sets of compute nodes, of these compute nodes can accessed same mother node or head node. need know how using qmgr command. also, know how add different nodes in 2 different queues. i met same problem. perhaps find solution here: queue configuration

java - Inheriting Nested classes into Subclass -

when going through this article, under section private members in superclass , saw line a nested class has access private members of enclosing class—both fields , methods. therefore, public or protected nested class inherited subclass has indirect access of private members of superclass. my question how can directly access nested class of base in derived (like can access public , protected fields)? and if there way, how can derived access p private field of base through nested ? public class base { protected int f; private int p; public class nested { public int getp() { return p; } } } class derived extends base { public void newmethod() { system.out.println(f); // understand inheriting protected field // how access inherited nested class here? , if accessed how retrieve 'p' ? } } thanks in advance time , effort in thread! base.nested theclassbro= new base.nest...

ios - ABPersonViewController does not have a navigationBar -

i writing application based on uiviewcontroller. not have navigation bar. application works addressbook. use 2 things. the first (select people): { abpeoplepickernavigationcontroller *picker = [[abpeoplepickernavigationcontroller alloc] init]; picker.peoplepickerdelegate = self; [self presentmodalviewcontroller:picker animated:yes]; } and second (select phone): { abpersonviewcontroller *picker = [[[abpersonviewcontroller alloc] init] autorelease]; picker.personviewdelegate = self; picker.displayedperson = person; picker.displayedproperties = [nsarray arraywithobjects: [nsnumber numberwithint:kabpersonphoneproperty], nil]; [self presentmodalviewcontroller:picker animated:yes]; } they called in different functions. in first case when picker displayed, has navigation bar buttons: cancel etc. in second case picker not have navigation bar. so, if select phone works if want return without making choice - not have button "back" or ...

html - How can i resize images in a table in twitter bootstrap? -

i want images in table resize. how can that? here table code: <table class='table' border='2'> <tr> <td class='click go0' id='1'><img src='../images/null.png'></td> <td class='click go0' id='2'><img src='../images/null.png'></td> <td class='click go0' id='3'><img src='../images/null.png'></td> ... </tr> ... </table> on bootstrap site, says tables not responsive. have put them in else make them responsive.

bash - “unary operator expected” in shell script -

i need script keep polling "receive_dir" directory till "stopfile" written in directory. this has run despite empty directory. so far have fails if receive_dir empty no files "unary operator expected". !! #!/usr/bin/ksh until [ $i = stopfile ] in `ls receive_dir`; time=$(date +%m-%d-%y-%h:%m:%s) echo $time echo $i; done done this ask (loop until stop file exist). added "sleep 1" lower resource usage. it's practice use "#!/usr/bin/env ksh" shebang. #!/usr/bin/env ksh until [ -e receive_dir/stopfile ] time=$(date +%m-%d-%y-%h:%m:%s) echo $time sleep 1 done

multithreading - get thread ID or name in python 2.6 -

i trying thread id or name in python 2.6 follow examples errors global name 'currentthread' not defined global name 'current_thread' not defined (i tried both currentthread , current_thread) here code : vim f3q.py 1 import queue 2 threading import thread 3 4 def do_work(item): 5 try: 6 print current_thread().getname() 7 8 9 except exception details: 10 print details 11 pass 12 print item*2 13 14 def worker(): 15 while true: 16 item=q.get() 17 do_work(item) 18 q.task_done() 19 20 q=queue.queue() 21 l=[13,26,77,99,101,4003] 22 item in l: 23 q.put(item) 24 25 26 in range (4): 27 t=thread(target=worker,name="child"+str(i)) 28 t.daemon=true 29 t.start() 30 31 32 q.join() 33 update: fixed error hint mata gave should have imported current_thread() too. ...