Return-Path: X-Original-To: apmail-shiro-user-archive@www.apache.org Delivered-To: apmail-shiro-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 340316A22 for ; Tue, 28 Jun 2011 10:24:10 +0000 (UTC) Received: (qmail 54918 invoked by uid 500); 28 Jun 2011 10:24:10 -0000 Delivered-To: apmail-shiro-user-archive@shiro.apache.org Received: (qmail 54685 invoked by uid 500); 28 Jun 2011 10:24:05 -0000 Mailing-List: contact user-help@shiro.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@shiro.apache.org Delivered-To: mailing list user@shiro.apache.org Received: (qmail 54624 invoked by uid 99); 28 Jun 2011 10:24:04 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Jun 2011 10:24:04 +0000 X-ASF-Spam-Status: No, hits=2.8 required=5.0 tests=FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL,URI_HEX X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of mipasov@gmail.com designates 209.85.213.45 as permitted sender) Received: from [209.85.213.45] (HELO mail-yw0-f45.google.com) (209.85.213.45) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Jun 2011 10:24:00 +0000 Received: by ywb3 with SMTP id 3so21701ywb.32 for ; Tue, 28 Jun 2011 03:23:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=nv4AiWq+/AR/6CUBbjOhZswP6i5B/3rnh05SlKfGdwc=; b=QRTns3pXV3scvb9tMNyQew7duARaiSYne40Rc38QiqwnIbNAq8apFuyVm/8YyzrQ/d tETkcDen8mApgazt2hhaMi5MNieIMrS+qjqbEtNoGJ75hvyA57nYE+Da1/rQ216+7FE0 onp4kETjhZzYZ/2ZEx7/eR+Ek+oWfXY6FD42Y= MIME-Version: 1.0 Received: by 10.150.65.10 with SMTP id n10mr7961094yba.256.1309256619208; Tue, 28 Jun 2011 03:23:39 -0700 (PDT) Received: by 10.150.144.17 with HTTP; Tue, 28 Jun 2011 03:23:39 -0700 (PDT) In-Reply-To: References: Date: Tue, 28 Jun 2011 16:23:39 +0600 Message-ID: Subject: Re: Shiro Jdbc Realm Mysql. From: Mirlan Ipasov To: user@shiro.apache.org Content-Type: multipart/alternative; boundary=000e0cd3aa2cb52fba04a6c30f55 --000e0cd3aa2cb52fba04a6c30f55 Content-Type: text/plain; charset=ISO-8859-1 Hi, Thank you for your replies. The thing is my server is not showing any Stack trace but only following exception . There was a SQL error while authenticating user [admin] I am using Eclipse Helios with tomcat7 is there anyway to see detailed stack trace? About using data source could you show me some example of using it with shiro? I searched it but no luck. Thanking you, Mirlan On Tue, Jun 28, 2011 at 9:39 AM, Les Hazlewood wrote: > Also, I wouldn't use the DataSource directly - use a connection pool > like BoneCPDataSource that uses the MySQL driver internally: > > http://jolbox.com/ > > I've been using it for a while with good results. > > HTH, > > Les > > On Mon, Jun 27, 2011 at 4:17 AM, Jared Bunting > wrote: > > Well, on first glance your password field is different in your tables and > your query. That being said, it would probably be a bit easier to assist if > you pasted the full stacktrace. > > > > ipas wrote: > > > > > > Hi, the problem above is resolved by changing following lines in web.xml > : > > > > ds = com.mysql.jdbc.Driver > > to > > ds = com.mysql.jdbc.jdbc2.optional.MysqlDataSource > > > > and i forget changing line coreFreightRealm.dataSource = $ds to > > jdbcRealm.dataSource = $ds > > > > > > Now my application is working but giving me *"here was a SQL error while > > authenticating user [admin]* ", But i can not understand exactly in which > > SQL query i have an error. > > > > my tables are : > > users(user_name varchar,user_pass varchar, status int), > > user_roles (user_name varchar,role_name varchar), > > roles_permissions(role_name varchar, permission varchar) > > > > Am i missing something? > > > > Thanking you, > > Mirlan > > > > > > > > -- > > View this message in context: > http://shiro-user.582556.n2.nabble.com/Shiro-Jdbc-Realm-Mysql-tp6519616p6519975.html > > Sent from the Shiro User mailing list archive at Nabble.com. > --000e0cd3aa2cb52fba04a6c30f55 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi, Thank you for your replies.
The thing is my server is not showing a= ny Stack trace but only following exception .

There was a SQL error = while authenticating user [admin]

I am using Eclipse Helios with to= mcat7 is there anyway to see detailed stack trace?

About using data source could you show me some example of using it with= shiro? I searched it but no luck.

Thanking you,
Mi= rlan




On Tue, Jun 28, 2011 at 9:39 AM, Les Haz= lewood <lhazl= ewood@apache.org> wrote:
Also, I wouldn't use the DataSource directly - use a connection pool like BoneCPDataSource that uses the MySQL driver internally:

http://jolbox.com/

I've been using it for a while with good results.

HTH,

Les

On Mon, Jun 27, 2011 at 4:17 AM, Jared Bunting
<jared.bunting@dig= italreasoning.com> wrote:
> Well, on first glance your password field is different in your tables = and your query. =A0That being said, it would probably be a bit easier to as= sist if you pasted the full stacktrace.
>
> ipas <mipasov@gmail.com>= ; wrote:
>
>
> Hi, the problem above is resolved by changing following lines in web.x= ml :
>
> ds =3D com.mysql.jdbc.Driver
> to
> ds =3D com.mysql.jdbc.jdbc2.optional.MysqlDataSource
>
> and i forget changing line coreFreightRealm.dataSource =3D $ds to
> jdbcRealm.dataSource =3D $ds
>
>
> Now my application is working but giving me *"here was a SQL erro= r while
> authenticating user [admin]* ", But i can not understand exactly = in which
> SQL query i have an error.
>
> my tables are :
> users(user_name varchar,user_pass varchar, status int),
> user_roles (user_name varchar,role_name varchar),
> roles_permissions(role_name varchar, permission varchar)
>
> Am i missing something?
>
> Thanking you,
> Mirlan
>
>
>
> --
> View this message in context: = http://shiro-user.582556.n2.nabble.com/Shiro-Jdbc-Realm-Mysql-tp6519616p651= 9975.html
> Sent from the Shiro User mailing list archive at Nabble.com.

--000e0cd3aa2cb52fba04a6c30f55--