Hi Matias, That is a rather crazy actor name! Regex issue aside -are you sure you cannot condense the name into something shorter? Even if this would pass the check, if this ends up going through remoting it will carry the entire actor path with it over the wire (!), which is a lot of data!
We'll see what we can do about the check in the mean time... On Wed, Nov 19, 2014 at 7:55 PM, Matias Tealdi <[email protected]> wrote: > I am running akka 2.3.5 and I got some issues creating actor (actorOf > raises a StackOverflowError) with long name (around 8000 chars). > > I was inspecting the code and found that in actor/ActorPath.scala there > is a regex which is used to validate the name. > > *line 25:* val ElementRegex = """(?:[-\w:@ > &=+,.!~*'_;]|%\p{XDigit}{2})(?:[-\w:@&=+,.!~*'$_;]|%\p{XDigit}{2})*""".r > > > I was wondering why it is necessary and what means """%\p{XDigit}{2}""" > isn't it enough with """[-\w:@&=+,.!~*'$_;]""" ? > I guess that (a|b)* make the regex to expensive to check. Would be a good > idea to try to improve/rewrite it? > > > Regards, > Matias > > *A test that makes it fails outside akka.* > > val ElementRegex = """(?:[-\w:@&=+,.!~*'_;]|%\p{XDigit}{2})(?:[-\w:@ > &=+,.!~*'$_;]|%\p{XDigit}{2})*""".r > > val s = > "687474703a2f2f74686566727569742e636f6d2f26683d37617165716378357926656e633d617a6e696e73346f7462636b6276717976397967646c7266347a6e386d2d367679346c62736979676a767175637a797165617138627163785f7a767070326b33657976622d7434666975306e707971366c777a723666626c776c757a6f3270686578716c5f62697277766f6539706271726e72695f6176626178627869666f7a647a30796f63702d7832636a70796b6971626d7a6a7a65726d7a386968757466623831746e747235656a616561646c667975716d31396e6c363068303473707673726566756b736e6e62796b6974646f6765707174636b36396e7937796430376773707161766637686f7879653534676866796a747764666933737769623267746f736e73723973766871387461686e7478627333646e687362716f31386b67793871636d6c61646e746d6f6b646272795f34686d7270647265766d6b646b6672646577686664666964737873766a616a7a6f636a61696a30786a36386836736f6e725f7970706a67766c6a33356964673274736176353978677463787763707937757574327a69346e397535793777715f7566706c70726f5f6c7a76616c3733616264705f72626f2d75723668736a6e6f79747376766270636377785f746f62367465786e6164696d6637773332746267727973636b7369757074393764786d747572355f737266356b736a7773786c6e347939306a6f7a72736c7870646c347a6b71303671376e6f357461396476696e6a637a336c74786765642d6965617331353366617678376b3031696d666970633063673466636174636c326e627673726c763566706d77647779666470796f6c6a33766475766465767a696e74656b322d353135797463686d727738662d7a777368736973716273656d5f6b786379716e736968316874655f6f786d716b7a6c6b727865346972637767716d647166626a366f6a79657375627473376b7577797a7038746d6c746e763271646f73315f636d6a65336c703977626464756a6f7a6f3239356d776d61646b6b6c736771747565696d79307668696c3570653364697877377a65767976735f706c6e67356271657579356d6f3430676c326c6575676d6b626332686a68726c7733396d716e74355f72626d6530396f366938636e6b656d65786a763261666d7067656364617670727873306d7a706e6f62636a6269387a7a6934693337796f3133797a3177627471766e6b38626c3338707a75776863372d61666d6b7565673338746868676d677534623073687a6738675f643269623178317a65366f646861673930667573787a7963696f396a6b326f6d74676175683637747779786a63786a64746f6f687576763870646d64796c656f6f31696773385f66686664786170326a6e63706d632d6634652d706166675f6775726d647066766b766466706174756e6174696966617870637877736d5f6a6c666736707735686b6a7a726170666e6d7178776d6c3775796868796a6e706d697a31655f797a7565672d30716872345f6b5f67636a393562696732797963677a64686a686563706f6a3970786c5f75645f61776e6d616f6a746b6171656d2d6371335f70766265347a776f716e70666f616b7474747636737776746179756e2d31696d69746f7a747570646a6c7a386862627069776c6e6373736b6b786971656c796675357570792d65316467386e776b667766627a696561736a786e617565785f6865783778656d726672363867647a6d62676d6363346e68396c786667736d746a376766776e6e6434347365636d7577626735746e77736965337869733865397173617530776c7562696b6361792d7274766e68697a7375757077766b72746464756c66702d3979756b73623375377270776f716964666568786634786d6f7569627072706d79716f303568657a72636a6461346f63617a65697a756162656a6d36796b726765646b6f313767686465383878636171707778636779637269626d66616b6f7276346b7063366a34333573326e6a746834667a6b6368386a706d6a63756f37783375777772707531797468666778396479666b6777786635353670723669776a6a6d6c67676f6d76777167643539737a70786d77687262646e327775726f6e7a6c30393339656830627a6a6979673376736774636d6f7465396168657979675f7875776e776a71385f397872666239776e7a7479656668696c7162746f6469677230387a3766706a66366d76716e7978377075616c72736570725f626a346964786e6f77667865326c3364796d386264676f65366c64637a77706b697167326f72396373656e5f6877697164627170793939635f356564646a6d7a68737468736c6b71636567736d6c6b34676565676e32673138646c366e74317874766f75797270333134775f6a6c7a78726f793667726666786d6b38766c613374736364676e6b323176746670646868775f39776d643171676c616666666b6836796c6b6871376a775f656132386978326d74726c3579767771773065636c72657074643634377a78756e67727868306979756e686368786469653264707a69656d70766a76646d777566696462386e723239767a3162737038306332746e6f6d6a6f357174356e74357770613934626632397169387572766b61773975376577746a7665736661696f6d3534716e6c696633386e656d3376766b6e6c6171326574306264326e6e71643138696e5f6b6d716c6d73766e38715f7937687363383467305f64636b6830706d716a78613636366a72666b7a7635666a636669727175356a70316b6a6330673138366e61657866626b323275777770766e6965735f6b313173655f343867646961617069696e6b5f677a792d693670697a67796867357667786d756276616432326774696f6e3470646b6b736762647a61636d6531676f797775356d7675776f30757976386476756e627772666d6b6967316a6d7a6d636c733862696f743631766a6a6f6d6b30706b736b2d6477713863686e757162626f706d376832343632367a73786b6171637838397836786d2d716c5f716468696c67355f3774746738746d69366c6a635f7331356b716871786f79666a3970717138726d756c676f6d356275676e376364692d6b62696f7a6a5f766663633236336765786f6f32326667697377793764786165746c3931687867657866657263666c6632756573356e615f2d617733686c726c7637717372767578656c6f746c676e78323076687a376931716e303270686778313077643537776d75787364343669677a6d6979706d62756c6e6633656c62756676706765787667786a6b7370785f796461767975735f6f6937663038757276677337783768756e3664307a3935656f726c36777a686e6f7563687867626f666672706a7a61666c7667796d683762777270656f756a5f6b65686b6672716663636f6c317670366d61636e706574627864386c3475676f386c737a65766137676d667562326e32786976756d656f69695f787a6379697165656765787734656c35353968612d6a6874656f656d735f78657537706c2d62666879665f663335786272356d686b6e6e716c7466752d6a656b6766676f7a7163393077767869696f6b6a7678636e67646369377137376e386d76646b625f6d5f667235753831326e37757a6c7a5f346e6c6a6a6d302d746c67313376347669716478616a756c6371703871732d7a73386e656e726a6473345f6b6a6e787a6f6a68626967316d7976776474676473706a7434773362706d7a726a7668666f656c71766e346c6a6b3937736f766e63726d646c3061356a786578697765686c636a3938326e746570767a796e6a68687672715f6a7366756a746c317a68336e75647a73766f7267386567336462637473627274796b786a74726a78366178383578616e36723178736f757270706363373869386677797765626d31697763736e707275637431706c6466745f706b762d6e61397339775f32623739646b726763727264747a7a33327170787975737867772d6c373773766e773473796a6f7839716c706470753133307273663039707a6c6f6d396f33712d6464626d3063307573366b353033636b69757361783263787a74636677777a69626f6b6d336877692d7870686a30636f612d38686662796f656777636e617978707961616c7374696c306a337a786368736c656f6432796f797864666c717166396e716a647279733770657767796675676d6637777572646d6e64787065756533626f696d7231776663706d7a6f2d70696561716471637475776472676961327668706c7a777977796d67677a6a646a626b373067612d6d7377666e70693134336938373377307a6876676a6132766c3974756e336b323066622d6c66776f347675707472347a376b6f39636d313065663933646866736d37766c69736f68717330726362623137347862306277787331616b6d737268626c6c772d637a716d6c6970316a6835717970716e646b776a6c6273713875706931686d61656675716c70327a7a70726461366630766b346d3969336c735f74796b6e6d726365785f636d766e656d656c677a6a762d74663375656c637274386b783335766a646a5f656e6a6373767867677667646869666a6b75665f676f62766c75316175376336726c783872776a39657379616b636a6538676c687374776968697a3276656875746d34697136767869616f6c5f6d71342d67696f7867737767706a62337579612d336674677a772d2d7070797372783664797863786f61356d" > > s match { > > case ElementRegex() => "Awesome" > > } > > -- > >>>>>>>>>> Read the docs: http://akka.io/docs/ > >>>>>>>>>> Check the FAQ: > http://doc.akka.io/docs/akka/current/additional/faq.html > >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user > --- > You received this message because you are subscribed to the Google Groups > "Akka User List" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at http://groups.google.com/group/akka-user. > For more options, visit https://groups.google.com/d/optout. > -- Cheers, Konrad 'ktoso' Malawski hAkker @ Typesafe -- >>>>>>>>>> Read the docs: http://akka.io/docs/ >>>>>>>>>> Check the FAQ: >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user --- You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/d/optout.
