Search Results

Search found 181 results on 8 pages for 'jruby'.

Page 4/8 | < Previous Page | 1 2 3 4 5 6 7 8  | Next Page >

  • Cannot install Curb gem on Netbeans 6.9 R2

    - by Zeck
    Hi guys, I'm trying to install feedzirra. When i install curb on my netbeans i get following errors. Building native extensions. This could take a while... ERROR: Error installing curb-0.7.6.gem: ERROR: Failed to build gem native extension. "C:/Program Files/NetBeans 6.9 RC2/ruby/jruby-1.5.0/bin/jruby.bat.exe" extconf.rb '"C:/Program Files/NetBeans 6.9 RC2/ruby/jruby-1.5.0/bin/jruby.bat.exe"' is not recognized as an internal or external command, operable program or batch file. Gem files will remain installed in C:/Program Files/NetBeans 6.9 RC2/ruby/jruby-1.5.0/lib/ruby/gems/1.8/gems/curb-0.7.6 for inspection. Results logged to C:/Program Files/NetBeans 6.9 RC2/ruby/jruby-1.5.0/lib/ruby/gems/1.8/gems/curb-0.7.6/ext/gem_make.out Any ideas how I can get this to work? Or did you know very fast feed parser gem?

    Read the article

  • Why the HelloWorld of opennlp library works fine on Java but doesn't work with Jruby?

    - by 0x90
    I am getting this error: SyntaxError: hello.rb:13: syntax error, unexpected tIDENTIFIER public HelloWorld( InputStream data ) throws IOException { The HelloWorld.rb is: require "java" import java.io.FileInputStream; import java.io.InputStream; import java.io.IOException; import opennlp.tools.postag.POSModel; import opennlp.tools.postag.POSTaggerME; public class HelloWorld { private POSModel model; public HelloWorld( InputStream data ) throws IOException { setModel( new POSModel( data ) ); } public void run( String sentence ) { POSTaggerME tagger = new POSTaggerME( getModel() ); String[] words = sentence.split( "\\s+" ); String[] tags = tagger.tag( words ); double[] probs = tagger.probs(); for( int i = 0; i < tags.length; i++ ) { System.out.println( words[i] + " => " + tags[i] + " @ " + probs[i] ); } } private void setModel( POSModel model ) { this.model = model; } private POSModel getModel() { return this.model; } public static void main( String args[] ) throws IOException { if( args.length < 2 ) { System.out.println( "HelloWord <file> \"sentence to tag\"" ); return; } InputStream is = new FileInputStream( args[0] ); HelloWorld hw = new HelloWorld( is ); is.close(); hw.run( args[1] ); } } when running ruby HelloWorld.rb "I am trying to make it work" when I run the HelloWorld.java "I am trying to make it work" it works perfectly, of course the .java doesn't contain the require java statement. EDIT: I followed the following steps. The output for jruby -v : jruby 1.6.7.2 (ruby-1.8.7-p357) (2012-05-01 26e08ba) (Java HotSpot(TM) 64-Bit Server VM 1.6.0_35) [darwin-x86_64-java]

    Read the article

  • What's the easiest way to get the result of an HTTP GET request in using URL in JRuby

    - by sipwiz
    I'm attempting to build a Tropo Ruby application and I need to retrieve the result of an HTTPS GET. The Tropo platform doesn't have the httpclient Ruby gem so I can't use that. The Ruby engine used is JRuby so a suggestion has been to make use of the Java URL class to do the request. I've played around with it a little bit and I seem to be able to create the URL object ok but am now struggling with how to get the results of executing the request. How do I do it? javaURL = java.net.URL.new svcURL transferResult = javaURL.getContent()

    Read the article

  • JRuby 1.6 passe en RC, support de Ruby 1.9.2 et compatibilité Windows pour l'implémentation alternative de Ruby sur la JVM

    JRuby 1.6 passe en RC Support de Ruby 1.9.2 et compatibilité Windows pour l'implémentation alternative de Ruby sur la JVM JRuby 1.6, la nouvelle version majeure de l'implémentation alternative du langage Ruby sur la Machine Virtuelle Java, sera bientôt prête. Elle vient en effet d'atteindre le stade de Release Candidate. Il s'agit de la première version en date de JRuby qui soit compatible avec Ruby 1.9.2 - première version de la branche 1.9.x du langage qui soit réellement stable et prête pour la production selon ses concepteurs. Mais JRuby 1.6 dispose aussi d'un mode Ruby 1.8.7. L'équipe du projet s'est penchée sur l'amélioration de la compatibilité avec les envir...

    Read the article

  • pickle on jruby

    - by brad
    Does anyone know if pickle is compatible with jruby? I just installed cucumber and cucumber-rails. I then tried gem install pickle and it installs, but a script/generate pickle yields Couldn't find 'pickle' generator I did everything according to the readme no dice. Anyone have any experience with this: specs jruby-1.4.0 rails-2.3.5 cucumber 0.7.2 pickle 0.2.10

    Read the article

  • Is it possible to run locally JRuby on Google App Engine without restarting server on every change?

    - by elado
    Unfortunately, GAE requires restart of the server on each code change. Is it possible to prevent it and have immediate feedback after code save? Or, can I import Google App Engine's API into my ruby code and run it on Sinatra server? Tried this but it fails on "import com.google.appengine.api" (it doesn't know what 'com' is). For Sinatra, I use "Rerun" ( http://github.com/alexch/rerun ) which restarts server immediately after a change with minimum wait. Thanks.

    Read the article

  • Warbler: Where are my images

    - by user108031
    I'm using Jruby and Warbler to deploy a Jruby on Rails application to a Tomcat server. I can see all of my images when I deploy the server with Webrick: jruby -S server/script. However, when I create a .war file out of the rails directory using jruby -S warble and deploy to Tomcat, none of my images show up on the tomcat server. I noticed that image location has changed to the root of the directory in the war file. It seems that /images/picturename.jpg would be appropriate, but my images are not showing up.

    Read the article

  • Simple Serialization Faster Than JSON? (in Ruby)

    - by Sinan Taifour
    I have an application written in ruby (that runs in the JRuby VM). When profiling it, I realized that it spends a lot (actually almost all of) its time converting some hashes into JSON. These hashes have keys of symbols, values of other similar hashes, arrays, strings, and numbers. Is there a serialization method that is suitable for such an input, and would typically run faster than JSON? It would preferable if it is has a Java or JRuby-compatible gem, too. I am currently using the jruby-json gem, which is the fastest JSON implementation in JRuby (as I am told), so the move will most likely be to a different serialization method rather than just a different library. Any help is appreciated! Thanks.

    Read the article

  • Language Prejudices

    - by paranoid_pedlar
    I've been researching programming languages, in hopes of learning to program. Since I've heard a lot of good things about Ruby, I went ahead and purchased The Pragmatic guide to Ruby. I understand that there is a lot of hype about Ruby on Rails. Because ruby lets you program scripts, applications, and internet helped me to decide on learning Ruby vs other languages. Today I watched a talk about google go, and it's really caught my attention. Coincidently I stumbled on a talk about jruby. I've been under the impression that java applications are bloated an slow. However the speaker made a point of what is wrong with Ruby, and how Jruby diagnosed Ruby's shortcomings. All that said. I would like to hear peoples opinions on Jruby vs Ruby, and if Ruby is working on fixing these "short comings". Also, how do you, the programming community feel about "go" and if I'm making a mistake learning Ruby instead of go, or Jruby. Appreciate your advice and opinions Thanks,

    Read the article

  • Au revoir, Python?

    - by GuySmiley
    I'm an ex-C++ programmer who's recently discovered (and fallen head-over-heels with) Python. I've taken some time to become reasonably fluent in Python, but I've encountered some troubling realities that may lead me to drop it as my language of choice, at least for the time being. I'm writing this in the hopes that someone out there can talk me out of it by convincing me that my concerns are easily circumvented within the bounds of the python universe. I picked up python while looking for a single flexible language that will allow me to build end-to-end working systems quickly on a variety of platforms. These include: - web services - mobile apps - cross-platform client apps for PC Development speed is more of a priority at the time-being than execution speed. However, in order to improve performance over time without requiring major re-writes or architectural changes I think it's imperative to be able to interface easily with Java. That way, I can use Java to optimize specific components as the application scales, without throwing away any code. As far as I can tell, my requirement for an enterprise-capable, platform-independent, fast language with a large developer base means it would have to be Java. .NET or C++ would not cut it due to their respective limitations. Also Java is clearly de rigeur for most mobile platforms. Unfortunately, tragically, there doesn't seem to be a good way to meet all these demands. Jython seems to be what I'm looking for in principle, except that it appears to be practically dead, with no one developing, supporting, or using it to any great degree. And also Jython seems too married to the Java libraries, as you can't use many of the CPython standard libraries with it, which has a major impact on the code you end up writing. The only other option that I can see is to use JPype wrapped in marshalling classes, which may work although it seems like a pain and I wonder if it would be worth it in the long run. On the other hand, everything I'm looking for seems to be readily available by using JRuby, which seems to be much better supported. As things stand, I think this is my best option. I'm sad about this because I absolutely love everything about Python, including the syntax. The perl-like constructs in Ruby just feel like such a step backwards to me in terms of readability, but at the end of the day most of the benefits of python are available in Ruby as well. So I ask you - am I missing something here? Much of what I've said is based on what I've read, so is this summary of the current landscape accurate, or is there some magical solution to the Python-Java divide that will snuff these concerns and allow me to comfortably stay in my happy Python place?

    Read the article

  • Lazy loading of ESB in a jruby rails app

    - by brad
    I have a jruby/rails app using: jruby 1.4.0 Rails 2.3.5 ActiveMQ 5.3.0 Mule ESB 2.2.1 Currently in our environment.rb file we start up Mule in the initializer. This becomes a big pain when we go to do normal rake tasks that don't require JMS/Mule such as db:migrate as it takes a long time to startup/shutdown Mule everytime. The code is similar to this: APP_CONTEXT = Java::our.company.package.service_clients.Initializer.getAppContext(MULE_CONFIG_PATH) And we use APP_CONTEXT to fetch the bean to connect to the appropriate service. I'm trying to figure out some mechanism by which APP_CONTEXT could be lazily instantiated (not in initialize) to avoid all of the pains of having to startup Mule on initialize. Currently we have a few ruby client classes that are instantiated as a before_filter in application_controller such as @data_service = DataService.new(APP_CONTEXT) that initialize the proper java client for each request for use in our controllers. I'm open to all suggestions. I'm having a hard time trying to find the right place to put this lazy instantiation.

    Read the article

  • Exception in thread "main" java.lang.NoSuchMethodError: sun/misc/Unsafe.allocateDBBMemory

    - by user2524935
    Has anyone been able to compile JRuby on a s390x Linux system? I am trying to use LogStash, which apparently requires JRuby, however SLES 11 has no JRuby repo included. jar ant produces the following. compile-annotation-binder: [javac] Compiling 18 source files to /home/user7/jruby-1.7.4/build/classes/jruby [javac] warning: [options] bootstrap class path not set in conjunction with -source 1.6 [javac] Note: /home/user7/jruby-1.7.4/src/org/jruby/util/CodegenUtils.java uses unchecked or unsafe operations. [javac] Note: Recompile with -Xlint:unchecked for details. [javac] 1 warning compile-jruby: [javac] Compiling 1395 source files to /home/user7/jruby-1.7.4/build/classes/jruby [javac] Exception in thread "main" java.lang.NoSuchMethodError: sun/misc/Unsafe.allocateDBBMemory(J)J [javac] at java.nio.DirectByteBuffer.(DirectByteBuffer.java:127) [javac] at java.nio.ByteBuffer.allocateDirect(ByteBuffer.java:306) [javac] at sun.misc.Perf.createLong(Native Method) [javac] at sun.misc.PerfCounter.(PerfCounter.java:77) [javac] at sun.misc.PerfCounter.newPerfCounter(PerfCounter.java:83) [javac] at sun.misc.PerfCounter$CoreCounters.(PerfCounter.java:140) [javac] at java.lang.J9VMInternals.initializeImpl(Native Method) [javac] at java.lang.J9VMInternals.initialize(J9VMInternals.java:236) [javac] at sun.misc.PerfCounter.getZipFileOpenTime(PerfCounter.java:194) [javac] at java.util.zip.ZipFile.(ZipFile.java:230) [javac] at java.util.zip.ZipFile.(ZipFile.java:159) [javac] at java.util.jar.JarFile.(JarFile.java:167) [javac] at java.util.jar.JarFile.(JarFile.java:104) [javac] at sun.misc.URLClassPath$JarLoader.getJarFile(URLClassPath.java:958) [javac] at sun.misc.URLClassPath$JarLoader.access$700(URLClassPath.java:826) [javac] at sun.misc.URLClassPath$JarLoader$1.run(URLClassPath.java:909) [javac] at sun.misc.URLClassPath$JarLoader$1.run(URLClassPath.java:899) [javac] at java.security.AccessController.doPrivileged(AccessController.java:280) [javac] at sun.misc.URLClassPath$JarLoader.ensureOpen(URLClassPath.java:898) [javac] at sun.misc.URLClassPath$JarLoader.(URLClassPath.java:871) [javac] at sun.misc.URLClassPath$3.rtJarLoader(URLClassPath.java:596) [javac] at sun.misc.URLClassPath$3.run(URLClassPath.java:546) [javac] at sun.misc.URLClassPath$3.run(URLClassPath.java:536) [javac] at java.security.AccessController.doPrivileged(AccessController.java:280) [javac] at sun.misc.URLClassPath.getLoader(URLClassPath.java:535) [javac] at sun.misc.URLClassPath.getLoader(URLClassPath.java:498) [javac] at sun.misc.URLClassPath.getResource(URLClassPath.java:324) [javac] at java.net.URLClassLoader$ClassFinder.run(URLClassLoader.java:1157) [javac] at java.security.AccessController.doPrivileged(AccessController.java:314) [javac] at java.net.URLClassLoader.findClass(URLClassLoader.java:594) [javac] at java.lang.ClassLoader.loadClassHelper(ClassLoader.java:743) [javac] at java.lang.ClassLoader.loadClass(ClassLoader.java:711) [javac] at java.lang.ClassLoader.loadClassHelper(ClassLoader.java:735) [javac] at java.lang.ClassLoader.loadClass(ClassLoader.java:711) [javac] at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:325) [javac] at java.lang.ClassLoader.loadClass(ClassLoader.java:690) [javac] at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:494) BUILD FAILED /home/user7/jruby-1.7.4/build.xml:636: The following error occurred while executing this line: /home/user7/jruby-1.7.4/build.xml:289: Compile failed; see the compiler error output for details. Total time: 1 minute 37 seconds Line 636 of build.xml <target name="jar" depends="init" description="Create the jruby.jar file. Used during dev."> -> <antcall target="jar-jruby" inheritall="true"/> </target> Line 289 of build.xml <javac destdir="${jruby.classes.dir}" fork="true" debug="true" source="${javac.version}" target="${javac.version}" -> deprecation="true" encoding="UTF-8" includeantruntime="true" memorymaximumsize="${jruby.compile.memory}"> <classpath refid="jruby.execute.classpath"/> <src path="${src.dir}"/> <exclude name="org/jruby/runtime/Constants.java"/> java -version java version "1.7.0" Java(TM) SE Runtime Environment (build pxz6470sr4fp1-20130325_01(SR4 FP1)) IBM J9 VM (build 2.6, JRE 1.7.0 Linux s390x-64 Compressed References 20130306_140761 (JIT enabled, AOT enabled) J9VM - R26_Java726_SR4_FP1_20130306_1011_B140761 JIT - r11.b03_20130131_32403ifx1 GC - R26_Java726_SR4_FP1_20130306_1011_B140761_CMPRSS J9CL - 20130306_140761) JCL - 20130315_01 based on Oracle 7u13-b08 ant -version Apache Ant version 1.7.1

    Read the article

  • ?know How?Oracle WebLogic Server 11g? JRuby?JMX???????|WebLogic Channel|??????

    - by ???02
    ??Java SE???????????????JMX?????????????????????????????????????????????????????????????????????????????????????????????????????JRuby??????????JMX??????Oracle WebLogic Server 11g Release 1????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????¦????????????????????????????????????????    * Oracle Database 11g Release 2??     * JDK 1.6    * JRuby 1.5.6    * Oracle WebLogic Server 11g Release 1??    * ????·????????...

    Read the article

  • Rails deployment strategies with Bundler and JRuby

    - by brad
    I have a jruby rails app and I've just started using bundler for gem dependency management. I'm interested in hearing peoples' opinions on deployment strategies. The docs say that bundle package will package your gems locally so you don't have to fetch them on the server (and I believe warbler does this by default), but I personally think (for us) this is not the way to go as our deployed code (in our case a WAR file) becomes much larger. My preference would be to mimic our MVN setup which fetches all dependencies directly on the server AFTER the code has been copied there. Here's what I'm thinking, all comments are appreciated: Step1: Build war file, copy to server Step2: Unpack war on server, fetch java dependencies with mvn Step3: use Bundler to fetch Gem deps (Where should these be placed??) * Step 3 is the step I'm a bit unclear on. Do I run bundle install with a particular target in mind?? Step4: Restart Tomcat Again my reasoning here is that I'd like to keep the dependencies separate from the code at deploy time. I'd also like to place all gem dependencies in the app itself so they are contained, rather than installing them in the app user's home directory (as, again, I believe is the default for Bundler)

    Read the article

  • Talking JavaOne with Rock Star Charles Nutter

    - by Janice J. Heiss
    JavaOne Rock Stars, conceived in 2005, are the top rated speakers from the JavaOne Conference. They are awarded by their peers who through conference surveys recognize them for their outstanding sessions and speaking ability. Over the years many of the world’s leading Java developers have been so recognized.We spoke with distinguished Rock Star, Charles Nutter. A JRuby Update from Charles NutterCharles Nutter of Red Hat is well known as a lead developer of JRuby, a Ruby implementation of Java that is tightly integrated with Java to allow for the embedding of the interpreter into any Java application with full two-way access between the Java and the Ruby code. Nutter is giving the following sessions at this year’s JavaOne: CON7257 – “JVM Bytecode for Dummies (and the Rest of Us Too)” CON7284 – “Implementing Ruby: The Long, Hard Road” CON7263 – “JVM JIT for Dummies” BOF6682 – “I’ve Got 99 Languages, but Java Ain’t One” CON6575 – “Polyglot for Dummies” (Both with Thomas Enebo) I asked Nutter, to give us the latest on JRuby. “JRuby seems to have hit a tipping point this past year,” he explained, “moving from ‘just another Ruby implementation’ to ‘the best Ruby implementation for X,’ where X may be performance, scaling, big data, stability, reliability, security, and a number of other features important for today's applications. We're currently wrapping up JRuby 1.7, which improves support for Ruby 1.9 APIs, solves a number of user issues and concurrency challenges, and utilizes invokedynamic to outperform all other Ruby implementations by a wide margin. JRuby just gets better and better.” When asked what he thought about the rapid growth of alternative languages for the JVM, he replied, “I'm very intrigued by efforts to bring a high-performance JavaScript runtime to the JVM. There's really no reason the JVM couldn't be the fastest platform for running JavaScript with the right implementation, and I'm excited to see that happen.”And what is Nutter working on currently? “Aside from JRuby 1.7 wrap-up,” he explained, “I'm helping the Hotspot developers investigate invokedynamic performance issues and test-driving their new invokedynamic code in Java 8. I'm also starting to explore ways to improve the general state of dynamic languages on the JVM using JRuby as a guide, and to help the JVM become a better platform for all kinds of languages.” Originally published on blogs.oracle.com/javaone.

    Read the article

  • Talking JavaOne with Rock Star Charles Nutter

    - by Janice J. Heiss
    JavaOne Rock Stars, conceived in 2005, are the top rated speakers from the JavaOne Conference. They are awarded by their peers who through conference surveys recognize them for their outstanding sessions and speaking ability. Over the years many of the world’s leading Java developers have been so recognized.We spoke with distinguished Rock Star, Charles Nutter. A JRuby Update from Charles NutterCharles Nutter of Red Hat is well known as a lead developer of JRuby, a Ruby implementation of Java that is tightly integrated with Java to allow for the embedding of the interpreter into any Java application with full two-way access between the Java and the Ruby code. Nutter is giving the following sessions at this year’s JavaOne: CON7257 – “JVM Bytecode for Dummies (and the Rest of Us Too)” CON7284 – “Implementing Ruby: The Long, Hard Road” CON7263 – “JVM JIT for Dummies” BOF6682 – “I’ve Got 99 Languages, but Java Ain’t One” CON6575 – “Polyglot for Dummies” (Both with Thomas Enebo) I asked Nutter, to give us the latest on JRuby. “JRuby seems to have hit a tipping point this past year,” he explained, “moving from ‘just another Ruby implementation’ to ‘the best Ruby implementation for X,’ where X may be performance, scaling, big data, stability, reliability, security, and a number of other features important for today's applications. We're currently wrapping up JRuby 1.7, which improves support for Ruby 1.9 APIs, solves a number of user issues and concurrency challenges, and utilizes invokedynamic to outperform all other Ruby implementations by a wide margin. JRuby just gets better and better.” When asked what he thought about the rapid growth of alternative languages for the JVM, he replied, “I'm very intrigued by efforts to bring a high-performance JavaScript runtime to the JVM. There's really no reason the JVM couldn't be the fastest platform for running JavaScript with the right implementation, and I'm excited to see that happen.”And what is Nutter working on currently? “Aside from JRuby 1.7 wrap-up,” he explained, “I'm helping the Hotspot developers investigate invokedynamic performance issues and test-driving their new invokedynamic code in Java 8. I'm also starting to explore ways to improve the general state of dynamic languages on the JVM using JRuby as a guide, and to help the JVM become a better platform for all kinds of languages.”

    Read the article

  • Hiding specific files in TextMate

    - by brad
    I do a lot of JRuby on Rails apps, and we have a fair amount of Java .jar dependencies. These become quite annoying in textmate as it really muddies up my lib directory, and I never (obviously) need to actually open these files. Can someone tell me how I might hide .jar files from my file listing in Textmate??

    Read the article

  • SQLServer Binary Data with ActiveRecord and JDBC

    - by John Duff
    I'm using the activerecord-jdbc-adapter with ActiveRecord to be able to access a SQLServer database for Rails Application running under jRuby and am having trouble inserting binary data. The Exception I am getting is below. Note I just have a blurb for the binary data from the fixtures that was working fine for MySQL. ActiveRecord::StatementInvalid: ActiveRecord::ActiveRecordError: Operand type clash: nvarchar is incompatible with image: INSERT INTO blobstorage_datachunks ([id], [datafile_id], [chunk_number], [data]) VALUES (369397133, 663419003, 0, N'GIF89a@') When I created the tables the migration had binary and SQLServer used Image instead. We're using Rails 2.3.5, SQLServer Express 2008. What I'm looking for is a way to get the binary data into SQLServer with ActiveRecord. Thanks in advance for the help.

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8  | Next Page >