The jail dispute between correctional officers and Santa Clara County Sheriff Laurie Smith is headed to court with new issues arising.
The Santa Clara County Correctional Peace Officers Association provided NBC Bay Area with a complaint it filed Friday in Superior Court.
In the lawsuit, the union says the sheriff violated rules to protect officers' privacy rights by making text messages sent by the officers public.
Some of the text messages included racial slurs about inmates.
As NBC Bay Area reported last year, sources said some texts were written by Lance Scimeca, who was the union president at that time.
Scimeca and other officers were placed on administrative leave.
Scimeca also stepped down temporarily as union president and his position filled by Julio Alvarez.
The lawsuit also says the sheriff violated rules by showing personnel records to a third party.
As NBC Bay Area reported, the head of the county's Blue Ribbon Commission, retired judge LaDoris Cordell says she met privately with Smith, at the sheriff's request, to discuss the jail situation.
Cordell, who is on a trip to the east coast, told NBC Bay Area she has not seen the lawsuit and said if she is called to testify "I will tell the truth."
She also said the sheriff, unsolicited, did share personnel records about the correctional officers at their private meeting.
Cordell made reference to the discussions in emails responding to an email complaint from the sheriff, who accused Cordell of soliciting media coverage the sheriff staged a jail fight for recently installed jail cameras.
The sheriff adamantly denied staging a fight among inmates.
Sources tell NBC Bay Area that the sheriff's office will publicly deny the accusations raised in the lawsuit.
They point out the text messages were obtained in a criminal search warrant and are in possession of the court.
So, sources say the messages were not from personnel files but from an "unsealed" criminal search warrant.
They add the sheriff simply shared a "sampling" of the "vile" text messages with the chair of the Blue Ribbon Commission.
The sheriff's office told NBC Bay Area on Tuesday it is still reviewing the complaint.
Late Tuesday afternoon, the sheriff issued a statement reiterating and supporting what insiders told NBC Bay Area earlier: "Of course I showed the chair of the Blue Ribbon evaluating custody operations a sampling of vile and racist text messages obtained through a criminal search warrant, not personnel records, that was ordered unsealed by a judge on November 15, 2015. What a coincidence that last week after a media outlet ( note: Mercury News) filed a public records act request to obtain these hateful text messages that the union leadership is suing to stop their release."
The acting union President, Alvarez, issued a statement to NBC Bay Area saying "the CPOA is responsible for protecting the rights of our members. It's clear from Judge Cordell's emails that there have been serious violations of members' rights and we are going to protect those rights."
A spokesman for the union told NBC Bay Area "we will now wait for a judge to act. We have confidence in the legal process."
See the lawsuit:
Read the search warrant: