I cannot get getResourceAsStream to find a file. I have put the file in the top level dir, target dir, etc, etc and have tried it with a \"/\" in front as well. Everytime
Old question but I just had the same problem and none of the answers worked for me (or I didn't understand them).
In Eclipse, refresh the project directory to make Eclipse aware that a new file has been added to resources. For this, right-click on the project (topmost) directory in the package explorer view, then hit "Refresh". The same if you edit an existing resource file from outside eclipse: refresh to make eclipse aware of the edits.