Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Configuration files
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Fabien Carrion  
View profile  
 More options Aug 2 2010, 12:55 pm
From: Fabien Carrion <fabien.carr...@gmail.com>
Date: Mon, 02 Aug 2010 11:55:47 -0500
Local: Mon, Aug 2 2010 12:55 pm
Subject: Configuration files
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello,

For my purposes, I would need to describe one job, or one batch in
various configuration files. And when all the files are loaded process
the job/batch.

It seems to me the functionality doesn't exist.

I would like to know if it is the best way to do it. I would also like
to know in case I do the functionality if you want it.

Thanks

- --
Fabien Carrion

()  Campagne du ruban ASCII -- Contre les mails en html
/\  contre les pieces-jointes Microsoft
Web: http://fabien.carrion.free.fr/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkxW+JAACgkQTe/bvZWuSM9pjwCgzSZasGODtqPCKLxkz3aE55g/
RiUAn2p87FaRd2lmGNWrS7ookmYvAMqt
=T70V
-----END PGP SIGNATURE-----


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Thibaut Barrère  
View profile  
 More options Aug 2 2010, 1:22 pm
From: Thibaut Barrère <thibaut.barr...@gmail.com>
Date: Mon, 2 Aug 2010 19:22:20 +0200
Local: Mon, Aug 2 2010 1:22 pm
Subject: Re: Configuration files
Hello Fabien,

> For my purposes, I would need to describe one job, or one batch in
> various configuration files. And when all the files are loaded process the job/batch.
> It seems to me the functionality doesn't exist.

I'm not sure to understand your needs here - can you describe your use
case a little bit more so we can try to help ?

cheers,

-- Thibaut


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Fabien Carrion  
View profile  
 More options Aug 2 2010, 1:50 pm
From: Fabien Carrion <fabien.carr...@gmail.com>
Date: Mon, 02 Aug 2010 12:50:22 -0500
Local: Mon, Aug 2 2010 1:50 pm
Subject: Re: Configuration files
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Sure,

Right now we have:
ETL::Engine.process("configfile.ctl")

And it parse the file configfile.ctl and it execute it.

I would need something like:
engine = ETL::Engine.new
engine.load("configfile1.ctl")
engine.load("configfile2.ctl")
engine.load("configfile3.ctl")
engine.process

And it would parse all the sources/processors/destinations in
configfile1.ctl, configfile2.ctl, configfile3.ctl and process all of them

This would let me use various configuration files as bricks for a bigger
job.

Is it more understandable?

Thanks

On 08/02/2010 12:22 PM, Thibaut Barr re wrote:

> Hello Fabien,

>> For my purposes, I would need to describe one job, or one batch in
>> various configuration files. And when all the files are loaded process the job/batch.
>> It seems to me the functionality doesn't exist.

> I'm not sure to understand your needs here - can you describe your use
> case a little bit more so we can try to help ?

> cheers,

> -- Thibaut

- --
Fabien Carrion

()  Campagne du ruban ASCII -- Contre les mails en html
/\  contre les pieces-jointes Microsoft
Web: http://fabien.carrion.free.fr/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkxXBVsACgkQTe/bvZWuSM/m1ACfZRKs+YpaBnuIe3KeAIgy4JYN
NdcAn0M0YNInebceUoLjbDaPrxhJcpId
=aF+W
-----END PGP SIGNATURE-----


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Anthony Eden  
View profile  
 More options Aug 2 2010, 2:06 pm
From: Anthony Eden <anthonye...@gmail.com>
Date: Mon, 2 Aug 2010 14:06:54 -0400
Local: Mon, Aug 2 2010 2:06 pm
Subject: Re: Configuration files

That's what .ebf files are for, although I can't recall if they support
delayed execution. If not, then I'd suggest that's where the feature needs
to be implemented.

-Anthony

On Mon, Aug 2, 2010 at 1:50 PM, Fabien Carrion <fabien.carr...@gmail.com>wrote:

--
GMU/IT d- s: a33 C++(++++)$ UL@ P--- L+(++) !E W+++$ !N o? K? w--- !O M++ V
PS+ PE Y PGP t+ !5 X- R tv b++ DI+ D++ G- e++ h---- r+++ y++++**

http://anthony.mp


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Thibaut Barrère  
View profile  
 More options Aug 2 2010, 3:53 pm
From: Thibaut Barrère <thibaut.barr...@gmail.com>
Date: Mon, 2 Aug 2010 21:53:12 +0200
Local: Mon, Aug 2 2010 3:53 pm
Subject: Re: Configuration files

I second what Anthony said: you can use an .ebf file to gather the sequence
of your .ctl files, eg:

require 'common'

run 'first.ctl'
run 'second.ctl' unless some_condition
run 'third.ctl'

Here are a few additional tips:
- you can share common code (any bits of Ruby, really) using a regular
require from inside your .ctl
- you can load whatever is needed, including YAML configuration, ENV
variables etc
- if you have one .ctl with a large setup you'd like to factor our, you can
do this:

before (unique.ctl):

source ..., :table => xxx
transform ...
destination ..., :table => yyy

extract to my_processing.rb:

def do_my_processing(source_table, destination_table)
  source ..., :table => source_table
  transform ...
  destination ..., :table => destination_table
end

then reuse in first.ctl and second.ctl:

# first.ctl
require File.dirname(__FILE__) + '/my_processing'
do_my_processing('A','B')

# second.ctl
require File.dirname(__FILE__) + '/my_processing'
do_my_processing('C','D')

Just the same way, you can extract a group of transform like:

transform :xxx, some_params...
transform :yyy

to

def macro_transform(some_params)
  transform :xxx, some_params
  transform :yy
end

which makes it easy to reuse a large block (eg: cleaning + lookup operations
for instance) accross multiple .ctl files.

Keep in mind that the source/transform/destination etc calls really are
"registrations" rather than "executions". Once the .ctl file is fully loaded
(and all the .ctl file has been parsed), the execution will start row by
row, more or less.

I hope these few tips will help you cover your need - given that you can
fallback to Ruby by design (on purpose), it's fairly easy to accomplish all
the glue code needed here.

-- Thibaut


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Fabien Carrion  
View profile  
 More options Sep 8 2010, 7:39 pm
From: Fabien Carrion <fabien.carr...@gmail.com>
Date: Wed, 08 Sep 2010 18:39:32 -0500
Local: Wed, Sep 8 2010 7:39 pm
Subject: Re: Configuration files
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Thanks for all those tips.

Activewarehouse is working really well for me. I have achieved almost
all my goals.

Let me know if you want to push some commits from my github to the
official repository.

Thanks.

On 08/02/2010 02:53 PM, Thibaut Barr re wrote:

- --
Fabien Carrion

()  Campagne du ruban ASCII -- Contre les mails en html
/\  contre les pieces-jointes Microsoft
Web: http://fabien.carrion.free.fr/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkyIHq0ACgkQTe/bvZWuSM9w3gCgw56JYVvH2ZMV49APpG3Cg318
ba4AmwQkIcjoCfk5qU45oFEDnnIyAIFp
=PyXU
-----END PGP SIGNATURE-----


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »