Removed logging

This commit is contained in:
Ben Davies 2014-10-04 12:54:27 +01:00
parent 99b882aad2
commit d5f9d4bd46
2 changed files with 0 additions and 12 deletions

View File

@ -3,10 +3,6 @@ Credits go to github.com/SlyMarbo/rss for inspiring this solution.
*/
package feeder
import (
"fmt"
)
type database struct {
request chan string
response chan bool
@ -20,10 +16,8 @@ func (d *database) Run() {
for {
s = <-d.request
if _, ok := d.known[s]; ok {
fmt.Println("Database used: true")
d.response <- true
} else {
fmt.Println("Database used: false")
d.response <- false
d.known[s] = struct{}{}
}

View File

@ -1,9 +1,5 @@
package feeder
import (
"fmt"
)
type databaseHandler struct {
db *database
itemhandler ItemHandler
@ -11,7 +7,6 @@ type databaseHandler struct {
}
func (d *databaseHandler) ProcessItems(f *Feed, ch *Channel, items []*Item) {
fmt.Println("Processing items")
var newitems []*Item
for _, item := range items {
if d.db.request <- item.Key(); !<-d.db.response {
@ -26,7 +21,6 @@ func (d *databaseHandler) ProcessItems(f *Feed, ch *Channel, items []*Item) {
}
func (d *databaseHandler) ProcessChannels(f *Feed, ch []*Channel) {
fmt.Println("Processing channels")
var newchannels []*Channel
for _, channel := range ch {
if d.db.request <- channel.Key(); !<-d.db.response {