![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
require 'rubygems' require 'lib/relaxdb'
RelaxDB.configure :host => "localhost", :port => 5984, :design_doc => "app" #, :logger => Logger.new(STDOUT) RelaxDB.delete_db "relaxdb_scratch" rescue :ok RelaxDB.use_db "relaxdb_scratch" RelaxDB.enable_view_creation # creates views when class definition is executed
class User < RelaxDB::Document property :name end
class Invite < RelaxDB::Document
property :created_at
property :event_name
property :state, :default => "awaiting_response", :validator => lambda { |s| %w(accepted rejected awaiting_response).include? s }
references :sender, :validator => :required
references :recipient, :validator => :required
property :sender_name, :derived => [:sender, lambda { |p, o| o.sender.name } ]
view_by :sender_name view_by :sender_id view_by :recipient_id, :created_at, :descending => true
def on_update_conflict puts "conflict!" end
end
sofa = User.new(:name => "sofa").save! futon = User.new(:name => "futon").save!
i = Invite.new :sender => sofa, :recipient => futon, :event_name => "CouchCamp" i.save!
il = RelaxDB.load i._id puts i == il # true
ir = Invite.by_sender_name "sofa" puts i == ir # true
ix = Invite.by_sender_name(:key => "sofa").first puts i == ix # true
puts ix.sender_name # prints sofa, no requests to CouchDB made puts ix.sender.name # prints sofa, a single CouchDB request made
idup = i.dup i.save! idup.save # conflict printed
i = Invite.new :sender => sofa, :event_name => "CouchCamp"
i.save! rescue :ok # save! throws an exception on validation failure or conflict i.save # returns false rather than throwing an exception puts i.errors.inspect # prints {:recipient=>"invalid:"}
i.validation_skip_list << :recipient # Any and all validations may be skipped i.save # succeeds
FAQs
Unknown package
We found that paulcarey-relaxdb demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.