I write my own code to index some data files myself. It was all working. Once I modified the schema.xml file, now i get internal server error that i have no ide
Exception IndexNotFoundException signals that no index was found in the Directory. Possibly because the directory is empty, however can also indicate an index corruption.
So you should:
Delete the index directory or restore data from backups.
Restart the server (or at least the reload the config).