This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Notification < ActiveRecord::Base | |
belongs_to :sender, class_name: "User" | |
belongs_to :receiver, class_name: "User" | |
validates :sender_id, presence: true | |
validates :receiver_id, presence: true | |
attr_accessible :sender_id, :receiver_id | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
development: | |
adapter: postgresql | |
encoding: unicode | |
database: app_development | |
pool: 25 | |
username: notmyrealusername | |
password: notmyrealpassword |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[therrell@uw1-320-16 ftp]$ ./ftp ftp.tripod.com | |
220 Welcome to Tripod FTP. | |
Name (ftp.tripod.com:therrell): css432 | |
331 Username set to css432. Now enter your password. | |
Password: | |
230- IMPORTANT NOTICE | |
230- ============================================================ | |
230- | |
230- Powerful building tools. Traffic-generating, money-making | |
230- programs. It's all waiting for you at Tripod. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Manually create the index | |
curl -XPUT 'http://localhost:9200/pins/' | |
# Create proper mapping | |
curl -XPUT 'http://localhost:9200/pins/pin/_mapping' -d ' | |
{ | |
"pin" : { | |
"properties" : { | |
"location" : { | |
"type" : "geo_point" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jtherrell$ curl -XGET http://localhost:9200/test/pin/_search?pretty=true -d '{ | |
"query" : { | |
"match_all" : {} | |
} | |
} | |
' | |
{ | |
"took" : 2, | |
"timed_out" : false, | |
"_shards" : { |