Posts

java - GCTaskThread JVM Crash -

my jvm (7.0_21-b11) crashing randomly (sometimes after 1 day , sometime after 1 month). using api makes jni calls. based on quick search seems happens either because of faulty jni calls or faulty ram / disk. running tests , enabled -xcheck:jni can eliminate both of above point. are there other reasons can cause jvm crash in these circumstances. these top few lines hs_err_pid log file. **# jre version: 7.0_21-b11 # java vm: java hotspot(tm) 64-bit server vm (23.21-b01 mixed mode windows-amd64 ) # problematic frame: # v [jvm.dll+0x31e6ec] # # core dump written. default location: c:\app\bin\hs_err_pid9099.mdmp --------------- t h r e d --------------- current thread (0x0000000001cdc000): gctaskthread [stack: 0x0000000000000000,0x0000000000000000] [id=90672] siginfo: exceptioncode=0xc0000005, reading address 0x0000000000000220** you using old version of java jdk7 update 21. crash occured in gc. gc issue caused bug corrupts heap memory. issue gc, compiler, bad native...

angularjs - Angular Route with multiple slashes override folder path -

i have angular app using ngroute module along html5 mode pushstate cleaner url. app.config(function($routeprovider, $locationprovider){ $locationprovider.html5mode(true); $routeprovider //route home page .when("/", { templateurl: "templates/main.html", controller: "imagecontroller", }) //route page .when("/me", { templateurl: "templates/me.html", controller: "imagecontroller", }) //404 error .when("/404", { template: "", controller: "imagecontroller", title: "404 error", }) //default route / .otherwise({ redirectto: "/404", }); }); i have changed .htaccess file rewrite trailing slashes ("/"). rewriteengine on rewritebase / # don't rewrite files or directories rewritecond %{request_filename} -f [or] rewritecond %{request_filename} -d rewrite...

python - Django Biginner - How to connect my algorithm code in django -

this might simple, i'm quite new django. want build app make user upload csv file, run algorithm on it, , make output file available downloaded user. started uploading file thing , looks it's working, , have algorithm code ready, however, i'm not sure how connect algorithm code, not sure how make function include that, , need new url each uploading,running algorithm , downloading? 1 url displays 3 of them. here project files , app, model.py : from django.db import models django.forms import modelform class upload(models.model): pic = models.filefield("csv file", upload_to="images/") upload_date=models.datetimefield(auto_now_add =true) # fileupload form class. class uploadform(modelform): class meta: model = upload fields = '__all__' # or list of fields want include in form view.py: from __future__ import division django.shortcuts import render uploader.models import uploadform,upload io import textiowrappe...

java - What should I use to store data for a program I am working on -

should use arraylist, vectors, hashmp or there else should use store data bank program working on. trying store user information in 1 of them , send file, should use? thank you. to decide between using arraylist/vector or hashmap depends on whether have key-value pairs or simple list of elements. key-value pairs hashmap go-to option (e.g name - person object). if have objects no real keys (a list of trees in forest) arraylist or vector better. the difference between vector , arraylist more subtle. if want more information on difference between 2 can read this article. article 2001, information isn't newest. in cases, arraylist better choice , vector pretty considered deprecated nowadays. biggest difference between 2 is, vector synchronized while arraylist isn't, in cases, makes vector slower arraylist creates unnecessary overhead. more information can @ question: why java vector class considered obsolete or deprecated?

javascript - programmatically close select onorientationchange -

i can't seem close select element when rotating ios device. i've tried blur() (both native , jquery versions), setting style display:none, calling hide(), triggering focus events on other elements, triggering click events on on both select , other elements, disabling select, hiding options, etc. etc. i know webkit doesn't let close selects blur(). have anymore suggestions? i guessing here since have no way test it, seems if put anchor in page this: <a id="myanchor"></a> and add jquery: $(window).on("orientationchange",function(){ $('#myanchor').focus(); }); it should focus on anchor , close select... maybe?

Testing android implementation of cordova plugin -

i have created cordova plugin has android implementation. java code has calls sdk interfaces specific hardware mobile device connected to. write unit tests java code , mock calls sdk can run tests during ci. when looking this, found cordova-plugin-test-framework , can tell, tests write against javascript code, not actual platform implementations. i'm sure use , write tests, require mobile device connected hardware, , don't want have actual calls sdk. in other words, don't have way of mocking sdk calls using this. i thought maybe run junit command line java code, getting errors because couldn't find org.apache.cordova.callbackcontext . tried faking own object, continued, found more dependencies code in isolation doesn't know about. next figured best test within android project under /platforms in ionic mobile app, since dependencies visible @ point. i'm able run ./gradlew test ( https://developer.android.com/studio/test/command-line.html ) here, can...

stored procedures - How can I supply report parameters to ancillary reports from a "base" SSRS report? -

Image
i need have several (four) reports identical except value of particular parameter. don't want user have enter parameters manually, though. when enter following parameters: beatles ------- begdate: 1962 enddate: 1970 unit: beatles i want 4 reports run, using these parameters: lennon ------ begdate: 1962 enddate: 1970 unit: john lennon mccartney --------- begdate: 1962 enddate: 1970 unit: paul mccartney harrison -------- begdate: 1962 enddate: 1970 unit: george harrison starr ----- begdate: 1962 enddate: 1970 unit: ringo starr so when user enters 3 parameters, first 2 ("date") parameters , appropriate-for-the-ancillary-report "unit" parameter ("john lennon" first, "paul mccartney" second, etc.) passed. the report "robot" says after person enters "beatles" unit: "oh, entered 'beatles'! i'll pass 'john lennon' unit parameter first report, 'paul mccartney' unit parameter secon...