Forums / General / importing users from an external datasource

importing users from an external datasource

Author Message

Robin de Silva Jayasinghe

Friday 09 July 2004 5:43:21 am

hello!

i am planning to implement an large scale community site for an organisation with about 2000 members. every member shall have its own pre-installed user. i have all the userdata like email, name, surname, etc. in a separete excel-file.
my question is if there is an possibility to import this file as csv and generate ezPublish users with limited rights automatically?

thanks and best regards from germany!
robin

visit http://www.jayasinghe.de

Paul Borgermans

Friday 09 July 2004 6:03:15 am

Yes,

I did something similar when migrating users in pre 3.4 sites. I modified the text login handler a little bit: instead of creating a user upon firts attempt to login, I let the script "slurp" the entire file. After this I changed the login handler back to the default. Passwords were migrated too (ie the hashed values)

hth

-paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Jonathan Dillon-Hayes

Sunday 19 September 2004 6:57:27 pm

Bump.

This actually is something we're interested in doing as well. We could import, but unfortunately everything else in our architecture is integrated with the parent DB and not eZ. So I suppose we'll have to get eZ to auth against our other MysqlDB and not export it.

I'm working on a 3.4 codebase, and I think I have it down. Quite a challenge though -- I wish there were a way to do this with a web service (SOAP) client.

Anyone have an idea of a good way to do it? I have a couple of thousand users in an external MysqlDB with SHA1 encryption. I can use php's native functions to auth against the raw output (I have php accessing a perl script to get raw output with a 4.3 php version so it's actually just a string comparison).

Anyone have any experience with this? I could use some pointers myself before I break my head for the next two days. ;-)

Jonathan

---------
FireBright provides advanced eZ deployment with root access
http://www.FireBright.com/

Marco Zinn

Tuesday 21 September 2004 1:20:17 pm

Hi,

well, we actually did both with extensions, that we bought from ezSystems for our ez 3.3 system.
First, we had a CSV import module, which imported users to pre-installed user groups, including the sending of generated first-time passwords by email to the individual user.

Now, we are having a User directory, which can be accessed via SOAP. ezSystems wrote an extension, which provided a new user handler, which connects to that User directory via SOAP and checks for the Password. If the login is okay, the SOAP server replies with the full user data, as well as some role identifiers. The user plugin maps those roles to ezPublish roles and creates or updates a "local user" (the one in the ezPublish DB).

The SOAP solution is quite special for our needs, but the CSV import should work fine for any ezPublish solution.

Marco
http://www.hyperroad-design.com

riccardo refolo

Thursday 24 February 2005 1:26:01 am

I have to import user by a csv file, have somebody got a module to do it?
Thank's.
Ps. He could send me the file by mail. I could tell him my mail.

eZ debug

Timing: Jan 18 2025 19:23:19
Script start
Timing: Jan 18 2025 19:23:19
Module start 'content'
Timing: Jan 18 2025 19:23:20
Module end 'content'
Timing: Jan 18 2025 19:23:20
Script end

Main resources:

Total runtime1.1865 sec
Peak memory usage4,096.0000 KB
Database Queries206

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0060 587.8359180.8203
Module start 'content' 0.00601.0089 768.6563683.3906
Module end 'content' 1.01490.1714 1,452.0469337.0625
Script end 1.1864  1,789.1094 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00410.3495210.0002
Check MTime0.00150.1262210.0001
Mysql Total
Database connection0.00090.078610.0009
Mysqli_queries1.095492.32792060.0053
Looping result0.00270.23162040.0000
Template Total1.151697.120.5758
Template load0.00210.178020.0011
Template processing1.149496.877720.5747
Template load and register function0.00010.009410.0001
states
state_id_array0.00280.237310.0028
state_identifier_array0.00220.189320.0011
Override
Cache load0.00180.1484330.0001
Sytem overhead
Fetch class attribute can translate value0.00150.124660.0002
Fetch class attribute name0.00240.199680.0003
XML
Image XML parsing0.00240.202060.0004
class_abstraction
Instantiating content class attribute0.00000.001180.0000
General
dbfile0.00420.3577400.0001
String conversion0.00000.000430.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
5content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
8content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
4content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 22
 Number of unique templates used: 6

Time used to render debug report: 0.0005 secs