My custom field gets removed and set to none on updating the issue via edit issue screen

I am encountering a strange issue, i have built a custom field named (Custom ID) using customfield module for java, the field is read only and only the Java app can edit or update this.
So if i generate a value from the app and then go to issue view screen, if on the issue view screen if i update any field lets say Priority to High it works as expected. But as soon as i do the same thing via clicking on the edit button to update the Priority and save the changes it removed the Custom ID field and set it to none.
May anyone please assist me in this.