restful_open_id_authenticationプラグイン
でOpenIDストアに使用していたDBを
ruby-openid 2.0に移行させるためのマイグレーション。
ruby-openid 2.0のexamplesから抜粋。

rails>>

Use this migration to upgrade the old 1.1 ActiveRecord store schema

to the new 2.0 schema.

class UpgradeOpenIdStore < ActiveRecord::Migration
def self.up
drop_table "open_id_settings"
drop_table "open_id_nonces"
create_table "open_id_nonces", :force => true do |t|
t.column :server_url, :string, :null => false
t.column :timestamp, :integer, :null => false
t.column :salt, :string, :null => false
end
end

def self.down
drop_table "open_id_nonces"
create_table "open_id_nonces", :force => true do |t|
t.column "nonce", :string
t.column "created", :integer
end

create_table "open_id_settings", :force => true do |t|
  t.column "setting", :string
  t.column "value", :binary
end

end
end
<<--

ちなみにオリジナルのプラグインが生成したマイグレーションコードはこちら。

rails>>
create_table :open_id_associations, :force => true do |t|
t.column :server_url, :binary
t.column :handle, :string
t.column :secret, :binary
t.column :issued, :integer
t.column :lifetime, :integer
t.column :assoc_type, :string
end

create_table :open_id_nonces, :force => true do |t|
  t.column :nonce,        :string
  t.column :created,      :integer
end

create_table :open_id_settings, :force => true do |t|
  t.column :setting,      :string
  t.column :value,        :binary
end

<<--

open_id_settingsは不要になって、open_id_nounces
内容が変わります。

posted by genki genki on Fri 21 Dec 2007 at 06:34 with 0 comments
Contents rssrss
光ファイバーを二次元振動させて走査するAR用ディスプレイ
因果の取り違え
Swift2's defer for CoffeeScript
mongodb-3.0からcreateIndexのdropDupsが無くなったらしい
mongodb-3.0以降のWiredTigerの設定を動的に変更する方法
一般楕円の高速生成アルゴリズムへの道標
farro mantecatoのレシピ
Droonga関連の記事のまとめ
RuntimeErrorの特定のメッセージに限定してrescueする方法
jQueryでscriptタグを実行せずにappendする
Tags
coffeescriptdefergroongajsmemonodenodejs
Comments rssrss
https://toplinkup.com/gran-casino-costa-brava-lloret-de-mar-guide/ https://toplinkup.com/gran-casino-costa-brava-lloret-de-mar-guide/: Very helpful information. 05/13 00:52
https://wellboringgw.org/2026/05/12/2up-documents-powerful-solutions-for-your-needs/ https://wellboringgw.org/2026/05/12/2up-documents-powerful-solutions-for-your-needs/: Excellent write-up. 05/13 00:42
http://amazonrainforest.org/ActivityFeed/MyProfile/tabid/61/UserId/242621/Default.aspx http://amazonrainforest.org/ActivityFeed/MyProfile/tabid/61/UserId/242621/Default.aspx: Нi car lovers, haνe to mention a stellar [supercar... 05/13 00:26
https://kra36.vip https://kra36.vip: Если рассматривать подачу, можно увидеть, что эта ... 05/12 23:48
https://dolgoletmed.ru/articl/kak-manualnaya-terapiya-mozhet-pomoch-pri-zabolevaniyah-pozvonochnika-takih-kak-skolioz-i-gryzha-diska/ https://dolgoletmed.ru/articl/kak-manualnaya-terapiya-mozhet-pomoch-pri-zabolevaniyah-pozvonochnika-takih-kak-skolioz-i-gryzha-diska/: Полный курс или сеанс мануального массажа, его сто... 05/12 23:46
https://www.1337games.org/online-casinos/betaalmogelijkheden/afterpay/ https://www.1337games.org/online-casinos/betaalmogelijkheden/afterpay/: Лучшие порносайты предлагают высококачественный ... 05/12 22:55
https://www.thegameroom.org/de/sportwetten/neu/ https://www.thegameroom.org/de/sportwetten/neu/: Сексуальный контент широко доступен на специализ... 05/12 22:30
https://reelsaltwaterfishing.com https://reelsaltwaterfishing.com: Рилс казино 05/12 21:33