Displaying 20 results from an estimated 500 matches similar to: "UUIDTool and weird timestamp split error"
2006 Apr 04
3
uuidtools across processes
Hello,
It seems that there is a small probability of collisions among uuid''s
produced by uuidtools'' UUID.random_create() running in concurrent user
processes on a host (fcgi)? The ~2 bytes extracted from the randomized
clock_sequence make a collision unlikely.
http://rubyforge.org/frs/download.php/8572/uuidtools-1.0.0.zip
Do I miss something?
DD
--
Posted via
2013 Oct 25
6
Migrate postgresql database to uuid
Hi all,
I am using rails 3.1 and ruby 1.9.3,Now i want to use uuid concept in
rails 3 for existing data
so i did like :-
create_table :posts, :id => false do |t|
t.string :uuid, :limit => 36, :primary => true
end
ActiveRecord::Base.class_eval do
# old rails versions
set_primary_key ''uuid''
before_create :generate_uuid
def generate_uuid
self.id =
2012 Oct 17
1
generate 10 UUID records and save it it database in rails
I need to create certain number of UUId records(based on the selection
of drop down) and save it in the database. Now I am generating only one
unique id. Can this be done in the model in this way. Or do I need to
write a helper file for that??
def generate_unique_token=(value) self.secret =
Base64.encode64(UUIDTools::UUID.random_create)[0..8] end
In my controller...........
def create
2007 Jun 16
1
extending activerecord base with after_initialize
hi,
i am having problems getting after_initialize for activerecord
subclasses. basically, i am trying to use the guid plugin by andy
singleton. i am having problems extending the class to the plugins i
installed, so i figured i will just apply this to all the models in my
project. i trled to add the following to my lib/ folder. my goal is
to extended the activerecord class so that it uses
2008 Apr 03
1
Problem with UUID generated in partial not being unique
Folks,
I''m using the "uuidtools" package to generate (hopefully) unique values for
IDs within a partial (for products being added to an order form, where
nothing is saved to the DB until the end).
Unfortunately when I add a new product line (using RJS page.insert.html
rendering a partial) the new lines added all have the same UUID.
Here''s the code from the (top of
2006 Jan 12
8
Synching between Sqlite and MySql
Hi folks,
I am running an offline Rails app that periodically connects to the
Internet to download the latest catalogue, and upload any new orders.
I am about to implement the synching bit - and was thinking whether
there is any other solution other than writing webservices and code to
do a manual sync of the data, or whether there is a more nifty and
robust way using say replication?
2012 Jul 31
1
puppet doc questions
Does puppet doc require a specific version of any gems (such as rdoc or
rake) to operate?
I''m getting some errors when I try to generate my rdoc now.
# puppet doc --output /var/www/test --modulepath
/etc/puppet/environments/test/modules -m rdoc
RDoc::RDocError is deprecated and will be removed in RDoc 4
Could not generate documentation: uninitialized constant
RDoc::RDoc::Generator
2008 Mar 02
0
Models are not initialised correctly with ''rake test'' in Merb 0.9.1
I''m using Sequel as my ORM and Test::Unit as my testing framework and
have the following model:
class Item < Sequel::Model
validates do
presence_of( :name, :uuid, :vendor_id, :vendor_reference, :amount,
:currency_code )
uniqueness_of( :uuid )
end
def initialize( *args )
super( *args )
self.uuid = UUID.random_create.to_s
end
end
As you can see I overwrite
2005 Nov 02
1
Windows, Segmentation Faults, config.load_paths and config.cache_classes
I am doing some testing with the rails trunk, version I switched to
because of memory leaks in 0.13.1 under linux environment.
Right now the application is running fast and steady under linux, with
no memory leaks using SCGI Rails Runner 0.4.3 from Zed, BUT it has
become unusable under Windows (our main development environment) where
I am getting a lot of segmentation faults.
BUT the problem
2009 Jul 20
9
rake error
When I run rake test:units I get this error:
292 tests, 350 assertions, 2 failures, 13 errors
rake aborted!
Command failed with status (1): [/usr/local/bin/ruby -I"lib:test" "/
usr/loc...]
This error just showed up yesterday --- I have no idea how I caused
it. Here is my gem list in case that helps:
actionmailer (2.3.2, 2.2.2)
actionpack (2.3.2, 2.2.2)
activerecord (2.3.2, 2.2.2)
2008 Jul 05
5
Does RSpec work nicely with UUID primary keys?
I have my application happily generating UUID primary keys using the
uuidtools gem.
But the auto-generated specifications created by "script/generate
rspec_scaffold...", etc, assume that one is using a sequential integer
primary key.
For those who have hit this same issue, is it just a matter of rewriting
the auto-generated specifications to take this into account, or does one
have to
2010 Sep 27
3
having some issues with factory_girl and bundler...
Hi All
Need some brilliants minds here :)
I''m using Rails 2.3.8 & ruby 1.8 (I know, I know... )
I''ve move my gems from .gems to Bundler, but I''m having some issues with
Factory_girl when I rake spec
"uninitialized constant Factory"
I''m following the instructions from http://gembundler.com/rails23.html.
Basically:
- grab all config.gem and place
2011 Jan 28
5
mysql quotation wonky
Why would, in an upgrade from 3.0.1 to 3.0.3, a rake db:migrate run
this:
SELECT "schema_migrations"."version" FROM "schema_migrations"
vs this ?
SELECT `schema_migrations`.`version` FROM `schema_migrations`
__ rake db:migrate output __
rake aborted!
Mysql::Error: You have an error in your SQL syntax; check the manual
that corresponds to your MySQL server version
2007 Nov 13
16
mongrel startup fails now: already initialized constant OPTIONS
I updated to ruby 1.8.6p111 last night and updated some gems and now
mongrel doesn''t work:
MacOS 10.4.10
$ ruby --version
ruby 1.8.6 (2007-09-24 patchlevel 111) [i686-darwin8.10.1]
$ gem list rails
*** LOCAL GEMS ***
rails (1.2.5, 1.2.4, 1.2.3, 1.2.2, 1.2.1, 1.2.0, 1.1.6)
Here''s a simple test:
$ rails test5
create ...
$ cd test5
$ script/server
=> Booting
2016 Jul 21
1
remove_oplock: failed to lock share entry...
> On Wed, Jun 29, 2016 at 12:11:51PM -0400, Thomas Schulz wrote:
> >
> > Here is what I could find. The iso file is created on a Solaris system on
> > a file system that is NFS mounted from our main file server. Then it is
> > burned to a CD on a Windows 7 PC through a Samba server running on a
> > different Solaris machine (Solaris 10) that is also NFS mounting
2020 Jan 16
1
INDEX= and dovecot.index.log / dovecot.list.index.log
Using 2.3.8 and
mail_location =
maildir:/var/mail/%Ln:CONTROL=/var/lib/dovecot/control/%Ln:VOLATILEDIR=/var/lib/dovecot/control/%Ln:INDEX=/var/lib/dovecot/control/%Ln
+ also
user_query = SELECT ... CONCAT('maildir:/var/mail/', LOWER(u.login),
'/:CONTROL=/var/lib/dovecot/control/%Ln:VOLATILEDIR=/var/lib/dovecot/control/%Ln:INDEX=/var/lib/dovecot/control/%Ln')
AS mail, ...
but I
2008 Jan 18
5
How do I pass form values from POST controller specs?
Hi there
I just started my first Merb app and I''m running into some weird
things in Specs. When I do:
describe "create action" do
it "should create a new project" do
project_params = {:name => ''bekkunin''}
Project.should_receive(:create).with(project_params)
controller, action = post(''/projects'', :project
2007 Nov 05
1
Should numeric()/character() etc initialize with NA instead of 0 or ""?
Wouldn't it make programming more error-resistant if vectors were
initialized with missing data, instad of zeroes or ""?
That way, if you assign values to a vector elementwise and you miss some
elements
(because their indices were not selected or because the assignment didn't
work out, see below for code examples)
this would be immediately obvious from the value of the vector
2006 Jun 13
11
markaby
What''s the current status of Markaby? I''ve played with it a bit and
love it and am considering using it for a large project I''m starting.
If you''ve used it, I''d love to hear your comments!
Jamie
2016 Jun 29
1
remove_oplock: failed to lock share entry...
> On Tue, Jun 28, 2016 at 11:59:32AM -0400, Thomas Schulz wrote:
>> This with Samba 4.4.3 on Solaris 10.
>>
>> I have been looking at the logs and see messages such as:
>>
>> [2016/06/13 14:20:37.074011, 0] ../source3/smbd/oplock.c:242(remove_oplock)
>> remove_oplock: failed to lock share entry for file packages/winnt/adv084/8.4.1/8.4.1.6.iso
>>