Search Results

Search found 51 results on 3 pages for 'portoalet'.

Page 1/3 | 1 2 3  | Next Page >

  • deploying titanium app on jailbroken iphone

    - by portoalet
    Hi, What do I need to do to deploy Titanium app into a jailbroken iPhone? I can deploy an XCode app into a jailbroken iphone by creating my own certificate. I tried packaging the KitchenSink app, but it came up with packaging error. I assume if I can get pass the packaging stage, I can just simply copy and paste the app file into my iPhone (following the previous iPhone guide) THanks

    Read the article

  • Image manipulation

    - by portoalet
    Hi, I am just wondering what kind of computing/programming language/frameworks are needed to produce images such as the one in http://www.erdas.com/ ? Programmatically, how does one produce the general spatial analysis images ? ps: I use java most of the time. Thanks

    Read the article

  • JBoss EJB Bean not bound

    - by portoalet
    Hi, I have the following error Exception in thread "main" javax.naming.NameNotFoundException: CounterBean not bound trying to access an EJB JAR CounterBean.jar deployed on JBoss5 from a client application outside the Application Server. From the Jboss log, it looks like it does not have a global JNDI name? Is this ok? What have I done wrong? JBoss log: 13:50:39,669 INFO [JBossASKernel] Created KernelDeployment for: Counter.jar 13:50:39,672 INFO [JBossASKernel] installing bean: jboss.j2ee:jar=Counter.jar,name=CounterBean,service=EJB3 13:50:39,672 INFO [JBossASKernel] with dependencies: 13:50:39,672 INFO [JBossASKernel] and demands: 13:50:39,673 INFO [JBossASKernel] partition:partitionName=DefaultPartition; Required: Described 13:50:39,673 INFO [JBossASKernel] jboss.ejb:service=EJBTimerService; Required: Described 13:50:39,673 INFO [JBossASKernel] and supplies: 13:50:39,673 INFO [JBossASKernel] jndi:CounterBean 13:50:39,673 INFO [JBossASKernel] Added bean(jboss.j2ee:jar=Counter.jar,name=CounterBean,service=EJB3) to KernelDeployment of: Counte r.jar 13:50:39,712 INFO [SessionSpecContainer] Starting jboss.j2ee:jar=Counter.jar,name=CounterBean,service=EJB3 13:50:39,727 INFO [EJBContainer] STARTED EJB: com.don.CounterBean ejbName: CounterBean 13:50:39,732 INFO [JndiSessionRegistrarBase] Binding the following Entries in Global JNDI: The client code is: public static void main(String[] args) throws NamingException, InterruptedException { InitialContext ctx = new InitialContext(); Counter s = (Counter)ctx.lookup("CounterBean/remote"); for(int i = 0; i < 100; i++ ) { s.printCount(i); Thread.sleep(1000); } } Error message: java -Djava.naming.provider.url=jnp://123.123.123.123:1099 -Djava.naming.factory.initial=org.jnp.interfaces.NamingContextFactory com.don.Client Exception in thread "main" javax.naming.NameNotFoundException: CounterBean not bound at org.jnp.server.NamingServer.getBinding(NamingServer.java:771) at org.jnp.server.NamingServer.getBinding(NamingServer.java:779) at org.jnp.server.NamingServer.getObject(NamingServer.java:785) at org.jnp.server.NamingServer.lookup(NamingServer.java:396) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:305) at sun.rmi.transport.Transport$1.run(Transport.java:159) at java.security.AccessController.doPrivileged(Native Method) at sun.rmi.transport.Transport.serviceCall(Transport.java:155) at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) at java.lang.Thread.run(Thread.java:619) at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:255) at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:233) at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:142) at org.jnp.server.NamingServer_Stub.lookup(Unknown Source) at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:726) at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686) at javax.naming.InitialContext.lookup(InitialContext.java:392) at com.don.Client.main(Client.java:10)

    Read the article

  • Sun Java Realtime System on VirtualMachine / cloud

    - by portoalet
    Just wondering if anybody can run/compile application for Sun Java Realtime system on a VM such as VMWare or on the Cloud such as on Amazon EC2 ? I know it is not ideal running Realtime java on a virtualized infrastructure, but it makes things easier. (Otherwise I just have to install SLES SP2 on physical hardware.)

    Read the article

  • OpenStreetMap and Hadoop

    - by portoalet
    Hi, I need some ideas for a weekend project about Hadoop and OpenStreetMap. I have access to AWS EC2 instance with OpenStreetMap snapshot in my EBS volume. The OpenStreetMap data is in a PostgreSQL database. What kind of MapReduce function can be run on the OpenStreetMap data, assuming I can export them into xml format, and then place into HDFS ? In other words, I am having a brain cramp at the moment, and cannot think what kind of MapReduce operation that can extract valuable insight from the OpenStreetMap xml? (i.e. extract all the places designated as park or golf course. But this needs to be done once only, not continuously) Many Thanks

    Read the article

  • process csv in scala

    - by portoalet
    I am using scala 2.7.7, and wanted to parse CSV file and store the data in SQLite database. I ended up using OpenCSV java library to parse the CSV file, and using sqlitejdbc library. Using these java libraries makes my scala code looks almost identical to that of Java code (sans semicolon and with val/var) As I am dealing with java objects, I can't use scala list, map, etc, unless I do scala2java conversion or upgrade to scala 2.8 Is there a way I can simplify my code further using scala bits that I don't know? val filename = "file.csv"; val reader = new CSVReader(new FileReader(filename)) var aLine = new Array[String](10) var lastSymbol = "" while( (aLine = reader.readNext()) != null ) { if( aLine != null ) { val symbol = aLine(0) if( !symbol.equals(lastSymbol)) { try { val rs = stat.executeQuery("select name from sqlite_master where name='" + symbol + "';" ) if( !rs.next() ) { stat.executeUpdate("drop table if exists '" + symbol + "';") stat.executeUpdate("create table '" + symbol + "' (symbol,data,open,high,low,close,vol);") } } catch { case sqle : java.sql.SQLException => println(sqle) } lastSymbol = symbol } val prep = conn.prepareStatement("insert into '" + symbol + "' values (?,?,?,?,?,?,?);") prep.setString(1, aLine(0)) //symbol prep.setString(2, aLine(1)) //date prep.setString(3, aLine(2)) //open prep.setString(4, aLine(3)) //high prep.setString(5, aLine(4)) //low prep.setString(6, aLine(5)) //close prep.setString(7, aLine(6)) //vol prep.addBatch() prep.executeBatch() } } conn.close()

    Read the article

  • Maven jetty download dependencies

    - by portoalet
    Hi, Why does every time I do "mvn jetty:run", maven tries to download some dependencies (apache poi and ojdbc jars) ? How can I disable this? [INFO] Scanning for projects.. [INFO] Searching repository for plugin with prefix: 'jetty'. [INFO] ------------------------------------------------------------------------ [INFO] Building infolitReport [INFO] task-segment: [jetty:run] [INFO] ------------------------------------------------------------------------ [INFO] Preparing jetty:run Downloading: http://repository.springsource.com/maven/bundles/release/org/apache/poi/com.springsource.org.apache.poi/3.6/com.springsource.org.apache.poi-3.6.pom Downloading: http://repository.springsource.com/maven/bundles/external/org/apache/poi/com.springsource.org.apache.poi/3.6/com.springsource.org.apache.poi-3.6.pom Downloading: http://repository.springsource.com/maven/bundles/milestone/org/apache/poi/com.springsource.org.apache.poi/3.6/com.springsource.org.apache.poi-3.6.pom Downloading: http://repository.springsource.com/maven/bundles/snapshot/org/apache/poi/com.springsource.org.apache.poi/3.6/com.springsource.org.apache.poi-3.6.pom Downloading: http://repo1.maven.org/maven2/org/apache/poi/com.springsource.org.apache.poi/3.6/com.springsource.org.apache.poi-3.6.pom Downloading: http://repository.springsource.com/maven/bundles/release/com/oracle/ojdbc14/10.2.0.2/ojdbc14-10.2.0.2.pom Downloading: http://repository.springsource.com/maven/bundles/external/com/oracle/ojdbc14/10.2.0.2/ojdbc14-10.2.0.2.pom Downloading: http://repository.springsource.com/maven/bundles/milestone/com/oracle/ojdbc14/10.2.0.2/ojdbc14-10.2.0.2.pom Downloading: http://repository.springsource.com/maven/bundles/snapshot/com/oracle/ojdbc14/10.2.0.2/ojdbc14-10.2.0.2.pom Downloading: http://repo1.maven.org/maven2/com/oracle/ojdbc14/10.2.0.2/ojdbc14-10.2.0.2.pom [INFO] [aspectj:compile {execution: default}]

    Read the article

  • Resources for JVM Tuning

    - by portoalet
    Anybody knows a good book or two (or resources) for JVM Tuning? I am struggling to find any. I stumbled upon Apress Java EE 5 Performance Management and Optimization, but there was not much in there.

    Read the article

  • Classpath issue with java -jar

    - by portoalet
    Hi, I have an executable jar Client.jar that requires jndi.properties file. Since the jndi properties is not part of the Client.jar, and java -jar ignores the -classpath argument, How can I execute the jar and let it know where the jndi.properties is? Thanks

    Read the article

  • Trying to cause java.lang.OutOfMemoryException

    - by portoalet
    Hi, I am trying to reproduce java.lang.OutOfMemoryException in Jboss4, which one of our client got, presumably by running the J2EE applications over days/weeks. I am trying to find a way for the webapp to spitout java.lang.OutOfMemoryException in a matter of minutes (instead of days/weeks). One thing come into mind is to write a selenium script and has the script bombards the webapps. One other thing that we can do is to reduce JVM heap size, but we would prefer not to do this, as we want to see the limit of our system. Any suggestions? ps: I don't have access to the source code.

    Read the article

  • Using StringBuilder to process csv files to save heap space

    - by portoalet
    I am reading a csv file that has about has about 50,000 lines and 1.1MiB in size (and can grow larger). In Code1, I use String to process the csv, while in Code2 I use StringBuilder (only one thread executes the code, so no concurrency issues) Using StringBuilder makes the code a little bit harder to read that using normal String class. Am I prematurely optimizing things with StringBuilder in Code2 to save a bit of heap space and memory? Code1 fr = new FileReader(file); BufferedReader reader = new BufferedReader(fr); String line = reader.readLine(); while ( line != null ) { int separator = line.indexOf(','); String symbol = line.substring(0, seperator); int begin = separator; separator = line.indexOf(',', begin+1); String price = line.substring(begin+1, seperator); // Publish this update publisher.publishQuote(symbol, price); // Read the next line of fake update data line = reader.readLine(); } Code2 fr = new FileReader(file); StringBuilder stringBuilder = new StringBuilder(reader.readLine()); while( stringBuilder.toString() != null ) { int separator = stringBuilder.toString().indexOf(','); String symbol = stringBuilder.toString().substring(0, separator); int begin = separator; separator = stringBuilder.toString().indexOf(',', begin+1); String price = stringBuilder.toString().substring(begin+1, separator); publisher.publishQuote(symbol, price); stringBuilder.replace(0, stringBuilder.length(), reader.readLine()); }

    Read the article

  • How to deploy http://code.google.com/p/dyuproject/ into app engine

    - by portoalet
    Hi, I am trying to use openid/hybrid in app engine, but so far, no luck. No success with openid4java (because it creates socket etc), and no luck with dyuproject either. How do it deploy dyuproject into my java appengine? I just could not understand the different structure of the code in http://dyuproject.googlecode.com/files/dyuproject.appspot.com-source-2009-10-08.zip It is just so different than the default new google web application. Many thanks.. I have been struggling the whole week

    Read the article

  • Java Synchronized List Deadlock

    - by portoalet
    From Effective Java 2nd edition item 67 page 266-268: The background thread calls s.removeObserver, which attempts to lock observers, but it can’t acquire the lock, because the main thread already has the lock. All the while, the main thread is waiting for the background thread to finish removing the observer, which explains the deadlock. I am trying to find out which threads deadlock in the main method by using ThreadMXBean (http://stackoverflow.com/questions/1102359/programmatic-deadlock-detection-in-java) , but why does it not return the deadlocked threads? I used a new Thread to run the ThreadMXBean detection. public class ObservableSet<E> extends ForwardingSet<E> { public ObservableSet(Set<E> set) { super(set); } private final List<SetObserver<E>> observers = new ArrayList<SetObserver<E>>(); public void addObserver(SetObserver<E> observer) { synchronized(observers) { observers.add(observer); } } public boolean removeObserver(SetObserver<E> observer) { synchronized(observers) { return observers.remove(observer); } } private void notifyElementAdded(E element) { synchronized(observers) { for (SetObserver<E> observer : observers) observer.added(this, element); } } @Override public boolean add(E element) { boolean added = super.add(element); if (added) notifyElementAdded(element); return added; } @Override public boolean addAll(Collection<? extends E> c) { boolean result = false; for (E element : c) result|=add(element); //callsnotifyElementAdded return result; } public static void main(String[] args) { ObservableSet<Integer> set = new ObservableSet<Integer>(new HashSet<Integer>()); final ThreadMXBean threadMxBean = ManagementFactory.getThreadMXBean(); Thread t = new Thread(new Runnable() { @Override public void run() { while( true ) { long [] threadIds = threadMxBean.findDeadlockedThreads(); if( threadIds != null) { ThreadInfo[] infos = threadMxBean.getThreadInfo(threadIds); for( ThreadInfo threadInfo : infos) { StackTraceElement[] stacks = threadInfo.getStackTrace(); for( StackTraceElement stack : stacks ) { System.out.println(stack.toString()); } } } try { System.out.println("Sleeping.."); TimeUnit.MILLISECONDS.sleep(1000); } catch (InterruptedException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } }); t.start(); set.addObserver(new SetObserver<Integer>() { public void added(ObservableSet<Integer> s, Integer e) { ExecutorService executor = Executors.newSingleThreadExecutor(); final SetObserver<Integer> observer = this; try { executor.submit(new Runnable() { public void run() { s.removeObserver(observer); } }).get(); } catch (ExecutionException ex) { throw new AssertionError(ex.getCause()); } catch (InterruptedException ex) { throw new AssertionError(ex.getCause()); } finally { executor.shutdown(); } } }); for (int i = 0; i < 100; i++) set.add(i); } } public interface SetObserver<E> { // Invoked when an element is added to the observable set void added(ObservableSet<E> set, E element); } // ForwardingSet<E> simply wraps another Set and forwards all operations to it.

    Read the article

  • How thread-safe is enum in java?

    - by portoalet
    Hi, How thread-safe is enum in java? I am implementing a Singleton using enum (as per Bloch's Effective Java), should I worry at all about thread safety for my singleton enum? Is there a way to prove or disprove that it is thread safe? // Enum singleton - the preferred approach public enum Elvis { INSTANCE; public void leaveTheBuilding() { ... } } Thanks

    Read the article

  • String regex matching in Erlang

    - by portoalet
    How would I do regex matching in Erlang? All I know is this: f("AAPL" ++ Inputstring) - true. The lines that I need to match "AAPL,07-May-2010 15:58,21.34,21.36,21.34,21.35,525064\n" In Perl regex: ^AAPL,* (or something similar) In Erlang?

    Read the article

  • 2 IE8 behave differently

    - by portoalet
    Hi, I am having a problem where 2 IE8 (with the same version number 8.0.6001.18702) behave differently in processing a webpage. The misbehaving one is of course used by the client :) , and I just cannot reproduce it on my machine or on our test machine. How can I narrow down what is causing this problem? Thanks

    Read the article

  • Java Performance measurement

    - by portoalet
    Hi, I am doing some Java performance comparison between my classes, and wondering if there is some sort of Java Performance Framework to make writing performance measurement code easier? I.e, what I am doing now is trying to measure what effect does it have having a method as "synchronized" as in PseudoRandomUsingSynch.nextInt() compared to using an AtomicInteger as my "synchronizer". So I am trying to measure how long it takes to generate random integers using 3 threads accessing a synchronized method looping for say 10000 times. I am sure there is a much better way doing this. Can you please enlighten me? :) public static void main( String [] args ) throws InterruptedException, ExecutionException { PseudoRandomUsingSynch rand1 = new PseudoRandomUsingSynch((int)System.currentTimeMillis()); int n = 3; ExecutorService execService = Executors.newFixedThreadPool(n); long timeBefore = System.currentTimeMillis(); for(int idx=0; idx<100000; ++idx) { Future<Integer> future = execService.submit(rand1); Future<Integer> future1 = execService.submit(rand1); Future<Integer> future2 = execService.submit(rand1); int random1 = future.get(); int random2 = future1.get(); int random3 = future2.get(); } long timeAfter = System.currentTimeMillis(); long elapsed = timeAfter - timeBefore; out.println("elapsed:" + elapsed); } the class public class PseudoRandomUsingSynch implements Callable<Integer> { private int seed; public PseudoRandomUsingSynch(int s) { seed = s; } public synchronized int nextInt(int n) { byte [] s = DonsUtil.intToByteArray(seed); SecureRandom secureRandom = new SecureRandom(s); return ( secureRandom.nextInt() % n ); } @Override public Integer call() throws Exception { return nextInt((int)System.currentTimeMillis()); } } Regards

    Read the article

  • Java loop for a certain duration

    - by portoalet
    Hi, Is there a way I can do a for loop for a certain amount of time easily? (without measuring the time ourselves using System.currentTimeMillis() ?) I.e. I want to do something like this in Java: int x = 0; for( 2 minutes ) { System.out.println(x++); } Thanks

    Read the article

  • Adding images into source code

    - by portoalet
    Is there a way (or an editor) that allows me to link an image/files/http links from within a source file (*.java for instance), sort of like a rich text document ? This way, while reading the code I can quickly look at the appended image (augmenting the comments), instead of opening the browser etc.

    Read the article

1 2 3  | Next Page >