This file contains hidden or 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
| [tsaleh@tardis:~/code/liveworld-seattle multitenant ∴ ] ./clear_cache.sh | |
| * About to connect() to localhost port 8080 (#0) | |
| * Trying ::1... Connection refused | |
| * Trying fe80::1... Connection refused | |
| * Trying 127.0.0.1... connected | |
| * Connected to localhost (127.0.0.1) port 8080 (#0) | |
| > POST /admin/system-cache.jsp HTTP/1.1 | |
| > User-Agent: curl/7.16.3 (powerpc-apple-darwin9.0) libcurl/7.16.3 OpenSSL/0.9.7l zlib/1.2.3 | |
| > Host: localhost:8080 | |
| > Accept: */* |
This file contains hidden or 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
| mysql> show tables; | |
| +---------------------------------------+ | |
| | Tables_in_everett_multitenant_default | | |
| +---------------------------------------+ | |
| | abuseMessage | | |
| | abuseMessageProp | | |
| | abuseThread | | |
| | abuseThreadProp | | |
| | clubInvitation | | |
| | deletedCategory | |
This file contains hidden or 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
| [tsaleh@tardis:~/code/liveworld-seattle multitenant ∴ ] cat WEB-INF/jiveHome/jive_startup.xml | |
| <defaultProvider> | |
| <username>jive</username> | |
| <serverURL>jdbc:mysql://localhost:3306/everett_multitenant_default</serverURL> | |
| <maxConnections>25</maxConnections> | |
| <connectionTimeout>1.0</connectionTimeout> | |
| <driver>com.mysql.jdbc.Driver</driver> | |
| <password>JumpnJ1v3</password> | |
| <minConnections>5</minConnections> | |
| </defaultProvider> |
This file contains hidden or 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
| Account Create (0.3ms) INSERT INTO `accounts` (`name`, `updated_at`, `deleted_at`, `pending_deletion`, `full_domain`, `created_at`, `tenant_disabled`) VALUES('Cakes Account', '2009-05-26 11:13:25', NULL, 0, 'cakes.livebarhq.com', '2009-05-26 11:13:25', 0) | |
| POST http://localhost:8080/services/seattle/tenants.json | |
| --- | |
| - "{\"username\": \"cakes\", \"domain\": \"cakes.livebarhq.com\", \"first_name\": \"Cakes\", \"password\": \"test\", \"last_name\": \"Admin\", \"email\": \"[email protected]\"}" | |
| - Authentication: f5d06ddb28537e81edcaa1a1f1ca842cba77d6219bba95fbb38a4906750c7d5d0e6301a6c602a918 | |
| Content-Type: application/json | |
| --> 201 Created ({"admin_token_value":"c0b701fe7381e1b31a56f130a162bd8b2280d0b985d11ed9fc86507eeb70f6aa83ec45fd9f87c693","anon_token_value":"681e35bcbd3a74a7a34317d98036daa7fdc5840db09c81cb6c325519df0077c5","domain":"cakes.livebarhq.com","email":null,"first_name":null,"id":3,"last_name":null,"password":null,"username":null}b 1.38s) | |
| User Exists (0.5ms) SELECT `users`.id FROM `users` WHE |
This file contains hidden or 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
| def email_validate_confirmation_required? | |
| (self.email.blank? && !self.email_confirmation.blank?) || | |
| (!self.email.blank? && !self.email_confirmation.blank?) || | |
| (!self.email.blank? && self.email_confirmation.blank?) | |
| end |
This file contains hidden or 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
| def fb_cookie_prefix | |
| Facebooker.api_key+"_" | |
| end | |
| def fb_cookie_names | |
| fb_cookie_names = cookies.keys.select{|k| k.starts_with?(fb_cookie_prefix)} | |
| end | |
| def secure_with_cookies! | |
| parsed = {} |
This file contains hidden or 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
| def post_form_with_net_http(url,params) | |
| Net::HTTP.post_form(url, params) | |
| end | |
| def post_form_with_curl(url,params,multipart=false) | |
| response = Curl::Easy.http_post(url.to_s, *to_curb_params(params)) do |c| | |
| c.multipart_form_post = multipart | |
| c.timeout = Facebooker.timeout | |
| end | |
| response.body_str |
This file contains hidden or 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
| def publish(feed_story_or_action) | |
| session.post(Facebooker::Feed::METHODS[feed_story_or_action.class.name.split(/::/).last], feed_story_or_action.to_params) == "1" ? true : false | |
| end |
This file contains hidden or 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
| {:one => 1, :two => 2}.select {|k,v| k == :one} #=> [[:one, 1]] |
This file contains hidden or 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
| def cookies | |
| return {} unless @env["HTTP_COOKIE"] | |
| if @env["rack.request.cookie_string"] == @env["HTTP_COOKIE"] | |
| @env["rack.request.cookie_hash"] | |
| else | |
| @env["rack.request.cookie_string"] = @env["HTTP_COOKIE"] | |
| # According to RFC 2109: | |
| # If multiple cookies satisfy the criteria above, they are ordered in | |
| # the Cookie header such that those with more specific Path attributes |