         GenServer.start_link(Eeb.DuoshuoRecord, :ok, name: @servername)
       _ ->
         :true
+    end
+  end
+
+  def get_record(blog_key, field) do
+    record = get_record(blog_key)
+    case record do
+      nil ->
+        0
+      _ ->
+        case field do
+          :comments ->
+            record.comments
+          :like ->
+            record.like
+          :hits ->
+            record.hits
+          _ ->
+            0
+        end
     end
   end
 

    else
      records = Map.put(records, blog_key, record)
    end
  end
end

  end

  def handle_cast({:update_record, blog_key, record}, records) do
    # Hex.Shell.info("record: #{inspect record}")
    if Map.has_key?(records, blog_key) do
      records = Map.update!(records, blog_key,
        fn _x ->
