Hadoop eclipse plugin : Unable to see output on console - eclipse

I am using hadoop-0.20.2 from http://www.apache.org/dyn/closer.cgi/hadoop/common/ and I'm using the following Eclipse plugin hadoop-0.20.1-eclipse-plugin.jar from http://code.google.com/p/hadoop-eclipse-plugin/.
Using the file I'm able to load the file into HDFS and also able to compile word-count program . I'm able to compile it without error and get .class files. But when I run the project on Hadoop, I don't see any out-put on the console.
Please tell me if there are any configurations that I need to get the out-put on console. Even output file is not generated.

You should chack the out file path given in FileOutputFormat.setOutputPath(conf, new Path(args[1]));
Note that the output directory should not exist.
I am running the same example given here. And it works fine and also creating the output folder.

Related

flutter blank screen on desktop(windows)

Running my application on another Windows machine results in a blank window. I works fine on the development machine.
I have included all the dll-files + data folder + 3 extra dll files mentioned on the Flutter website.
I have also ran "dependencies" on the resulting .exe file and can't see any missing dll's.
Compiling the "mydemo" application works fine, so I assume there are some other external files my application needs.
I have tried looking through the output of "flutter run -v" to find any clues of extra files needed, but can't see anything useful.
What is the preferred way to tackle a problem like this? How can I find out what files/resources are missing to distribute my app? Is there a way to use the "debug" version on the other machine instead and bring out the debug console window? I would guess that would show me errors when the app tries to load the missing resources.
Check if any package you depend on has some additional file requirements: for example, I'm using sqflite_common_ffi in some of my projects, which needs an additional DLL file to run. I don't know what you're referring to 'dependencies' ran on the EXE, though.
In any case, when I can't get any good output or error from a project, I do this: open up Windows prompt, go to the directory where you have put all the required files, and run
your_exe_file >> logFile.txt 2>&1
which will output the standard output and the standard error to the file. The log file name and extension don't really matter, it will be a simple text file.
For example, if I dont put the additional DLL for sqflite_common_ffi in the same folder of the compiled EXE, the output of the command above will specifically mention the name of the DLL that is missing.
if you got your project through a repository to run on another windows machine, use the command "flutter pub get"

SBT gives my Scala program stale resource files

I have a simple Scala project using SBT. I have a resource file, src/main/resources/cea-builtins.rkt. I open it with val resource = Source.fromResource("cea-builtins.rkt").
Unfortunately, it gives me a stale version of the resource file.
What I expect to happen is:
I edit the file.
I run my program from the sbt command prompt and my program reads the updated file.
What actually happens is:
I edit the resource file.
I run my program from the sbt command prompt and my program reads the old version of the file.
I can clean the project and still get the old version of the file.
If I exit SBT, restart it, and then run my program, I get the updated version of the resource file.
I note that there is a copy of the file in ./target/scala-2.13/<project_name>_2.13-0.1.jar. Updating the resource file and running the program causes that copy to be updated, but I still get the old contents in my program.
If I do lsof -p <sbt_pid> | grep <project_name> I get
<project_root>/target/bg-jobs/sbt_ae437a1d/job-1/target/c224367f/577d7b48/<project_name>_2.13-0.1.jar
I wondered if my program was getting a copy from that file, but that file does not exist in spite of what lsof says.
I've been using Source.fromResource("cea-builtins.rkt") to read the file. That works (except that it's stale). However, if I adapt my code to open the resource with getClass.getResource("cea-builtins.rkt") it fails, as this returns null. I don't understand why.
My build.sbt file is absolutely vanilla. It does not change any paths. It contains library dependencies, one resolver, and that's about it. The only plugin is sbt-assembly.
Any help understanding why I get the stale resource unless I exit and restart SBT? Any suggestions on how to fix this?

How To Run Robot Framework Project Developed In Eclipse Via Command Line

I have created a project using Robot Framework in Eclipse via RED. I want to know how can I run this project via Windows Command Line, so that I can create a Jenkins job to run it at a particular time ? I have tried using the steps for running Eclipse Project from command line via Debug mode, but it is not helping.
Please find the project structure below
I also tried to reach this location and run this test suit using the command
Robot Test_Suite.robot, but then I'm getting below 2 errors
1.) Importing test library 'Excel_Library' failed: ImportError: No module named Excel_Library. This file is a python file which I have written to support Excel operations and it is present at below location in the project -
2.) No Such File Or Directory - Path_To_External_Input\\External_Inputs.xls
This file contains the input which is being read before performing operations related to test suite and it is present at below location -
Do I need to add those in the command line if so how to take care of that ? This project run smoothly from eclipse but only problem is coming from command line.
It seems that you are able to run robot correctly, although I would prefer lowercase R with robot command.
1) I think you have misspelled the library name. If it's a pip package, try ExcelLibrary instead, and check that you have installed it by pip list command or equivalent.
2) Please check the path. Without additional info on how and where the file is called and where the file is located are needed.

"Not A Valid Jar" When trying to run Map Reduce Job

I am trying to run a my MapReduce job by building a jar from eclipse , but while trying to execute the job , I am getting "Not a valid Jar" error.
I have tried to follow the link Not a valid Jar but that didnt help.
Can anyone please give me the instructions on how to build the jar from eclipse, for it to run on Hadoop.
I am aware of the process of building the Jar file from eclipse,however I am not sure, do I have to take any special care for building a jar file, so that it runs on Hadoop.
When you submit the command, make certain you have the following things on the line to do the command:
When you indicate the jar, make certain you are directing to the jar properly. It may be easiest to be certain by using the absolute path. To get the absolute path, if you navigate to the place where the jar is, then run 'readlink -f ' command to get the absolute path. So for you, not just hist.jar, but maybe /home/akash_user/jars/hist.jar or wherever it is on your system. If you are using Eclipse, it may be saving it somewhere funny, so make sure that is not the problem. The jar cannot be run from HDFS storage. must run from local storage.
When you name your main class, in your example Histogram, you must use the fully qualified name of the class, with the package, the project, and the class. So, usually, if the program/project is named Histogram, and there is a HistogramDriver, HistogramMapper, HistogramReducer, and your main() is in HistogramDriver, you need to type Histogram.HistogramDriver to get the program running. (Unless you made your jar runnable, which requires extra stuff at the beginning, making .mdf and things.)
Make sure that the jar you are submitting (hist.jar) is in the current directory from where you are submitting the 'hadoop jar' command.
If the issue is still persisting, please tell the Java, Hadoop and Linux version you are using.
You should not keep the jar file in HDFS when executing the MapReduce job. Make sure Jar is available in the local path. Input path and output directory should be the path from HDFS.

Pass a text file into a Java program as a parameter in Eclipse

I'm trying to pass a .txt file as a paramater into my java program.
My program is titled SetTest and the file I'm trying to read is Ted.txt. From a Windows 7 command prompt I create a temp folder and compile my program there creating SetTest.class. Also in that folder is Ted.txt. From that temp directory I then issue the command:
java SetTest < Ted.txt
Everything works as expected. The program reads in the file and outputs what I'm looking for. All good.
My question is how do I duplicate this using Eclipse? I believe my text file is in the proper location, listed under JRE System Library as seen in the Package Explorer. I've been trying the following from Eclipse: Run -> Run Configurations... Then in the (x)= Arguments section, in the Program arguments field I enter Ted.txt then click on Run. Unfortunately nothing seems to happen. No error message, but I don't see the console output I'm looking for either.
To rephrase your question - you want to send a file to your application's standard input, while it is running in Eclipse.
You can write (copy & paste) data into console (that's where the standard input is taken from). However I am not aware of any possibility how you can redirect file contents directly to the standard input.
UPDATE with correct keywords you might be able to find more resources:
Eclipse reading stdin (System.in) from a file
https://bugs.eclipse.org/bugs/show_bug.cgi?id=155411