title: how to read a json file and save entries to mongodb
body: <p>I am parsing a JSON file that is an array of objects. I am trying to parse this array with some logic and then save each entry to mongodb via mongoose.</p>
  
  <pre><code>var fs = require('fs');
  var Promise = require("bluebird");
  var Show = require('../server/models/show');
  
  Promise.promisifyAll(fs);
  
  // read file
  fs.readFileAsync('upcoming-shows.json', 'utf8')
  .then(function (resolve, reject) {
      var shows = JSON.parse(resolve);
  
      shows.forEach(function(show){
          // first entries have no date
          if(typeof show.date != 'undefined'){
              var formatDate = show.date.split('\n')[1].trim();   // Thu 08 Oct 2015
              show.date = formatDate;
  
              var newShow = new Show(show);
              newShow.headline = show.headline;
              newShow.eventLink = show.eventLink;
              newShow.eventImage = show.eventImage;
              newShow.venue = show.venue;
              newShow.dateString = show.date;
  
              // console.log(newShow);
              newShow.save(function(err, s){
                  console.log(s);
  
              });
  
          }
  
      });
  
  });
  </code></pre>
  
  <p>The <code>newShow</code> object looks like a mongodb object</p>
  
  <pre><code>{ dateString: 'Fri 25 Sep 2015',
    headline: 'Gui Boratto',
    eventLink: 'http://www.songkick.com/concerts/24627124-gui-boratto-at-mighty',
    eventImage: 'http://images.sk-static.com/images/media/profile_images/artists/404729/large_avatar',
    date: Fri Sep 25 2015 00:00:00 GMT-0700 (PDT),
    venue: 'Mighty',
    _id: 55d7c0e461ed8df612ad232b,
    artists: [] }
  </code></pre>
  
  <p>My mongoose model looks like:</p>
  
  <pre><code>var mongoose = require('mongoose');
  
  // show model schema
  var showSchema = mongoose.Schema({
  
      artists: [{ type : mongoose.Schema.ObjectId, ref : 'Artist' }],
      venueId: { type : mongoose.Schema.ObjectId, ref : 'Venue' },
      date: { type: Date },
      ticketUrl: { type: String },
  
      headline: { type: String },
      eventLink: { type: String },
      eventImage: { type: String },
      venue: { type: String },
      dateString: { type: String }
  
  });
  
  module.exports = mongoose.model('Show', showSchema);
  </code></pre>
  
  <p>However the entry does not save to mongodb! Why isn't the data being added to the database?</p>