title: Feathers-mongoose : Get by custom attribute in feathers-mongoose
body: <p>I have a very basic feathers service which stores data in mongoose using the feathers-mongoose package. The issue is with the get functionality. My model is as follows:</p>
  
  <pre><code>module.exports = function (app) {
    const mongooseClient = app.get('mongooseClient');
    const { Schema } = mongooseClient;
    const messages = new Schema({
      message: { type: String, required: true }
    }, {
      timestamps: true
    });
  
    return mongooseClient.model('messages', messages);
  };
  </code></pre>
  
  <p>When the a user runs a GET command :</p>
  
  <pre><code>curl http://localhost:3030/messages/test
  </code></pre>
  
  <p>I have the following requirements</p>
  
  <ol>
  <li>This essentially tries to convert test to ObjectID.  What i would 
  like it to do is to run a query against the message attribute 
  {message : "test"} , i am not sure how i can achieve this. There is 
  not enough documentation for to understand to write or change this
  in the hooks. Can some one please help</li>
  <li>I want to return a custom error code (http) when a row is not found or does not match some of my criterias. How can i achive this?</li>
  </ol>
  
  <p>Thanks</p>