Since there are few spontaneous suicides, I'd say that it would depend on the suituation and interpretation of "suicide". If it's because of emotions, then it's against the jedi code and bad. If it's a sacrifice for the greater good, it's a good thing.